{"components":{"schemas":{"CollectionBatch":{"additionalProperties":false,"properties":{"events":{"items":{"$ref":"#/components/schemas/CollectionEvent"},"maxItems":100,"minItems":1,"title":"Events","type":"array"},"project_key":{"maxLength":200,"minLength":1,"pattern":"\\S","title":"Project Key","type":"string"}},"required":["project_key","events"],"title":"CollectionBatch","type":"object"},"CollectionError":{"properties":{"detail":{"$ref":"#/components/schemas/CollectionErrorDetail"}},"required":["detail"],"title":"CollectionError","type":"object"},"CollectionErrorDetail":{"properties":{"code":{"title":"Code","type":"string"},"hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hint"},"message":{"title":"Message","type":"string"},"request_id":{"title":"Request Id","type":"string"}},"required":["message","code","request_id"],"title":"CollectionErrorDetail","type":"object"},"CollectionEvent":{"additionalProperties":false,"properties":{"anonymous_id":{"anyOf":[{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"},{"type":"null"}],"title":"Anonymous Id"},"context":{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"title":"Context","type":"object"},"event":{"anyOf":[{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"},{"type":"null"}],"title":"Event"},"group_key":{"anyOf":[{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"},{"type":"null"}],"title":"Group Key"},"group_type":{"anyOf":[{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"},{"type":"null"}],"title":"Group Type"},"groups":{"patternProperties":{"\\S":{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"}},"propertyNames":{"maxLength":200,"minLength":1},"title":"Groups","type":"object"},"id":{"maxLength":200,"minLength":1,"pattern":"\\S","title":"Id","type":"string"},"properties":{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"title":"Properties","type":"object"},"session_id":{"anyOf":[{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"},{"type":"null"}],"title":"Session Id"},"set_once":{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"title":"Set Once","type":"object"},"timestamp":{"format":"date-time","title":"Timestamp","type":"string"},"traits":{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"title":"Traits","type":"object"},"type":{"enum":["track","page","identify","group"],"title":"Type","type":"string"},"user_id":{"anyOf":[{"maxLength":200,"minLength":1,"pattern":"\\S","type":"string"},{"type":"null"}],"title":"User Id"}},"required":["id","type","timestamp"],"title":"CollectionEvent","type":"object"},"CollectionReceipt":{"properties":{"received":{"title":"Received","type":"integer"},"received_at":{"format":"date-time","title":"Received At","type":"string"},"request_id":{"title":"Request Id","type":"string"},"status":{"enum":["accepted","discarded"],"title":"Status","type":"string"}},"required":["status","received","received_at","request_id"],"title":"CollectionReceipt","type":"object"},"JsonValue":{}}},"info":{"description":"Native and PostHog-compatible event collection. Disabled by default; discard mode is non-durable.","title":"Embrasure Collection API","version":"0.1.0"},"openapi":"3.1.0","paths":{"/batch/":{"post":{"description":"Supported analytics-only PostHog SDK requests. See the SDK compatibility guide.","operationId":"collect_posthog_batch__post","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionReceipt"}}},"description":"Sink acknowledged the batch, or discard mode. Inspect status."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Forbidden"},"408":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Timeout"},"413":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Entity Too Large"},"415":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unsupported Media Type"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unprocessable Entity"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Too Many Requests"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Service Unavailable"}},"summary":"Collect Posthog","tags":["collection"]}},"/e/":{"post":{"description":"Supported analytics-only PostHog SDK requests. See the SDK compatibility guide.","operationId":"collect_posthog_e__post","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionReceipt"}}},"description":"Sink acknowledged the batch, or discard mode. Inspect status."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Forbidden"},"408":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Timeout"},"413":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Entity Too Large"},"415":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unsupported Media Type"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unprocessable Entity"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Too Many Requests"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Service Unavailable"}},"summary":"Collect Posthog","tags":["collection"]}},"/i/v0/e/":{"post":{"description":"Supported analytics-only PostHog SDK requests. See the SDK compatibility guide.","operationId":"collect_posthog_i_v0_e__post","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionReceipt"}}},"description":"Sink acknowledged the batch, or discard mode. Inspect status."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Forbidden"},"408":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Timeout"},"413":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Entity Too Large"},"415":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unsupported Media Type"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unprocessable Entity"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Too Many Requests"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Service Unavailable"}},"summary":"Collect Posthog","tags":["collection"]}},"/v1/batch":{"post":{"operationId":"collect_batch_v1_batch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionBatch"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionReceipt"}}},"description":"Successful Response"},"202":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionReceipt"}}},"description":"Durably accepted by the configured sink."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Forbidden"},"408":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Timeout"},"413":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Request Entity Too Large"},"415":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unsupported Media Type"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Unprocessable Entity"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Too Many Requests"},"503":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionError"}}},"description":"Service Unavailable"}},"summary":"Collect Batch","tags":["collection"]}}},"servers":[{"url":"https://api.embrasure.ai/collect"}]}