{"openapi":"3.1.0","info":{"title":"OutboundSync API","version":"1.0.0","description":"Public REST API for OutboundSync account introspection and pipeline status checks.\nAuthenticate with a Bearer token: `Authorization: Bearer osapi_<key>`.\n\nMachine-readable contract for API v1. Human reference:\nhttps://outboundsync.com/docs/api/v1\n","contact":{"name":"OutboundSync","url":"https://outboundsync.com"}},"servers":[{"url":"https://app.outboundsync.com","description":"Production"}],"security":[{"bearerAuth":[]}],"tags":[{"name":"Discovery","description":"Auth-free OpenAPI document endpoints"},{"name":"Platform","description":"Public, unauthenticated platform health checks"},{"name":"Account","description":"Identity and pipeline readiness"},{"name":"Connections","description":"CRM connections"},{"name":"Sources","description":"Inbound sequencer paste URLs"}],"paths":{"/health/live":{"get":{"operationId":"getHealthLive","tags":["Platform"],"summary":"Platform liveness","description":"Liveness probe. Returns 200 whenever the platform process is reachable\nand does no downstream checks. No API key required. Lives at the host\nroot, not under /api/v1.\n","security":[],"responses":{"200":{"description":"Platform process is up","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthLiveResponse"}}}}}}},"/health/ready":{"get":{"operationId":"getHealthReady","tags":["Platform"],"summary":"Platform readiness","description":"Readiness probe. Reports whether the platform can receive and sync\nevents right now, with per-component checks. `GET /health` is an alias.\nReturns 200 for operational/partial_outage and 503 for a total outage.\nNo API key required. Lives at the host root, not under /api/v1.\n","security":[],"responses":{"200":{"description":"Readiness snapshot (operational or partial_outage)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthReadyResponse"}}}},"503":{"description":"Total outage — every component check is in outage","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthReadyResponse"}}}}}}},"/api/v1/openapi.json":{"get":{"operationId":"getOpenApiJson","tags":["Discovery"],"summary":"OpenAPI 3.1 document (JSON)","description":"Auth-free machine-readable API contract.","security":[],"responses":{"200":{"description":"OpenAPI 3.1 document","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}}}}},"/api/v1/openapi.yaml":{"get":{"operationId":"getOpenApiYaml","tags":["Discovery"],"summary":"OpenAPI 3.1 document (YAML)","description":"Auth-free machine-readable API contract (source form).","security":[],"responses":{"200":{"description":"OpenAPI 3.1 document","content":{"application/yaml":{"schema":{"type":"string"}}}}}}},"/api/v1/me":{"get":{"operationId":"getMe","tags":["Account"],"summary":"API key identity and related links","description":"Returns account, API key metadata, accessible CRM connections, and links\nto related v1 endpoints. Use as the bootstrap call after authentication.\n","responses":{"200":{"description":"Identity and discovery links","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/api/v1/account/status":{"get":{"operationId":"getAccountStatus","tags":["Account"],"summary":"Pipeline readiness","description":"Point-in-time pipeline status across all connections the key can access.\nAuthenticated-but-not-ready returns HTTP 200 with `ready: false`.\n","responses":{"200":{"description":"Readiness snapshot","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountStatusResponse"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/api/v1/connections":{"get":{"operationId":"listConnections","tags":["Connections"],"summary":"List CRM connections","description":"CRM connections with embedded status and capability flags.","responses":{"200":{"description":"Named list wrapper","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionsResponse"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/api/v1/sources":{"get":{"operationId":"listSources","tags":["Sources"],"summary":"List inbound sources","description":"Inbound sources with the URL to paste into a sequencer, platform,\nconfig summary, and destination bindings.\n","responses":{"200":{"description":"Named list wrapper","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SourcesResponse"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"osapi","description":"OutboundSync API key. Pass as `Authorization: Bearer osapi_<key>`.\nKeys are created in the OutboundSync dashboard.\n"}},"responses":{"Unauthorized":{"description":"Missing, invalid, or revoked API key","headers":{"WWW-Authenticate":{"schema":{"type":"string","example":"Bearer realm=\"OutboundSync API\""}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiError"}}}},"Forbidden":{"description":"Valid key but no API-enabled connections (`canUseApi`)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiError"}}}},"TooManyRequests":{"description":"Per-IP or per-account rate limit exceeded","headers":{"Retry-After":{"schema":{"type":"string","description":"Seconds until the client may retry"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiError"}}}}},"schemas":{"HealthLiveResponse":{"type":"object","additionalProperties":true,"required":["schema_version","status"],"properties":{"schema_version":{"type":"integer","description":"Version of this response contract. Currently 2."},"status":{"type":"string","description":"Always \"operational\" when the process is reachable."}}},"HealthReadyResponse":{"type":"object","additionalProperties":true,"required":["schema_version","status"],"properties":{"schema_version":{"type":"integer","description":"Version of this response contract. Currently 2."},"status":{"type":"string","enum":["operational","partial_outage","major_outage"]},"checks":{"type":"object","additionalProperties":{"type":"string","enum":["operational","outage"]},"description":"Per-component status. Components present depend on the deployment\n(production/staging include the destination workers; local omits\nthem). Treat unknown keys as forward-compatible.\n"}}},"ApiError":{"type":"object","additionalProperties":false,"required":["statusCode","message","error"],"properties":{"statusCode":{"type":"integer"},"message":{"type":"string"},"error":{"type":"string"}}},"MeRelatedLink":{"type":"object","additionalProperties":false,"required":["href","description"],"properties":{"href":{"type":"string"},"description":{"type":"string"}}},"MeLinks":{"type":"object","additionalProperties":false,"required":["accountStatus","connections","sources","documentation","openapi"],"properties":{"accountStatus":{"$ref":"#/components/schemas/MeRelatedLink"},"connections":{"$ref":"#/components/schemas/MeRelatedLink"},"sources":{"$ref":"#/components/schemas/MeRelatedLink"},"documentation":{"$ref":"#/components/schemas/MeRelatedLink"},"openapi":{"$ref":"#/components/schemas/MeRelatedLink"}}},"MeAccount":{"type":"object","additionalProperties":false,"required":["id","email"],"properties":{"id":{"type":"integer"},"email":{"type":["string","null"]}}},"MeApiKey":{"type":"object","additionalProperties":false,"required":["name","scopes","connectionScope","connectionId"],"properties":{"name":{"type":"string"},"scopes":{"type":"array","items":{"type":"string"}},"connectionScope":{"type":"string","enum":["account","connection"]},"connectionId":{"type":["integer","null"],"description":"Set when connectionScope is connection; null for account-scoped keys.\nSame as connections[].id when scoped.\n"}}},"MeConnection":{"type":"object","additionalProperties":false,"required":["id","crm","organizationId","organizationDomain"],"properties":{"id":{"type":"integer"},"crm":{"type":"string"},"organizationId":{"type":["string","null"]},"organizationDomain":{"type":["string","null"]}}},"MeResponse":{"type":"object","additionalProperties":false,"required":["account","apiKey","connections","links"],"properties":{"account":{"$ref":"#/components/schemas/MeAccount"},"apiKey":{"$ref":"#/components/schemas/MeApiKey"},"connections":{"type":"array","items":{"$ref":"#/components/schemas/MeConnection"}},"links":{"$ref":"#/components/schemas/MeLinks"}}},"BlockerCode":{"type":"string","enum":["crm_disconnected","sync_not_enabled","no_sources"]},"WarningCode":{"type":"string","enum":["destinations_not_configured","blocklists_not_configured","blocklists_error"]},"StatusBlocker":{"type":"object","additionalProperties":false,"required":["code","connectionId","crm","message","remediation","docUrl"],"properties":{"code":{"$ref":"#/components/schemas/BlockerCode"},"connectionId":{"type":"integer"},"crm":{"type":"string"},"message":{"type":"string"},"remediation":{"type":"string"},"docUrl":{"type":"string","format":"uri"}}},"StatusWarning":{"type":"object","additionalProperties":false,"required":["code","connectionId","crm","message","remediation","docUrl"],"properties":{"code":{"$ref":"#/components/schemas/WarningCode"},"connectionId":{"type":"integer"},"crm":{"type":"string"},"message":{"type":"string"},"remediation":{"type":"string"},"docUrl":{"type":"string","format":"uri"}}},"CrmConnectionStatus":{"type":"object","additionalProperties":false,"required":["status","crm","organizationId","organizationDomain"],"properties":{"status":{"type":"string","enum":["ready","disconnected"]},"crm":{"type":"string"},"organizationId":{"type":["string","null"]},"organizationDomain":{"type":["string","null"]}}},"SourcesStatus":{"type":"object","additionalProperties":false,"required":["status","count","platforms"],"properties":{"status":{"type":"string","enum":["ready","not_configured","disabled"]},"count":{"type":"integer"},"platforms":{"type":"array","items":{"type":"string"}}}},"DestinationsStatus":{"type":"object","additionalProperties":false,"required":["status","count","eventTypes"],"properties":{"status":{"type":"string","enum":["ready","not_configured","disabled"]},"count":{"type":"integer"},"eventTypes":{"type":"array","items":{"type":"string"}}}},"BlocklistsStatus":{"type":"object","additionalProperties":false,"required":["status","enabledCount","lastError","lastFetchedAt"],"properties":{"status":{"type":"string","enum":["ready","not_configured","disabled","error"]},"enabledCount":{"type":"integer"},"lastError":{"type":["string","null"]},"lastFetchedAt":{"type":["string","null"],"format":"date-time"}}},"ConnectionStatus":{"type":"object","additionalProperties":false,"required":["connectionId","crm","ready","crmConnection","sources","destinations","blocklists"],"properties":{"connectionId":{"type":"integer"},"crm":{"type":"string"},"ready":{"type":"boolean"},"crmConnection":{"$ref":"#/components/schemas/CrmConnectionStatus"},"sources":{"$ref":"#/components/schemas/SourcesStatus"},"destinations":{"$ref":"#/components/schemas/DestinationsStatus"},"blocklists":{"$ref":"#/components/schemas/BlocklistsStatus"}}},"AccountStatusResponse":{"type":"object","additionalProperties":false,"required":["ready","checkedAt","connections","blockers","warnings"],"properties":{"ready":{"type":"boolean"},"checkedAt":{"type":"string","format":"date-time"},"connections":{"type":"array","items":{"$ref":"#/components/schemas/ConnectionStatus"}},"blockers":{"type":"array","items":{"$ref":"#/components/schemas/StatusBlocker"}},"warnings":{"type":"array","items":{"$ref":"#/components/schemas/StatusWarning"}}}},"ConnectionCapabilities":{"type":"object","additionalProperties":false,"required":["sync","destinations","blocklists"],"properties":{"sync":{"type":"boolean"},"destinations":{"type":"boolean"},"blocklists":{"type":"boolean"}}},"ConnectionResource":{"type":"object","additionalProperties":false,"required":["id","crm","status","organizationId","organizationDomain","capabilities","createdAt"],"properties":{"id":{"type":"integer"},"crm":{"type":"string"},"status":{"type":"string","enum":["ready","disconnected"]},"organizationId":{"type":["string","null"]},"organizationDomain":{"type":["string","null"]},"capabilities":{"$ref":"#/components/schemas/ConnectionCapabilities"},"createdAt":{"type":"string","format":"date-time"}}},"ConnectionsResponse":{"type":"object","additionalProperties":false,"required":["connections"],"properties":{"connections":{"type":"array","items":{"$ref":"#/components/schemas/ConnectionResource"}}}},"SourceConfig":{"type":"object","additionalProperties":false,"required":["createOrUpdateCompany","createOrUpdateTask","assignContactOwner","salesforceObjectType"],"properties":{"createOrUpdateCompany":{"type":"boolean"},"createOrUpdateTask":{"type":"boolean"},"assignContactOwner":{"type":"boolean"},"salesforceObjectType":{"type":["string","null"]}}},"SourceDestination":{"type":"object","additionalProperties":false,"required":["url","description","eventTypes","isDelayed"],"properties":{"url":{"type":"string","format":"uri"},"description":{"type":"string"},"eventTypes":{"type":"array","items":{"type":"string"}},"isDelayed":{"type":"boolean"}}},"Source":{"type":"object","additionalProperties":false,"required":["id","url","platform","connectionId","crm","config","destinations","createdAt"],"properties":{"id":{"type":"integer"},"url":{"type":"string","format":"uri","description":"Paste URL for the sequencer (includes webhook ingress code)."},"platform":{"type":"string"},"connectionId":{"type":"integer"},"crm":{"type":"string"},"config":{"$ref":"#/components/schemas/SourceConfig"},"destinations":{"type":"array","items":{"$ref":"#/components/schemas/SourceDestination"}},"createdAt":{"type":"string","format":"date-time"}}},"SourcesResponse":{"type":"object","additionalProperties":false,"required":["sources"],"properties":{"sources":{"type":"array","items":{"$ref":"#/components/schemas/Source"}}}}}}}