{"openapi":"3.1.0","info":{"title":"BotDock Public API","version":"0.12.0"},"paths":{"/api/v1/projects/{project_id}/workflows/{identifier}/run":{"post":{"summary":"Run Public","operationId":"run_public_api_v1_projects__project_id__workflows__identifier__run_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"identifier","in":"path","required":true,"schema":{"type":"string","title":"Identifier"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":8,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__workflows__api__RunBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: workflows:run."}},"/api/v1/projects/{project_id}/workflow-runs/{identifier}":{"get":{"summary":"Read Public","operationId":"read_public_api_v1_projects__project_id__workflow_runs__identifier__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"identifier","in":"path","required":true,"schema":{"type":"string","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: workflows:read."}},"/api/v1/projects/{project_id}/automation-events":{"post":{"summary":"Public Event","operationId":"public_event_api_v1_projects__project_id__automation_events_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__workflows__api__EventBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: events:write."}},"/api/v1/projects/{project_id}/tables":{"get":{"tags":["Data"],"summary":"Public Tables","operationId":"public_tables_api_v1_projects__project_id__tables_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: data:read."}},"/api/v1/projects/{project_id}/tables/{table_id}/rows":{"get":{"tags":["Data"],"summary":"Public Rows","operationId":"public_rows_api_v1_projects__project_id__tables__table_id__rows_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"table_id","in":"path","required":true,"schema":{"type":"string","title":"Table Id"}},{"name":"environment","in":"query","required":false,"schema":{"enum":["sandbox","live"],"type":"string","default":"live","title":"Environment"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: data:read."},"post":{"tags":["Data"],"summary":"Public Add","operationId":"public_add_api_v1_projects__project_id__tables__table_id__rows_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"table_id","in":"path","required":true,"schema":{"type":"string","title":"Table Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":8,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RowsBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: data:write."}},"/api/v1/projects/{project_id}/analytics":{"get":{"tags":["Analytics"],"summary":"Public Stats","operationId":"public_stats_api_v1_projects__project_id__analytics_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"default":30,"title":"Days"}},{"name":"environment","in":"query","required":false,"schema":{"enum":["sandbox","live"],"type":"string","default":"live","title":"Environment"}},{"name":"channel_id","in":"query","required":false,"schema":{"type":"string","default":"","title":"Channel Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: analytics:read."}},"/api/v1/projects/{project_id}/profiles":{"get":{"tags":["Profiles"],"summary":"Profiles","operationId":"profiles_api_v1_projects__project_id__profiles_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"channel_id","in":"query","required":false,"schema":{"type":"string","default":"","title":"Channel Id"}},{"name":"external_id","in":"query","required":false,"schema":{"type":"string","default":"","title":"External Id"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: profiles:read."}},"/api/v1/projects/{project_id}/messages":{"post":{"tags":["Messages"],"summary":"Send Message","operationId":"send_message_api_v1_projects__project_id__messages_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":8,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: messages:write."}},"/api/v1/projects/{project_id}/events":{"post":{"tags":["Events"],"summary":"Send Event","operationId":"send_event_api_v1_projects__project_id__events_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__integrations__api__EventBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: events:write."}},"/api/v1/projects/{project_id}/operations":{"get":{"tags":["Integrations"],"summary":"Operations","operationId":"operations_api_v1_projects__project_id__operations_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: integrations:read."}},"/api/v1/projects/{project_id}/operations/{operation_id}/runs":{"post":{"tags":["Integrations"],"summary":"Public Run","operationId":"public_run_api_v1_projects__project_id__operations__operation_id__runs_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"operation_id","in":"path","required":true,"schema":{"type":"string","title":"Operation Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":8,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__integrations__api__RunBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: integrations:run. Payment operations also require payments:write."}},"/api/v1/projects/{project_id}/jobs/{job_id}":{"get":{"tags":["Integrations"],"summary":"Public Job","operationId":"public_job_api_v1_projects__project_id__jobs__job_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: integrations:read."}},"/api/v1/projects/{project_id}/audit":{"get":{"tags":["Events"],"summary":"Audit","operationId":"audit_api_v1_projects__project_id__audit_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"after","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"After"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: audit:read."}},"/api/v1/projects/{project_id}/payments":{"get":{"tags":["Payments"],"summary":"Payments","operationId":"payments_api_v1_projects__project_id__payments_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: payments:read."}},"/api/v1/projects/{project_id}/payments/{order_id}/refund":{"post":{"tags":["Payments"],"summary":"Public Refund","operationId":"public_refund_api_v1_projects__project_id__payments__order_id__refund_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"order_id","in":"path","required":true,"schema":{"type":"string","title":"Order Id"}},{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":8,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefundBody"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: payments:write."}},"/api/v1/projects/{project_id}/profiles/{profile_id}":{"get":{"summary":"Service Profile","operationId":"service_profile_api_v1_projects__project_id__profiles__profile_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"profile_id","in":"path","required":true,"schema":{"type":"string","title":"Profile Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: profiles:read."},"patch":{"summary":"Service Update","operationId":"service_update_api_v1_projects__project_id__profiles__profile_id__patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"profile_id","in":"path","required":true,"schema":{"type":"string","title":"Profile Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"400":{"description":"Request rejected; JSON detail explains the error."},"401":{"description":"Request rejected; JSON detail explains the error."},"403":{"description":"Request rejected; JSON detail explains the error."},"404":{"description":"Request rejected; JSON detail explains the error."},"409":{"description":"Request rejected; JSON detail explains the error."},"429":{"description":"Request rejected; JSON detail explains the error."}},"description":"Required scope: profiles:write."}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ProfileBody":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"state":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"State"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"access":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Access"}},"type":"object","title":"ProfileBody"},"RefundBody":{"properties":{"receipt":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Receipt"}},"type":"object","title":"RefundBody"},"RowsBody":{"properties":{"environment":{"type":"string","enum":["sandbox","live"],"title":"Environment","default":"sandbox"},"rows":{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":5000,"title":"Rows"},"replace":{"type":"boolean","title":"Replace","default":false},"revision":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Revision"}},"type":"object","required":["rows"],"title":"RowsBody"},"SendBody":{"properties":{"identity_id":{"type":"string","title":"Identity Id"},"text":{"type":"string","maxLength":3000,"minLength":1,"title":"Text"},"buttons":{"items":{},"type":"array","maxItems":12,"title":"Buttons"},"keyboard":{"type":"string","title":"Keyboard","default":"reply"},"columns":{"type":"integer","maximum":3.0,"minimum":1.0,"title":"Columns","default":1},"format":{"type":"string","title":"Format","default":"plain"},"image":{"type":"string","maxLength":2000,"title":"Image","default":""},"variants":{"additionalProperties":true,"type":"object","title":"Variants"}},"type":"object","required":["identity_id","text"],"title":"SendBody"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"app__integrations__api__EventBody":{"properties":{"event_id":{"type":"string","maxLength":100,"minLength":1,"title":"Event Id"},"identity_id":{"type":"string","title":"Identity Id"},"text":{"type":"string","maxLength":3000,"minLength":1,"title":"Text"},"data":{"additionalProperties":true,"type":"object","title":"Data"}},"type":"object","required":["event_id","identity_id","text"],"title":"EventBody"},"app__integrations__api__RunBody":{"properties":{"input":{"additionalProperties":true,"type":"object","title":"Input"},"identity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identity Id"},"environment":{"type":"string","title":"Environment","default":"sandbox"}},"type":"object","title":"RunBody"},"app__workflows__api__EventBody":{"properties":{"event_id":{"type":"string","maxLength":100,"minLength":8,"pattern":"^[A-Za-z0-9_.:-]+$","title":"Event Id"},"source":{"type":"string","pattern":"^custom\\.[A-Za-z0-9_.-]{1,60}$","title":"Source"},"environment":{"type":"string","title":"Environment","default":"sandbox"},"data":{"additionalProperties":true,"type":"object","title":"Data"},"identity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identity Id"}},"type":"object","required":["event_id","source"],"title":"EventBody"},"app__workflows__api__RunBody":{"properties":{"input":{"additionalProperties":true,"type":"object","title":"Input"},"identity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Identity Id"}},"type":"object","title":"RunBody"}},"securitySchemes":{"ProjectKey":{"type":"http","scheme":"bearer","description":"Scoped key from project → Operations and API."}}},"security":[{"ProjectKey":[]}]}