Send a text template for review
submit_site_message_template
Sends one text template for review, a built-in one included.
It works like Send for review in the Templates tab, for a template that is initial, rejected or disabled. A built-in template whose text was never changed is usually approved at once, because the built-in templates are approved ahead of time, and otherwise goes for review like any other. A template with text of the site's own is checked against the review rules first, and is refused with the reasons when it would likely be rejected or texting cannot be used for it. A rejected template rarely passes unchanged, so change its text with save_site_message_template, which sends it for review too. When the answer says retrying, the review could not start yet for a reason outside the template, and it is sent for review again on its own, so there is no need to send it again. See Template review.
Request
Call it with a POST to https://api.modulify.ai/v1/submit_site_message_template, sending the inputs below as a JSON object. The token needs the config:write scope.
It makes changes, so send an Idempotency-Key header whenever you might retry it. A retry with the same key gets the first answer back instead of running again.
curl -X POST https://api.modulify.ai/v1/submit_site_message_template \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"projectId":"PROJECT_ID","key":"KEY"}'Over MCP, the same method is the submit_site_message_template tool.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
projectId |
string | Yes | The site id. |
key |
string | Yes | The key of the template, from list_site_message_templates. |
Response
Every call answers with the JSON envelope of success, message, data, code and version. data holds the result described above, and on a method that returns a total, count carries it. The response headers carry the call's X-Request-Id and what is left of your per-minute budget in X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset. Errors explains every status code a call can answer with.