Okta Admin Management API
/Customizations
//
Create an SMS template
OAuth 2.0 scope:
- okta.templates.manage
Creates a new custom SMS template
Text of the Template, including any macros
- Template translations are optionally provided when you want to localize the SMS messages. Translations are provided as an object that contains
key:valuepairs: the language and the translated Template text. The key portion is a two-letter country code that conforms to ISO 639-1. The value is the translated SMS Template. - Just like with regular SMS Templates, the length of the SMS message can't exceed 160 characters.
- https://subdomain.okta.comhttps://subdomain.okta.com/api/v1/templates/sms
curl -i -X POST \
https://subdomain.okta.com/api/v1/templates/sms \
-H 'Content-Type: application/json' \
-d '{
"name": "Custom",
"type": "SMS_VERIFY_CODE",
"template": "${org.name}: your verification code is ${code}",
"translations": {
"es": "${org.name}: el código de verificación es ${code}",
"fr": "${org.name}: votre code de vérification est ${code}",
"it": "${org.name}: il codice di verifica è ${code}"
}
}'Success
Text of the Template, including any macros
- Template translations are optionally provided when you want to localize the SMS messages. Translations are provided as an object that contains
key:valuepairs: the language and the translated Template text. The key portion is a two-letter country code that conforms to ISO 639-1. The value is the translated SMS Template. - Just like with regular SMS Templates, the length of the SMS message can't exceed 160 characters.
Response
{ "id": "6NQUJ5yR3bpgEiYmq8IC", "name": "Custom", "type": "SMS_VERIFY_CODE", "template": "${org.name}: your verification code is ${code}", "translations": { "es": "${org.name}: el código de verificación es ${code}", "fr": "${org.name}: votre code de vérification est ${code}", "it": "${org.name}: il codice di verifica è ${code}" }, "created": "2024-04-25T17:35:02.000Z", "lastUpdated": "2024-04-25T17:35:02.000Z" }