Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

2.1 KB
Raw Blame
{
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "properties": {
        "data": {
            "description": "Optional metadata for the new event definition",
            "properties": {
                "description": {
                    "description": "Description explaining when the event is triggered",
                    "type": "string"
                },
                "hidden": {
                    "description": "Mark event as no longer used/captured. Hides it from UI while preserving historical data",
                    "type": "boolean"
                },
                "owner": {
                    "anyOf": [
                        {
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991,
                            "type": "integer"
                        },
                        {
                            "type": "null"
                        }
                    ],
                    "description": "Numeric user ID of the person responsible for the event. Must be a member of the organization. To find the ID from an email, call `org-members-list` and use `user.id`. Pass null to remove the owner."
                },
                "tags": {
                    "description": "Tags to organize events by product area (e.g. \"checkout\", \"onboarding\") or user journey stage (e.g. \"acquisition\", \"activation\", \"monetization\", \"retention\")",
                    "items": {
                        "maxLength": 255,
                        "type": "string"
                    },
                    "type": "array"
                },
                "verified": {
                    "description": "Mark as verified to indicate the event is properly instrumented and tracking correctly",
                    "type": "boolean"
                }
            },
            "type": "object"
        },
        "eventName": {
            "description": "The name of the event to create (e.g. \"user_signed_up\")",
            "maxLength": 400,
            "minLength": 1,
            "type": "string"
        }
    },
    "required": ["eventName"],
    "type": "object"
}