{"openapi":"3.1.0","info":{"title":"MSG91 (BYOK) API","version":"0.1.0","description":"MSG91 (BYOK) lets an AI assistant read your own MSG91 data through the MSG91 API with a key you supply (MSG91 auth key). Read-only: 12 tools (get_sms_report, get_otp_report, get_email_report, get_voice_report, get_whatsapp_report, get_rcs_report, get_email_logs, get_voice_logs, get_whatsapp_logs, list_voice_call_logs, list_voice_agents, list_email_templates). The BYOK key travels with each...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-msg91.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-msg91/docs"},"termsOfService":"https://connectorbay.com/byok-msg91/terms"},"servers":[{"url":"https://byok-msg91.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-msg91/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/get_sms_report":{"post":{"operationId":"get_sms_report","summary":"Daily SMS report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, cred","description":"Daily SMS report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, credits where the channel has them). Use for \"How many SMS did I send and deliver with MSG91 in the last two weeks\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD (not before 2024-01-01).","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 31 days.","maxLength":200,"title":"End Date","type":"string"}},"required":["start_date","end_date"],"title":"get_sms_reportArguments","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_otp_report":{"post":{"operationId":"get_otp_report","summary":"Daily OTP report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, cred","description":"Daily OTP report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, credits where the channel has them). Use for \"How many MSG91 OTPs were delivered this month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD (not before 2024-01-01).","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 31 days.","maxLength":200,"title":"End Date","type":"string"}},"required":["start_date","end_date"],"title":"get_otp_reportArguments","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_email_report":{"post":{"operationId":"get_email_report","summary":"Daily email report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, cr","description":"Daily email report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, credits where the channel has them). Use for \"How many MSG91 emails were delivered, opened and bounced this month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD (not before 2024-01-01).","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 31 days.","maxLength":200,"title":"End Date","type":"string"}},"required":["start_date","end_date"],"title":"get_email_reportArguments","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_voice_report":{"post":{"operationId":"get_voice_report","summary":"Daily voice call report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, faile","description":"Daily voice call report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, credits where the channel has them). Use for \"How many MSG91 voice calls were completed or unanswered this month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD (not before 2024-01-01).","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 31 days.","maxLength":200,"title":"End Date","type":"string"}},"required":["start_date","end_date"],"title":"get_voice_reportArguments","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_whatsapp_report":{"post":{"operationId":"get_whatsapp_report","summary":"Daily WhatsApp report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed,","description":"Daily WhatsApp report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, credits where the channel has them). Use for \"How many MSG91 WhatsApp messages were sent, delivered and read this month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD (not before 2024-01-01).","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 31 days.","maxLength":200,"title":"End Date","type":"string"}},"required":["start_date","end_date"],"title":"get_whatsapp_reportArguments","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_rcs_report":{"post":{"operationId":"get_rcs_report","summary":"Daily RCS report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, cred","description":"Daily RCS report for a date range of up to 31 days: per-day counts and the overall totals (sent, delivered, failed, credits where the channel has them). Use for \"How many MSG91 RCS messages were delivered and read this month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD (not before 2024-01-01).","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 31 days.","maxLength":200,"title":"End Date","type":"string"}},"required":["start_date","end_date"],"title":"get_rcs_reportArguments","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_email_logs":{"post":{"operationId":"get_email_logs","summary":"List individual email send records of a short period (at most 3 days, recent only): time, subject, sender domain, templa","description":"List individual email send records of a short period (at most 3 days, recent only): time, subject, sender domain, template, request id. Recipient addresses are not returned. Use for \"Which emails did MSG91 send in the last day or two\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD; must be within the last 3 days.","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 3 days.","maxLength":200,"title":"End Date","type":"string"},"request_id":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Only this request id.","title":"Request Id"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":50,"description":"How many log rows to return (default 50; the service itself defaults to 1000).","title":"Limit"}},"required":["start_date","end_date"],"title":"get_email_logsArguments","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_voice_logs":{"post":{"operationId":"get_voice_logs","summary":"List voice call records of a short period (at most 3 days, recent only): time, status, duration, charge, direction and c","description":"List voice call records of a short period (at most 3 days, recent only): time, status, duration, charge, direction and call id. Phone numbers are not returned. Use for \"Which MSG91 voice calls were made yesterday and how long did they last\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD; must be within the last 3 days.","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 3 days.","maxLength":200,"title":"End Date","type":"string"},"uuid":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Only this call uuid.","title":"Uuid"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":50,"description":"How many log rows to return (default 50; the service itself defaults to 1000).","title":"Limit"}},"required":["start_date","end_date"],"title":"get_voice_logsArguments","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_whatsapp_logs":{"post":{"operationId":"get_whatsapp_logs","summary":"List WhatsApp message records of a short period (at most 3 days, recent only): request time, status, direction, message ","description":"List WhatsApp message records of a short period (at most 3 days, recent only): request time, status, direction, message type, template language and failure reason. Customer numbers and message text are not returned. Use for \"Which MSG91 WhatsApp messages failed in the last two days\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"start_date":{"description":"First day, YYYY-MM-DD; must be within the last 3 days.","maxLength":200,"title":"Start Date","type":"string"},"end_date":{"description":"Last day, YYYY-MM-DD; the range is at most 3 days.","maxLength":200,"title":"End Date","type":"string"},"request_id":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Only this request id.","title":"Request Id"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":50,"description":"How many log rows to return (default 50; the service itself defaults to 1000).","title":"Limit"}},"required":["start_date","end_date"],"title":"get_whatsapp_logsArguments","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_voice_call_logs":{"post":{"operationId":"list_voice_call_logs","summary":"List recent voice call records of the account's voice product: source, destination, agent, durations, status, failure re","description":"List recent voice call records of the account's voice product: source, destination, agent, durations, status, failure reason and direction. Use for \"Show my latest MSG91 voice calls with agent and duration\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"list_voice_call_logsArguments","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_voice_agents":{"post":{"operationId":"list_voice_agents","summary":"List the voice agents of the company with their ids and usernames. Use for \"Which agents are set up in MSG91 voice\".","description":"List the voice agents of the company with their ids and usernames. Use for \"Which agents are set up in MSG91 voice\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"list_voice_agentsArguments","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_email_templates":{"post":{"operationId":"list_email_templates","summary":"List email templates (with versions) with paging, filtered by status and a keyword. Use for \"Which email templates do I ","description":"List email templates (with versions) with paging, filtered by status and a keyword. Use for \"Which email templates do I have in MSG91\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"per_page":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":25,"description":"Templates per page (1 to 100, default 25).","title":"Per Page"},"page":{"anyOf":[{"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"},"keyword":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Search text matched against the field named in search_in.","title":"Keyword"},"search_in":{"anyOf":[{"const":"name","type":"string"},{"type":"null"}],"default":"name","description":"Field to search: name (default).","title":"Search In"}},"title":"list_email_templatesArguments","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}}}}