11310: Invalid template token
ERROR
Twilio returns this error when your URL template references a token that is not available for the webhook or callback you configured. The set of available parameters depends on the specific request type that Twilio sends.
- Your URL template includes a placeholder for a parameter that Twilio does not send for this webhook or callback.
- The token name in the template does not match a valid parameter name for the request, such as
CallSidfor a VoiceStatusCallbackrequest orMessageSidfor an incoming Messaging webhook request. - You reused a template from another product, channel, or event type. Webhook parameters vary by channel and event type, so tokens that are valid for one webhook may not be available for another.
- Review the parameter list for the specific webhook or callback you configured, then update the template to use only parameter names that Twilio sends for that request.
- Replace or remove any unsupported placeholder in the template. For Voice
StatusCallbackrequests, use documented parameters such asCallSid,AccountSid,From, andTowhen they fit your use case. - Send a mock or test webhook request to your application and inspect the payload before you save the template. Twilio recommends using sample webhook requests, tools such as
curlor Postman, or a request capture service during development.