Core

Erase an End User

Erase what was generated for one of your users, for their privacy requests.

Pass the same user id you sent on their requests (URL-encoded). Erased: the request records sent with that id (prompt, parameters, inputs and output links removed; the charge, model and date stay for your invoices) and the images, clips and audio those requests produced, from the CDN and from your library.

Kept: content screening records (declines, strikes), which abuse prevention and the law require us to keep. If the end user has any decline or strike on record, nothing is erased and the response is held_for_review: email contact@spicyapi.com with the id and we will review it.

Requests sent without user cannot be tied to a person, so send it on every request if your users can ask for erasure.

DELETE/v1/end-users/{user}Try it
Erase an End User
cURL
curl --request DELETE \
  --url https://api.spicyapi.com/v1/end-users/user_8f3a2c \
  --header 'Authorization: Bearer $SPICYAPI_KEY'
200
JSON
{ "object": "end_user.erasure", "user": "user_8f3a2c", "status": "erased", "requests": 42, "files": 37 }

Authorizations

Authorizationstringheaderrequired

Bearer authentication header of the form Bearer <token>, where <token> is your SpicyAPI key (sk-spicy-…). Create one in the dashboard under API Keys.

Response

200 · application/json

Successful Response

statusstringrequired

erased or held_for_review.

requestsinteger

Request records erased.

filesinteger

Generated files deleted.

reasonstring

With held_for_review: why, and what to do.

Was this page helpful?