GET/api/v1/sms/providers
SMS providers, built in and custom, removed ones included.
- CLI
sendmock sms providers list- MCP tool
sendmock_sms_provider_list- In the app
- SMS > Providers
Answer
200 MessageProviderDefinition[]
/api/v1/sms/providersSMS providers, built in and custom, removed ones included.
sendmock sms providers listsendmock_sms_provider_list200 MessageProviderDefinition[]
/api/v1/sms/providersAdd an SMS provider, blank or copied from another.
sendmock sms providers createsendmock_sms_provider_createMessageProviderCreateRequest : Body of POST /api/v1/emails/providers and /api/v1/sms/providers.
| Field | Type | Description |
|---|---|---|
| name | string | The new provider's name.Example: SSL Wireless |
| key | string | Its key in /providers/<key>/... paths and on messages; lowercase, fixed after creation.Example: sslwireless |
| start_from | string | null | A provider of the same area to copy, or null to start blank.Example: twilio |
201 MessageProviderDefinition
Errors: 400, 409, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}One provider definition; secret credentials masked.
sendmock sms providers show <providerKey>sendmock_sms_provider_get200 MessageProviderDefinition
Errors: 404, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}Change a provider; 400 with the problems for template errors, bad paths or a path clash.
sendmock sms providers update <providerKey>sendmock_sms_provider_updateMessageProviderInput : Body of PATCH .../providers/{providerKey}; the key and area are fixed.
| Field | Type | Description |
|---|---|---|
| key | string | The /providers/<key>/... path and the provider value stored on each message; lowercase, fixed after creation.Example: sendgrid |
| name | string | The provider's name, shown on messages and in pickers.Example: SendGrid |
| accent | string | #rrggbb, used on its badge.Example: #1a82e2 |
| is_enabled | boolean | Off providers answer nothing; their paths get SendMock's native 404.Example: true |
| host | string | null | The provider's API host, used on the provider port to tell apart providers that share a path; null when not needed.Example: api.sendgrid.com |
| credentials | ProviderCredential[] | The credentials your app is configured with. |
| check_credentials | boolean | Off by default: any credentials are accepted. On: wrong ones get the provider's unauthorized answer.Example: false |
| operations | ProviderOperation[] | The requests it answers. |
| field_mapping | ProviderFieldMapping[] | Where each part of a sent message is read from; anything else is kept as metadata. |
| validation_rules | ProviderValidationRule[] | The checks run on each send, in order. |
| success_response | ProviderResponseTemplate | The answer to a request that passes every check. |
| error_responses | ProviderErrorResponse[] | The answer for each kind of error. |
| message_id_template | string | The provider's id for each message, a template.Example: <{{ uuid() }}@sendmock.local> |
| callback_template_key | string | null | The webhook template its status callbacks and inbound messages are sent with; null sends none.Example: sendgrid-event |
| status_names | object | The provider's name for each SendMock status. |
| outcome_error_codes | object | SMS only: the provider's error code for each delivery outcome, so test numbers fail with its own codes. |
200 MessageProviderDefinition
Errors: 400, 404, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}Remove a built-in (restorable) or delete a custom provider; its messages stay.
sendmock sms providers delete <providerKey>sendmock_sms_provider_delete204 No content
Errors: 404, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}/restoreBring a removed built-in back as it was.
sendmock sms providers restore <providerKey>sendmock_sms_provider_restore200 MessageProviderDefinition
Errors: 404, 409, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}/resetPut a built-in provider back as shipped.
sendmock sms providers reset <providerKey>sendmock_sms_provider_reset200 MessageProviderDefinition
Errors: 404, 409, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}/previewRun a sample request through a definition: the message it would store and the answer it would give.
sendmock sms providers preview <providerKey>sendmock_sms_provider_previewMessageProviderPreviewRequest : Body of POST .../providers/{providerKey}/preview.
| Field | Type | Description |
|---|---|---|
| provider | MessageProviderInput | The provider settings to run, saved or not. |
| sample_request? | ProviderSampleRequest | The request to run; the provider's example send when left out. |
200 MessageProviderPreview
Errors: 404, as { error: { code, message } }
/api/v1/sms/providers/{providerKey}/credentials/{credentialName}Reveal one secret credential (asked for after a confirmation).
sendmock sms providers credential <providerKey> <credentialName> --reveal200 ProviderCredentialReveal
Errors: 404, as { error: { code, message } }
/api/v1/sms/whatsapp-cloud/verify-webhookSend Meta's callback URL check to the app and report whether it answered the challenge.
sendmock sms whatsapp-cloud verify-webhooksendmock_sms_whatsapp_verify_webhookWhatsappWebhookVerificationRequest : Body of POST /api/v1/sms/whatsapp-cloud/verify-webhook.
| Field | Type | Description |
|---|---|---|
| url? | string | The URL to check; the WhatsApp Cloud provider's webhook_url when left out.Example: http://127.0.0.1:3000/whatsapp/webhook |
200 WhatsappWebhookVerification
Errors: 422, as { error: { code, message } }