{"openapi":"3.1.0","info":{"title":"Chaport (BYOK) API","version":"0.1.0","description":"Chaport (BYOK) lets an AI assistant read your own Chaport data through the Chaport API with a key you supply (Chaport access token). Read-only: 9 tools (list_operators, get_operator, list_visitors, get_visitor, get_visitor_current_chat, get_chat, list_chat_events, list_webhooks, get_webhook). The BYOK key travels with each request, is used for that one call only and is never stored, logged or...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-chaport.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-chaport/docs"},"termsOfService":"https://connectorbay.com/byok-chaport/terms"},"servers":[{"url":"https://byok-chaport.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-chaport/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_operators":{"post":{"operationId":"list_operators","summary":"List the operators (team members) with name, language, job title, role, last login and activity times and current status","description":"List the operators (team members) with name, language, job title, role, last login and activity times and current status. Email addresses are left out. Use for \"Which Chaport operators are online right now\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"list_operatorsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_operator":{"post":{"operationId":"get_operator","summary":"Get one operator by id with name, role, job title and presence status. Use for \"Show Chaport operator 59747c3ff779482201","description":"Get one operator by id with name, role, job title and presence status. Use for \"Show Chaport operator 59747c3ff77948220136b7b3\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"operator_id":{"description":"Operator id from list_operators.","maxLength":60,"title":"Operator Id","type":"string"}},"required":["operator_id"],"title":"get_operatorArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_visitors":{"post":{"operationId":"list_visitors","summary":"List visitors, most recent chat first, with name, source site, referrer, language, last seen, location, consents, UTM da","description":"List visitors, most recent chat first, with name, source site, referrer, language, last seen, location, consents, UTM data, browser and OS. Pages with links.next. Email, phone and notes are left out. Use for \"Who chatted with us on Chaport most recently\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"page":{"anyOf":[{"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Results page number, 1-indexed; follow links.next for the next page.","title":"Page"}},"title":"list_visitorsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_visitor":{"post":{"operationId":"get_visitor","summary":"Get one visitor by id with name, source site, referrer, language, last seen, location, consents, UTM data, browser and O","description":"Get one visitor by id with name, source site, referrer, language, last seen, location, consents, UTM data, browser and OS. Use for \"Show Chaport visitor 59747c3ff77948220136b7cd\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"visitor_id":{"description":"Visitor id from list_visitors.","maxLength":60,"title":"Visitor Id","type":"string"}},"required":["visitor_id"],"title":"get_visitorArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_visitor_current_chat":{"post":{"operationId":"get_visitor_current_chat","summary":"Get a visitor's current or most recent chat with stage, rating, operators, team, last message time and channel, and the ","description":"Get a visitor's current or most recent chat with stage, rating, operators, team, last message time and channel, and the chat events (messages). links.more lists older chats. Use for \"What did Chaport visitor 59747c3ff77948220136b7cd last chat about\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"visitor_id":{"description":"Visitor id from list_visitors.","maxLength":60,"title":"Visitor Id","type":"string"},"transcript":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"True to return the events as a transcript containing message events only.","title":"Transcript"}},"required":["visitor_id"],"title":"get_visitor_current_chatArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_chat":{"post":{"operationId":"get_chat","summary":"Get one chat by visitor id and chat id with stage, rating, operators, team, last message time and channel, and the chat ","description":"Get one chat by visitor id and chat id with stage, rating, operators, team, last message time and channel, and the chat events (messages). Use for \"Show Chaport chat 120904824\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"visitor_id":{"description":"Visitor id from list_visitors.","maxLength":60,"title":"Visitor Id","type":"string"},"chat_id":{"description":"Chat id (integer).","title":"Chat Id","type":"integer"},"transcript":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"True to return the events as a transcript containing message events only.","title":"Transcript"}},"required":["visitor_id","chat_id"],"title":"get_chatArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_chat_events":{"post":{"operationId":"list_chat_events","summary":"List all events of one chat (type and timestamp, plus the event details). Use for \"What happened in Chaport chat 1209048","description":"List all events of one chat (type and timestamp, plus the event details). Use for \"What happened in Chaport chat 120904824\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"visitor_id":{"description":"Visitor id from list_visitors.","maxLength":60,"title":"Visitor Id","type":"string"},"chat_id":{"description":"Chat id (integer).","title":"Chat Id","type":"integer"}},"required":["visitor_id","chat_id"],"title":"list_chat_eventsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_webhooks":{"post":{"operationId":"list_webhooks","summary":"List the webhook subscriptions with the events each listens to and the creation time. Target URLs are left out. Use for ","description":"List the webhook subscriptions with the events each listens to and the creation time. Target URLs are left out. Use for \"Which Chaport webhooks are set up\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"list_webhooksArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_webhook":{"post":{"operationId":"get_webhook","summary":"Get one webhook subscription by id: the events it listens to and its creation time. The target URL is left out. Use for ","description":"Get one webhook subscription by id: the events it listens to and its creation time. The target URL is left out. Use for \"Show Chaport webhook 59747c3ff77948220136b7aa\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"hook_id":{"description":"Webhook id from list_webhooks.","maxLength":60,"title":"Hook Id","type":"string"}},"required":["hook_id"],"title":"get_webhookArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}