Delete credentials
curl --request DELETE \
--url https://api.example.com/v1/end-users/{endUserId}/credentials \
--header 'Content-Type: application/json' \
--data '
{
"fields": [
"<string>"
]
}
'import requests
url = "https://api.example.com/v1/end-users/{endUserId}/credentials"
payload = { "fields": ["<string>"] }
headers = {"Content-Type": "application/json"}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({fields: ['<string>']})
};
fetch('https://api.example.com/v1/end-users/{endUserId}/credentials', 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.example.com/v1/end-users/{endUserId}/credentials",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'fields' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/end-users/{endUserId}/credentials"
payload := strings.NewReader("{\n \"fields\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("Content-Type", "application/json")
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.example.com/v1/end-users/{endUserId}/credentials")
.header("Content-Type", "application/json")
.body("{\n \"fields\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/end-users/{endUserId}/credentials")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"fields\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"ok": true
}End users
Delete credentials
Clear some or all credentials for an end-user.
DELETE
/
v1
/
end-users
/
{endUserId}
/
credentials
Delete credentials
curl --request DELETE \
--url https://api.example.com/v1/end-users/{endUserId}/credentials \
--header 'Content-Type: application/json' \
--data '
{
"fields": [
"<string>"
]
}
'import requests
url = "https://api.example.com/v1/end-users/{endUserId}/credentials"
payload = { "fields": ["<string>"] }
headers = {"Content-Type": "application/json"}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({fields: ['<string>']})
};
fetch('https://api.example.com/v1/end-users/{endUserId}/credentials', 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.example.com/v1/end-users/{endUserId}/credentials",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'fields' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/end-users/{endUserId}/credentials"
payload := strings.NewReader("{\n \"fields\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("Content-Type", "application/json")
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.example.com/v1/end-users/{endUserId}/credentials")
.header("Content-Type", "application/json")
.body("{\n \"fields\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/end-users/{endUserId}/credentials")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"fields\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"ok": true
}Path parameters
string
required
The end-user identifier.
Request body
string[]
Specific credential fields to clear. Omit or pass an empty array to wipe every credential for this end-user.Valid field names match the set endpoint:
twitterAuthToken, twitterCt0, redditSession, tiktokSessionId, tiktokCsrfToken, instagramSessionId, instagramCsrfToken, instagramDsUserId.Response — 200 OK
boolean
Always
true on success.Example
curl "$API_BASE/end-users/alice/credentials" -X DELETE \
-H "Authorization: Bearer $API_KEY"
curl "$API_BASE/end-users/alice/credentials" -X DELETE \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{"fields": ["twitterAuthToken", "twitterCt0"]}'
# Clear everything
client.end_users("alice").credentials.delete()
# Or a subset
client.end_users("alice").credentials.delete(
fields=["twitter_auth_token", "twitter_ct0"],
)
// Clear everything
await client.endUsers("alice").credentials.delete();
// Or a subset
await client.endUsers("alice").credentials.delete(
["twitterAuthToken", "twitterCt0"],
);
Notes
- Irreversible. Once cleared, the credentials are gone. To re-enable that platform for the end-user, call
PUT .../credentialsagain with fresh values. - The end-user record itself is not deleted. Only the credential fields inside it. The end-user’s task and session history remain accessible.
- Per-platform isolation. Passing
fields: ["twitterAuthToken", "twitterCt0"]clears Twitter only; TikTok, Instagram, etc. remain configured.
Errors
| Code | Meaning |
|---|---|
400 | Invalid JSON body, endUserId > 256 chars |
401 | Missing Authorization header |
403 | Revoked API key |
