Sample - OpenAI API
DELETE/threads/{thread_id}

Delete a thread

Deletes a specific thread. Use thread_id to identify the thread you want to remove from the thread collection.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

1 parameter
thread_idstringrequired
The identifier of the thread to delete.

2 status codes
200Returns a deletion result containing the thread identifier, a deleted flag, and the `thread.deleted` object type.
idstringrequired
deletedbooleanrequired
objectstringrequired
Allowed:thread.deleted
429Returned when the request was rejected because a rate limit was exceeded.
errorobjectrequired

Error handling

A 429 is returned when the request exceeds the rate limit. thread_id must identify the thread you intend to delete.