Unblock User
curl --request DELETE \
--url https://api.sublay.io/v8/:projectId/users/:userId/block \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sublay.io/v8/:projectId/users/:userId/block"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sublay.io/v8/:projectId/users/:userId/block', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sublay.io/v8/:projectId/users/:userId/block",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sublay.io/v8/:projectId/users/:userId/block"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.sublay.io/v8/:projectId/users/:userId/block")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sublay.io/v8/:projectId/users/:userId/block")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyUser Block Operations
Unblock User
Unblock a user by their ID
Unblock User
curl --request DELETE \
--url https://api.sublay.io/v8/:projectId/users/:userId/block \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sublay.io/v8/:projectId/users/:userId/block"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sublay.io/v8/:projectId/users/:userId/block', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sublay.io/v8/:projectId/users/:userId/block",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sublay.io/v8/:projectId/users/:userId/block"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.sublay.io/v8/:projectId/users/:userId/block")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sublay.io/v8/:projectId/users/:userId/block")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyRemoves the block edge from the acting user (the blocker) to the specified user (the target). The barrier lifts immediately.
Unblocking is idempotent — unblocking a user who isn’t blocked is a success no-op. Nothing that the block tore down is restored: removed follows and connections stay gone and the two users must re-establish them from scratch. A previously frozen 1:1 conversation becomes usable again (the conversation record still exists).
Requires the
moderation bundle. A project without the moderation bundle returns 403 database/tables-not-available. See Bundles.Path Parameters
string
required
The Sublay user ID (UUID) of the user to unblock (the target).
Query Parameters
string
Service key only, and required with one: the user this request acts as, who performs the unblock (the blocker). A user token always acts as its own user and must not send it (
400 block/acting-user-not-allowed).Response
On success, returns HTTP204 with no body.
Error Responses
Missing User — 400
Missing User — 400
A service key sent no
actingUserId.{
"error": "A service key must send actingUserId: the user this request acts as.",
"code": "block/missing-user-id"
}
Acting User Not Allowed — 400
Acting User Not Allowed — 400
A user token sent
actingUserId, even naming its own user. Only a service key names the user it acts as; a user token always acts as its own user.{
"error": "actingUserId is only accepted with a service key. A user's own token always acts as that user.",
"code": "block/acting-user-not-allowed"
}
User Not Found — 404
User Not Found — 404
Returned when a service key names an
actingUserId that isn’t a user in this project.{ "error": "No user with this actingUserId exists in this project.", "code": "block/user-not-found" }

