hog_functions
hog_functions

post/api/projects/{project_id}/hog_functions/{id}/discard_draft/

Request

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

Path parameters

idstring uuid required

A UUID string identifying this hog function.

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/.

Response

idstring uuid required
namestring nullable

Display name for the function.

descriptionstring

Human-readable description of what this function does.

created_atstring date-time required
updated_atstring date-time required
enabledboolean

Whether the function is active and processing events.

deletedboolean

Soft-delete flag. Set to true to archive the function.

hogstring

Source code. Hog language for most types; TypeScript for site_destination and site_app.

bytecodeunknown required
transpiledstring nullable required
inputsobject

Values for each input defined in inputs_schema.

icon_urlstring nullable

URL for the function's icon displayed in the UI.

template_idstring nullable

ID of the template to create this function from.

execution_orderinteger nullable

Execution priority for transformations. Lower values run first.

_create_in_folderstring
batch_export_idstring uuid nullable required
versioninteger required

Incremented every time the live config changes. See the revisions endpoint.

draftunknown required
draft_updated_atstring date-time nullable required

When config was last staged for review, or null when nothing is staged.

base_updated_atstring date-time

Optimistic concurrency: the updated_at (or draft_updated_at when editing a staged draft) you last read. If the stored side is newer, the write fails with 409 instead of overwriting the concurrent edit. Omit to overwrite unconditionally.

Changes

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