Batch
For instructions on how to authenticate to use this endpoint, see API overview.
Endpoints
Delete batch exports destroy
Required API key scopes
batch_export:write
Path parameters
- idstring
A UUID string identifying this batch export.
- project_idstring
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Request
DELETE
/api /projects /:project_id /batch_exports /:id
export POSTHOG_PERSONAL_API_KEY=[your personal api key]curl -X DELETE \-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \<ph_app_host>/api/projects/:project_id/batch_exports/:id/
Response
Status 204 No response body
Create batch exports backfill create
Trigger a backfill for a BatchExport.
Required API key scopes
batch_export:write
Path parameters
- idstring
A UUID string identifying this batch export.
- project_idstring
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Request parameters
- namestring
A human-readable name for this BatchExport.
- model
Which model this BatchExport is exporting.
events
- Eventspersons
- Persons
- destination
- interval
- pausedboolean
Whether this BatchExport is paused or not.
- last_paused_atstring
The timestamp at which this BatchExport was last paused.
- start_atstring
Time before which any Batch Export runs won't be triggered.
- end_atstring
Time after which any Batch Export runs won't be triggered.
- hogql_querystring
Request
POST
/api /projects /:project_id /batch_exports /:id /backfill
export POSTHOG_PERSONAL_API_KEY=[your personal api key]curl-H 'Content-Type: application/json'\-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \<ph_app_host>/api/projects/:project_id/batch_exports/:id/backfill/\-d name="string",\-d destination=undefined,\-d interval=undefined
Response
Status 200 No response body
Retrieve batch exports logs retrieve
Path parameters
- idstring
A UUID string identifying this batch export.
- project_idstring
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Request
GET
/api /projects /:project_id /batch_exports /:id /logs
export POSTHOG_PERSONAL_API_KEY=[your personal api key]curl \-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \<ph_app_host>/api/projects/:project_id/batch_exports/:id/logs/
Response
Status 200 No response body
Create batch exports pause create
Pause a BatchExport.
Required API key scopes
batch_export:write
Path parameters
- idstring
A UUID string identifying this batch export.
- project_idstring
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Request parameters
- namestring
A human-readable name for this BatchExport.
- model
Which model this BatchExport is exporting.
events
- Eventspersons
- Persons
- destination
- interval
- pausedboolean
Whether this BatchExport is paused or not.
- last_paused_atstring
The timestamp at which this BatchExport was last paused.
- start_atstring
Time before which any Batch Export runs won't be triggered.
- end_atstring
Time after which any Batch Export runs won't be triggered.
- hogql_querystring
Request
POST
/api /projects /:project_id /batch_exports /:id /pause
export POSTHOG_PERSONAL_API_KEY=[your personal api key]curl-H 'Content-Type: application/json'\-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \<ph_app_host>/api/projects/:project_id/batch_exports/:id/pause/\-d name="string",\-d destination=undefined,\-d interval=undefined
Response
Status 200 No response body
Create batch exports unpause create
Unpause a BatchExport.
Required API key scopes
batch_export:write
Path parameters
- idstring
A UUID string identifying this batch export.
- project_idstring
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Request parameters
- namestring
A human-readable name for this BatchExport.
- model
Which model this BatchExport is exporting.
events
- Eventspersons
- Persons
- destination
- interval
- pausedboolean
Whether this BatchExport is paused or not.
- last_paused_atstring
The timestamp at which this BatchExport was last paused.
- start_atstring
Time before which any Batch Export runs won't be triggered.
- end_atstring
Time after which any Batch Export runs won't be triggered.
- hogql_querystring
Request
POST
/api /projects /:project_id /batch_exports /:id /unpause
export POSTHOG_PERSONAL_API_KEY=[your personal api key]curl-H 'Content-Type: application/json'\-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \<ph_app_host>/api/projects/:project_id/batch_exports/:id/unpause/\-d name="string",\-d destination=undefined,\-d interval=undefined