A Messaging Service resource to add, fetch or remove short code numbers from a Messaging Service.
Path parameters
-
The SID of the Service to create the resource under.
Minimum length is
34, maximum length is34. Format should match the following pattern:^MG[0-9a-fA-F]{32}$.
POST
/v1/Services/{ServiceSid}/ShortCodes
curl \
--request POST 'https://messaging.twilio.com/v1/Services/{ServiceSid}/ShortCodes' \
--user "username:password" \
--header "Content-Type: application/x-www-form-urlencoded" \
--data 'ShortCodeSid=string'
Response examples (201)
{
"account_sid": "string",
"capabilities": [
"string"
],
"country_code": "string",
"date_created": "2026-05-04T09:42:00Z",
"date_updated": "2026-05-04T09:42:00Z",
"service_sid": "string",
"short_code": "string",
"sid": "string",
"url": "https://example.com"
}