Delete spans
Permanently deletes spans by their span IDs. This operation is irreversible.
Accepts between 1 and 5000 span IDs per request. Only spans within the searched time window are considered; spans outside that window are not affected.
The optional start_time and end_time fields scope the search to a specific time window. Each bound is independent: omitting start_time defaults to two years ago; omitting end_time defaults to now. You may provide either or both. Providing them when the approximate timestamp of the target spans is known significantly reduces the amount of span data the server must search.
A 200 OK response always includes:
- completed — true if the operation finished and no retry is needed; false if the operation could not fully complete (retry the full request).
- deleted_span_ids — span IDs confirmed deleted in this request.
- not_deleted_span_ids — requested IDs not deleted: either not found within the supported time range, or not reached when completed is false.
The delete operation is idempotent — re-submitting already-deleted IDs is safe.
<Note>This endpoint is in beta, read more here.</Note>
Request body
Response
Spans deleted. The response body always includes:
- completed: whether all requested spans were fully processed. This endpoint is idempotent — retries are safe.
- deleted_span_ids: IDs of spans confirmed deleted.
- not_deleted_span_ids: IDs of spans not deleted — either not found, or not yet processed when completed is false.