data_deletion_requests

Submit a one-column HogQL query for event deletion.

post/api/projects/{project_id}/data_deletion_requests/

Request

  • Base URL: https://us.posthog.com
  • URL: https://us.posthog.com/api/projects/{project_id}/data_deletion_requests/
  • Auth: HTTP bearer

Path parameters

project_idstring required

Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.

Request body

querystring required

HogQL query that selects one event UUID column.

variablesobject

Variables referenced by the HogQL query.

submission_idstring uuid required

Client-generated identifier that makes request submission idempotent.

Response

idstring uuid required

Deletion request identifier.

status'draft' | 'pending' | 'approved' | 'in_progress' | 'queued' | 'completed' | 'failed' required
  • draft - Draft
  • pending - Pending
  • approved - Approved
  • in_progress - In Progress
  • queued - Queued
  • completed - Completed
  • failed - Failed
querystring required

Submitted HogQL query snapshot.

variablesobject required

Submitted HogQL variable snapshot.

submission_idstring uuid nullable required

Client-generated idempotency identifier.

countinteger nullable required

Number of selected events, when calculated.

created_by_idinteger nullable required

Identifier of the user who submitted the request.

created_by_staffboolean nullable required

Whether the submitter was a PostHog staff user.

created_atstring date-time required

Time when the request was submitted.

updated_atstring date-time required

Time when the request last changed.

approved_atstring date-time nullable required

Time when the request was approved, if approved.

stats_calculated_atstring date-time nullable required

Time when selection statistics were calculated, if available.

Changes

No recorded changes to this operation across all 1 revision of this API.