{"openapi":"3.1.0","info":{"title":"Gorgias Configuration (BYOK) API","version":"0.1.0","description":"Gorgias Configuration (BYOK) lets an AI assistant read your own Gorgias Configuration data through the Gorgias Configuration API with a key you supply (your Gorgias account email address (the API username)). Read-only: 8 tools (list_macros, get_macro, list_rules, get_rule, list_teams, list_satisfaction_surveys, list_widgets, list_account_settings). The BYOK key travels with each request, is used...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-gorgias-configuration.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-gorgias-configuration/docs"},"termsOfService":"https://connectorbay.com/byok-gorgias-configuration/terms"},"servers":[{"url":"https://byok-gorgias-configuration.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-gorgias-configuration/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_macros":{"post":{"operationId":"list_macros","summary":"List macros (saved reply templates) with name, intent, language, usage count and dates, optionally searched, filtered by","description":"List macros (saved reply templates) with name, intent, language, usage count and dates, optionally searched, filtered by archived state and ordered. Cursor-paged. Use for \"Which Gorgias macros are used most\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"search":{"anyOf":[{"maxLength":100,"type":"string"},{"type":"null"}],"default":null,"description":"Only macros whose name contains this text.","title":"Search"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":false,"description":"True for only archived macros (the API default is false).","title":"Archived"},"order_by":{"anyOf":[{"enum":["name","created_datetime","updated_datetime","usage","language","name:asc","name:desc","created_datetime:asc","created_datetime:desc","updated_datetime:asc","updated_datetime:desc","usage:asc","usage:desc","language:asc","language:desc"],"type":"string"},{"type":"null"}],"default":"usage","description":"Order, for example usage:desc, name:asc, created_datetime:desc, updated_datetime:desc or language:asc.","title":"Order By"},"limit":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":30,"description":"Maximum number of items to return (typically up to 100).","title":"Limit"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Cursor from meta.next_cursor of the previous answer for the next page; empty for the first page.","title":"Cursor"}},"required":["subdomain"],"title":"list_macrosArguments","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_macro":{"post":{"operationId":"get_macro","summary":"Get one macro by id: name, intent, language, usage, dates and its actions (the reply text and tags it applies). Use for ","description":"Get one macro by id: name, intent, language, usage, dates and its actions (the reply text and tags it applies). Use for \"What does Gorgias macro 12 do\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"macro_id":{"description":"Id of the macro (a number such as 12).","maximum":1000000000,"minimum":1,"title":"Macro Id","type":"integer"}},"required":["subdomain","macro_id"],"title":"get_macroArguments","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_rules":{"post":{"operationId":"list_rules","summary":"List automation rules with name, description, trigger event types, priority, deactivation time and dates (rule code is n","description":"List automation rules with name, description, trigger event types, priority, deactivation time and dates (rule code is not returned). Cursor-paged. Use for \"Which Gorgias rules are active\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"search":{"anyOf":[{"maxLength":100,"type":"string"},{"type":"null"}],"default":null,"description":"Case-insensitive search by rule name.","title":"Search"},"limit":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":100,"description":"Maximum number of items to return (typically up to 100).","title":"Limit"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Cursor from meta.next_cursor of the previous answer for the next page; empty for the first page.","title":"Cursor"},"order_by":{"anyOf":[{"enum":["created_datetime:asc","created_datetime:desc"],"type":"string"},{"type":"null"}],"default":"created_datetime:desc","description":"Order by creation time.","title":"Order By"}},"required":["subdomain"],"title":"list_rulesArguments","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_rule":{"post":{"operationId":"get_rule","summary":"Get one automation rule by id, including its rule code. Use for \"Show the code of Gorgias rule 5\".","description":"Get one automation rule by id, including its rule code. Use for \"Show the code of Gorgias rule 5\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"rule_id":{"description":"Id of the rule (a number such as 5).","maximum":1000000000,"minimum":1,"title":"Rule Id","type":"integer"}},"required":["subdomain","rule_id"],"title":"get_ruleArguments","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_teams":{"post":{"operationId":"list_teams","summary":"List agent teams with name, description and creation time (member emails are not returned). Cursor-paged. Use for \"Which","description":"List agent teams with name, description and creation time (member emails are not returned). Cursor-paged. Use for \"Which teams exist in our Gorgias\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"limit":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":30,"description":"Maximum number of items to return (typically up to 100).","title":"Limit"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Cursor from meta.next_cursor of the previous answer for the next page; empty for the first page.","title":"Cursor"},"order_by":{"anyOf":[{"enum":["created_datetime:asc","created_datetime:desc","name:asc","name:desc"],"type":"string"},{"type":"null"}],"default":"created_datetime:desc","description":"Order: created_datetime or name, ascending or descending.","title":"Order By"}},"required":["subdomain"],"title":"list_teamsArguments","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_satisfaction_surveys":{"post":{"operationId":"list_satisfaction_surveys","summary":"List satisfaction survey records with score, ticket id and sent and scored times (comment text and customer ids are not ","description":"List satisfaction survey records with score, ticket id and sent and scored times (comment text and customer ids are not returned). Cursor-paged. Use for \"What satisfaction scores have customers given in Gorgias\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"limit":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":30,"description":"Maximum number of items to return (typically up to 100).","title":"Limit"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Cursor from meta.next_cursor of the previous answer for the next page; empty for the first page.","title":"Cursor"},"ticket_id":{"anyOf":[{"maximum":1000000000000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Only surveys for this ticket id.","title":"Ticket Id"},"order_by":{"anyOf":[{"enum":["created_datetime:asc","created_datetime:desc"],"type":"string"},{"type":"null"}],"default":"created_datetime:desc","description":"Order by creation time.","title":"Order By"}},"required":["subdomain"],"title":"list_satisfaction_surveysArguments","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_widgets":{"post":{"operationId":"list_widgets","summary":"List sidebar widgets with context, type, order, linked integration or app and dates. Cursor-paged. Use for \"Which Gorgia","description":"List sidebar widgets with context, type, order, linked integration or app and dates. Cursor-paged. Use for \"Which Gorgias sidebar widgets are configured\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"limit":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":30,"description":"Maximum number of items to return (typically up to 100).","title":"Limit"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Cursor from meta.next_cursor of the previous answer for the next page; empty for the first page.","title":"Cursor"},"integration_id":{"anyOf":[{"maximum":1000000000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Only widgets of this integration id.","title":"Integration Id"},"order_by":{"anyOf":[{"enum":["created_datetime:asc","created_datetime:desc","order:asc","order:desc"],"type":"string"},{"type":"null"}],"default":"created_datetime:desc","description":"Order: created_datetime or order, ascending or descending.","title":"Order By"}},"required":["subdomain"],"title":"list_widgetsArguments","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_account_settings":{"post":{"operationId":"list_account_settings","summary":"List account settings of one kind: business-hours (weekly opening days and times), satisfaction-surveys, ticket-assignme","description":"List account settings of one kind: business-hours (weekly opening days and times), satisfaction-surveys, ticket-assignment, auto-merge, auto-split or limits. Use for \"What business hours are set in our Gorgias account\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"subdomain":{"description":"Your Gorgias subdomain: the part before .gorgias.com, for example 'mystore' for mystore.gorgias.com.","maxLength":200,"pattern":"^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$","title":"Subdomain","type":"string"},"type":{"description":"Kind of setting.","enum":["business-hours","satisfaction-surveys","ticket-assignment","auto-merge","auto-split","limits"],"title":"Type","type":"string"}},"required":["subdomain","type"],"title":"list_account_settingsArguments","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}}}}