{"openapi":"3.1.0","info":{"title":"smsmode (BYOK) API","version":"0.1.0","description":"smsmode (BYOK) lets an AI assistant read your own smsmode data through the smsmode API with a key you supply (smsmode API key). Read-only: 8 tools (list_organisations, get_organisation, list_channels, get_channel, list_consumptions, list_credit_transfers, list_campaigns, get_campaign). The BYOK key travels with each request, is used for that one call only and is never stored, logged or cached; it...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-smsmode.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-smsmode/docs"},"termsOfService":"https://connectorbay.com/byok-smsmode/terms"},"servers":[{"url":"https://byok-smsmode.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-smsmode/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_organisations":{"post":{"operationId":"list_organisations","summary":"List the organisations (account and sub-accounts) with state, balance, payment type and monthly consumption against its ","description":"List the organisations (account and sub-accounts) with state, balance, payment type and monthly consumption against its limit. Contact and billing details are not returned. Use for \"What is the balance and monthly SMS spend of my smsmode organisations\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"name":{"anyOf":[{"maxLength":20,"type":"string"},{"type":"null"}],"default":null,"description":"Only organisations whose name matches this text (max 20 characters).","title":"Name"},"sort_by_name":{"anyOf":[{"enum":["ASC","DESC"],"type":"string"},{"type":"null"}],"default":null,"description":"Order by name.","title":"Sort By Name"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Items per page (1 to 100).","title":"Page Size"}},"title":"list_organisationsArguments","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_organisation":{"post":{"operationId":"get_organisation","summary":"Get one organisation: state, balance, payment type and monthly consumption against its limit. Contact and billing detail","description":"Get one organisation: state, balance, payment type and monthly consumption against its limit. Contact and billing details are not returned. Use for \"What is the balance of smsmode organisation 0cb2db9b\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"organisation_id":{"description":"Organisation id (UUID) from list_organisations.","maxLength":60,"title":"Organisation Id","type":"string"}},"required":["organisation_id"],"title":"get_organisationArguments","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_channels":{"post":{"operationId":"list_channels","summary":"List an organisation's SMS and RCS channels with flow (marketing, transactional, OTP), sender ids, daily and monthly con","description":"List an organisation's SMS and RCS channels with flow (marketing, transactional, OTP), sender ids, daily and monthly consumption and limits. Use for \"Which smsmode channels do I have and how close are they to their daily limits\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"organisation_id":{"description":"Organisation id (UUID) from list_organisations.","maxLength":60,"title":"Organisation Id","type":"string"},"name":{"anyOf":[{"maxLength":15,"type":"string"},{"type":"null"}],"default":null,"description":"Only channels whose name matches this text (max 15 characters).","title":"Name"},"channel_type":{"anyOf":[{"enum":["SMS","RCS"],"type":"string"},{"type":"null"}],"default":null,"description":"Only channels of this type.","title":"Channel Type"},"flow":{"anyOf":[{"enum":["MARKETING","TRANSACTIONAL","OTP"],"type":"string"},{"type":"null"}],"default":null,"description":"Only channels of this flow.","title":"Flow"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Items per page (1 to 100).","title":"Page Size"}},"required":["organisation_id"],"title":"list_channelsArguments","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_channel":{"post":{"operationId":"get_channel","summary":"Get one channel's flow, sender ids, daily and monthly consumption and limits, and archive period. Use for \"What are the ","description":"Get one channel's flow, sender ids, daily and monthly consumption and limits, and archive period. Use for \"What are the limits of smsmode channel 67c15045\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"organisation_id":{"description":"Organisation id (UUID) from list_organisations.","maxLength":60,"title":"Organisation Id","type":"string"},"channel_id":{"description":"Channel id (UUID) from list_channels.","maxLength":60,"title":"Channel Id","type":"string"}},"required":["organisation_id","channel_id"],"title":"get_channelArguments","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_consumptions":{"post":{"operationId":"list_consumptions","summary":"List a channel's monthly or daily message consumption: quantity and price per period. Use for \"How many messages and how","description":"List a channel's monthly or daily message consumption: quantity and price per period. Use for \"How many messages and how much did my smsmode channel use each month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"channel_id":{"description":"Channel id (UUID) from list_channels.","maxLength":60,"title":"Channel Id","type":"string"},"start_date":{"anyOf":[{"maxLength":10,"type":"string"},{"type":"null"}],"default":null,"description":"Start date, ISO 8601 (YYYY-MM-DD).","title":"Start Date"},"end_date":{"anyOf":[{"maxLength":10,"type":"string"},{"type":"null"}],"default":null,"description":"End date, ISO 8601 (YYYY-MM-DD).","title":"End Date"},"period_type":{"anyOf":[{"enum":["MONTH","DAY"],"type":"string"},{"type":"null"}],"default":"MONTH","description":"Aggregate by MONTH or DAY.","title":"Period Type"},"consumption_type":{"anyOf":[{"enum":["SMS_MONTH","SMS_DAY"],"type":"string"},{"type":"null"}],"default":"SMS_MONTH","description":"SMS_MONTH or SMS_DAY.","title":"Consumption Type"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Items per page (1 to 100).","title":"Page Size"}},"required":["channel_id"],"title":"list_consumptionsArguments","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_credit_transfers":{"post":{"operationId":"list_credit_transfers","summary":"List credit transfers between an organisation and its sub-organisations: direction, source and destination names, amount","description":"List credit transfers between an organisation and its sub-organisations: direction, source and destination names, amount, currency and reference. Use for \"What credit did I move between smsmode sub-accounts\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"organisation_id":{"description":"Organisation id (UUID) from list_organisations.","maxLength":60,"title":"Organisation Id","type":"string"},"transfer_type":{"anyOf":[{"enum":["DEBIT","CREDIT"],"type":"string"},{"type":"null"}],"default":null,"description":"DEBIT or CREDIT.","title":"Transfer Type"},"reference":{"anyOf":[{"maxLength":50,"type":"string"},{"type":"null"}],"default":null,"description":"Only transfers with this reference (max 50 characters).","title":"Reference"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Items per page (1 to 100).","title":"Page Size"}},"required":["organisation_id"],"title":"list_credit_transfersArguments","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_campaigns":{"post":{"operationId":"list_campaigns","summary":"List SMS campaigns of a channel with send and end dates, sender, message count, price and status (scheduled, ongoing, en","description":"List SMS campaigns of a channel with send and end dates, sender, message count, price and status (scheduled, ongoing, ended). Message text and recipients are not returned. Use for \"Which SMS campaigns did I send through smsmode this month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"channel_id":{"description":"Channel id (UUID) from list_channels.","maxLength":60,"title":"Channel Id","type":"string"},"start_date":{"anyOf":[{"maxLength":30,"type":"string"},{"type":"null"}],"default":null,"description":"Start date-time, ISO 8601.","title":"Start Date"},"end_date":{"anyOf":[{"maxLength":30,"type":"string"},{"type":"null"}],"default":null,"description":"End date-time, ISO 8601.","title":"End Date"},"status":{"anyOf":[{"enum":["SCHEDULED","ONGOING","ENDED"],"type":"string"},{"type":"null"}],"default":null,"description":"Only campaigns with this status.","title":"Status"},"encoding":{"anyOf":[{"enum":["GSM7","UNICODE"],"type":"string"},{"type":"null"}],"default":null,"description":"Only GSM7 or UNICODE campaigns.","title":"Encoding"},"ref_client":{"anyOf":[{"maxLength":140,"type":"string"},{"type":"null"}],"default":null,"description":"Only campaigns with this client reference (3 to 140 characters).","title":"Ref Client"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Items per page (1 to 100).","title":"Page Size"}},"required":["channel_id"],"title":"list_campaignsArguments","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_campaign":{"post":{"operationId":"get_campaign","summary":"Get one SMS campaign: dates, sender, message count, price and status. Message text and recipients are not returned. Use ","description":"Get one SMS campaign: dates, sender, message count, price and status. Message text and recipients are not returned. Use for \"What is the status of smsmode campaign 67c15045\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"channel_id":{"description":"Channel id (UUID) from list_channels.","maxLength":60,"title":"Channel Id","type":"string"},"campaign_id":{"description":"Campaign id (UUID) from list_campaigns.","maxLength":60,"title":"Campaign Id","type":"string"}},"required":["channel_id","campaign_id"],"title":"get_campaignArguments","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}}}}