Delete a Profile
DELETE https://api.botsi.com/v2/profiles/{profileId}This route accepts the secret key only
Send $BOTSI_SECRET_KEY as the bare value of the Authorization header, with no Bearer prefix, the same as the other secret-key V2 routes. The public key is rejected with 401, even though Create a Profile, Get a Profile, and Update a Profile accept it. Call this from your server, never from the app. See Authentication.
Path parameters#
There is no request body. Deleting by appUserId isn't supported on this route.
# Authorization: $BOTSI_SECRET_KEY
curl -X DELETE "https://api.botsi.com/v2/profiles/fff3c120-0ca8-480f-9b19-3955a5428e39" \
-H "Authorization: $BOTSI_SECRET_KEY"What this deletes#
Deleted:
- the Profile
- the records Botsi keeps for that Profile: its Access Levels (entitlements), custom attributes, segment membership, attribution data, and integration identifiers (AppsFlyer/Amplitude ids)
After the Profile is deleted#
GET, PATCH, and DELETE on that profileId return 404.
Calling Create a Profile again with the same appUserId creates a new Profile with a new profileId.
Response#
The Profile was deleted.
{ "ok": true }Errors#
A public key returns 401:
{ "error": "No valid API key provided.", "code": "unauthorized" }