Message Templates
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
APIs for managing message templates and their per-language translations. Templates are scoped to a business and contain a primary language plus optional secondary-language translations.
Host: https://business.arattai.in/api/v1
Required headers:
Arattai-CompanyId: Required for all endpoints. If you're a BSP creating a template on behalf of a business you manage, pass your BSP company's ID here.
Template Types and Limits
| Type | Max per business | Button limit | Notes |
|---|---|---|---|
promotion | 50 | 3 | |
transaction | 50 | 3 | |
authentication | 30 | 1 | Only copy_code button allowed. Media ignored. |
Supported Media Types
Server detects media type from file extension. Do not send media.type in request payloads.
| Extension | MIME type | Max size |
|---|---|---|
| jpeg, jpg | image/jpeg | 5 MB |
| png | image/png | 5 MB |
| gif | image/gif | 5 MB |
| avif | image/avif | 5 MB |
| webp | image/webp | 5 MB |
| mp3 | audio/mpeg | 20 MB |
| aac | audio/aac | 20 MB |
| amr | audio/amr | 20 MB |
| mp4 | video/mp4 | 20 MB |
| webm | video/webm | 20 MB |
| mkv | video/x-matroska | 20 MB |
| application/pdf | 20 MB | |
| txt | text/plain | 20 MB |
| ics | text/calendar | 5 MB |
Draft Status Lifecycle
- draft → under_review (via /submit)
- under_review → draft (via /revoke)
- under_review → approved | rejected (admin action)
- approved → disabled (via /disable)
- disabled → approved (via /enable)
Placeholder Variable Syntax: Use
{{variable_name}} in message body and title. Variables referenced in message must be declared in place_holders. Mismatch in either direction returns 400 invalid_input.
Detail-only Timestamp Fields
reviewed_time, last_submitted_time, last_approved_time, and last_rejected_time (all epoch milliseconds) are included only in the single-template detail response (GET /messagetemplates/{id}). They are omitted from list responses and from "get all translations" responses.
Notes
- In list responses, translations include only
language,created_time,draft.status, andpublished.status- no other translation fields are present.published.statusallowed values areapprovedanddisabled; if an approved template is later disabled (e.g. due to user reports or other reasons), itspublished.statusbecomesdisabled. - Updating a template, or syncing a translation of it, is blocked with
409 conflictif any translation of that same template is currentlyunder_review. Revoke the review first. - When placeholders or buttons change via update, all other translations of that same template (i.e. all secondary-language translations belonging to it) are marked
update_required. - Draft and published media are tracked separately. Media upload/delete endpoints only affect the draft version.
Error Response Format
{"code": "error_code", "message": "A human-readable description."}
Create a Message Template
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Creates a new message template scoped to the given business. Also creates the primary-language translation record in DRAFT status.
application/json as shown below.- It also supports
multipart/form-datato attach media in the same request - send all template fields as individual form parameters alongside the binaryfilefield. - Media can also be added after creation via the Upload Draft Media endpoint.
Required fields:
type, language, message.body.Validation
- Variables in message must match declarations in
place_holders. - Maximum 10
place_holdersper create/update. - Maximum 3 buttons per template (maximum 1 button total for
authenticationtemplates, which must becopy_code). - Across all template types, at most 1
copy_codebutton is allowed per template.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 15 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Allowed values:
promotion- Marketing or promotional messages, such as offers, discounts, and festival greetings.transaction- Transactional updates related to an order or payment, such as confirmations and shipping status.authentication- One-time password (OTP) or verification code messages used for login or account verification.
Allowed values:
quick_reply- Sends a fixed, predefined reply text back when tapped.url- Opens the specified destination URL when tapped.copy_code- Displays a copyable code, typically used for OTP/authentication templates.miniapp- Opens a linked mini app when tapped; requires miniapp_id.
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates"
type: POST
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("POST", "/api/v1/businesses/BUSINESS_ID/messagetemplates", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/businesses/BUSINESS_ID/messagetemplates",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
List Templates for a Business
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Lists templates scoped to a single business. Translations in list responses include only status fields. Use GET by ID or GET translations for full content.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 60 requests per minute
- Secondary Threshold Limit (Number of API calls allowed within 5 minutes) - 150 requests per 5 minutes
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Path Parameters
Query Parameters
Allowed values:
promotion- Marketing or promotional templates.transaction- Transactional templates.authentication- Authentication/OTP templates.
Allowed values:
draft- Translation has not yet been submitted for review.under_review- Translation has been submitted and is awaiting admin review.approved- Translation has been reviewed and approved.rejected- Translation was reviewed and rejected.update_required- Translation's content is out of sync with the parent template and must be re-synced.
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates")
.get()
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'GET',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("GET", "/api/v1/businesses/BUSINESS_ID/messagetemplates", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/businesses/BUSINESS_ID/messagetemplates",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates");
var request = new RestRequest(Method.GET);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/businesses/BUSINESS_ID/messagetemplates \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"url": "/api/v1/businesses/501000000002005/messagetemplates"
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Update a Message Template
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Updates template metadata and/or default-language draft content. If placeholders or buttons change, all translations are marked update_required. Updates are blocked if any translation is currently under_review.
Validation
- Same limits as Create apply.
- Maximum 10 place_holders.
- Maximum 3 buttons per template (maximum 1 button total for authentication templates, which must be copy_code).
- Across all template types, at most 1 copy_code button is allowed per template.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.UPDATE
Arguments
Allowed values:
enabled- Template is active and can be used to send messages.disabled- Template is inactive and cannot be used to send messages.
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"
type: PATCH
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID")
.patch(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'PATCH',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("PATCH", "/api/v1/messagetemplates/TEMPLATE_ID", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "PATCH",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Patch,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("PATCH", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request PATCH \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
Get a Message Template
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Returns the full template including all translations with complete draft/published content. Optionally include lifetime delivery stats.
Stats fields (include_fields=stats): sent, delivered, replied, delivery_rate (percentage to 2 decimal places), credits (4 decimal places), credits_per_msg (4 decimal places). Credits are charged on delivery only.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Path Parameters
Query Parameters
Allowed values:
stats- Include lifetime (last 6 months) delivery stats.
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID")
.get()
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'GET',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("GET", "/api/v1/messagetemplates/TEMPLATE_ID", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID");
var request = new RestRequest(Method.GET);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
Delete a Message Template
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Permanently deletes the template and all its translations.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.DELETE
Path Parameters
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"
type: DELETE
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID")
.delete(null)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'DELETE',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("DELETE", "/api/v1/messagetemplates/TEMPLATE_ID", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "DELETE",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("DELETE", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request DELETE \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
List all Templates
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Lists templates across all businesses accessible in the current scope. Translations in list responses include only status fields.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 60 requests per minute
- Secondary Threshold Limit (Number of API calls allowed within 5 minutes) - 150 requests per 5 minutes
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Query Parameters
Allowed values:
draft- Translation has not yet been submitted for review.under_review- Translation has been submitted and is awaiting admin review.approved- Translation has been reviewed and approved.rejected- Translation was reviewed and rejected.update_required- Translation's content is out of sync with the parent template and must be re-synced.
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates")
.get()
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'GET',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("GET", "/api/v1/messagetemplates", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates");
var request = new RestRequest(Method.GET);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/messagetemplates");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/messagetemplates \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"url": "/api/v1/messagetemplates"
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Download Template Media
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Downloads the media file attached to a message template. The {attachmentId} is the base64-encoded token from the template object's media URL field.
{attachmentId} token and extracted by the server automatically.Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 5 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Path Parameters
headers_data = Map();
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2")
.get()
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {method: 'GET', headers: {Authorization: 'Bearer REPLACE_BEARER_TOKEN'}};
fetch('https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = { 'Authorization': "Bearer REPLACE_BEARER_TOKEN" }
conn.request("GET", "/api/v1/templatemedia/YWJjMTIzZGVmNDU2", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/templatemedia/YWJjMTIzZGVmNDU2",
"headers": {
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2"),
Headers =
{
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/templatemedia/YWJjMTIzZGVmNDU2 \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"code": "not_found",
"message": "The requested media resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Submit Translations for Review
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Moves specified translation(s) from draft to under_review. Only translations currently in draft status can be submitted.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 50 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit"
type: POST
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/submit", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/submit",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/submit \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"languages": [
"en",
"fr"
]
}
{...}
{
"code": "invalid_input",
"message": "The request cannot be performed. Usually because of malformed parameter or missing parameter."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Only draft templates can be submitted for review"
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Revoke Translations from Review
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Moves specified translation(s) from under_review back to draft. Only translations currently in under_review status can be revoked.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 50 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke"
type: POST
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/revoke", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/revoke",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/revoke \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"languages": [
"en",
"fr"
]
}
{...}
{
"code": "invalid_input",
"message": "The request cannot be performed. Usually because of malformed parameter or missing parameter."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Only templates under review can be revoked"
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Enable Template or Translations
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Two behaviors depending on whether a languages array is provided:
a) languages array present and non-empty: Enables (re-approves) specific translations currently in disabled status. Only disabled translations can be enabled.
b) languages array absent or empty: Enables the template itself (parent row status). Template must be disabled. blocked and deleted templates cannot be enabled.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 50 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable"
type: POST
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/enable", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/enable",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/enable \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"languages": [
"en",
"fr"
]
}
{
"languages": []
}
{...}
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Only disabled templates can be enabled"
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Disable Template or Translations
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Two behaviors depending on whether a languages array is provided:
a) languages array present and non-empty: Disables specific translations currently in approved status. Only approved translations can be disabled.
b) languages array absent or empty: Disables the template itself. Template must be enabled.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 50 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable"
type: POST
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/disable", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/disable",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/disable \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"languages": [
"en",
"fr"
]
}
{
"languages": []
}
{...}
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Only approved templates can be disabled"
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Upload Draft Media (Primary Language)
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Uploads a new media file (or replaces existing draft media) for the template's primary language translation. Only draft media is updated; published media is unaffected. Blocked if the primary translation is currently under_review.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 10 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Path Parameters
Headers
parameters_data = Map();
parameters_data.put("field1", "value1")
parameters_data.put("field2", "value2")
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media"
type: POST
headers: headers_data
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("multipart/form-data; boundary=---011000010111000001101001");
RequestBody body = RequestBody.create(mediaType, "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "multipart/form-data; boundary=---011000010111000001101001")
.build();
Response response = client.newCall(request).execute();
const form = new FormData();
form.append("field1", "value1");
form.append("field2", "value2");
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'multipart/form-data; boundary=---011000010111000001101001'
}
};
options.body = form;
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "multipart/form-data; boundary=---011000010111000001101001"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/media", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/media",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "multipart/form-data; boundary=---011000010111000001101001"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n");
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "multipart/form-data; boundary=---011000010111000001101001");
request.AddParameter("multipart/form-data; boundary=---011000010111000001101001", "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new MultipartFormDataContent
{
new StringContent("value1")
{
Headers =
{
ContentDisposition = new ContentDispositionHeaderValue("form-data")
{
Name = "field1",
}
}
},
new StringContent("value2")
{
Headers =
{
ContentDisposition = new ContentDispositionHeaderValue("form-data")
{
Name = "field2",
}
}
},
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "multipart/form-data; boundary=---011000010111000001101001")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = new FormData();
data.append("field1", "value1");
data.append("field2", "value2");
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: multipart/form-data' \
--form field1=value1 \
--form field2=value2
{
"file": "<binary media file>"
}
{...}
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Template has a translation that is currently under review. Revoke first before uploading media"
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "file_too_large",
"message": "The uploaded file exceeds the maximum allowed size."
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Delete Draft Media (Primary Language)
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Deletes the draft media file from the template's primary language translation. Published media is unaffected. Blocked if the translation is currently under_review. Returns an error if no draft media exists.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 10 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.DELETE
Path Parameters
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media"
type: DELETE
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media")
.delete(null)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'DELETE',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("DELETE", "/api/v1/messagetemplates/TEMPLATE_ID/media", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "DELETE",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/media",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("DELETE", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request DELETE \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/media \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Template has a translation that is currently under review. Revoke first before deleting media"
}
{
"code": "not_found",
"message": "No draft media found for this template."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Sync Multiple Translations (Bulk)
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Bulk create or update translations. Keys are language codes, values are translation content objects. Creates a record if the language is new; updates existing draft if already exists. Blocked if any provided translation is currently under_review. Maximum 50 language keys. Payload maximum 50000 characters.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 50 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations"
type: POST
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/translations", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"en": {
"message": {
"body": "Hi {{name}}, your order has been dispatched!"
}
},
"fr": {
"message": {
"body": "Bonjour {{name}}, votre commande a été expédiée!"
}
}
}
{...}
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Template has a translation that is currently under review. Revoke first before syncing"
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Get all Translations
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Returns full translation objects (with complete draft/published content) for all languages of this template.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Path Parameters
Query Parameters
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations")
.get()
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'GET',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("GET", "/api/v1/messagetemplates/TEMPLATE_ID/translations", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations");
var request = new RestRequest(Method.GET);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{...}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Sync a Single Translation
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Updates a single translation's draft content (message, placeholders, buttons). Sets the translation back to draft status. Blocked if the translation is currently under_review.
lang_code format: [a-z]{2}(-[A-Z]{2})? (e.g. en, fr, en-US). Maximum 10 place_holders per translation.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 50 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.UPDATE
Arguments
Path Parameters
Headers
parameters_data='{"field1":"value1","field2":"value2"}';
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr"
type: PATCH
headers: headers_data
content-type: application/json
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr")
.patch(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'PATCH',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'application/json'
},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "application/json"
}
conn.request("PATCH", "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "PATCH",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({field1: 'value1', field2: 'value2'}));
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"field1\":\"value1\",\"field2\":\"value2\"}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Patch,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new StringContent("{\"field1\":\"value1\",\"field2\":\"value2\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr"
payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = JSON.stringify({
"field1": "value1",
"field2": "value2"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("PATCH", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.setRequestHeader("content-type", "application/json");
xhr.send(data);
curl --request PATCH \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"message": {
"body": "Bonjour {{name}}, votre commande est en route!"
}
}
{...}
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Template has a translation that is currently under review. Revoke first before syncing"
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Get a Single Translation
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Returns full draft and published content for a single translation language. Returns 404 if the template or translation for that language does not exist.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Path Parameters
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en")
.get()
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'GET',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("GET", "/api/v1/messagetemplates/TEMPLATE_ID/translations/en", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations/en",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en");
var request = new RestRequest(Method.GET);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/en \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{...}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Delete a Translation
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Deletes the translation for the specified language. Use with care; primary language translations can also be deleted via this endpoint.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.DELETE
Path Parameters
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr"
type: DELETE
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr")
.delete(null)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'DELETE',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("DELETE", "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "DELETE",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("DELETE", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request DELETE \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "not_found",
"message": "The requested resource was not found."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Upload Draft Media for a Translation
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Uploads a new media file (or replaces existing draft media) for a specific translation language. Only draft media is updated; published media is unaffected. Blocked if the translation is currently under_review.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 10 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.CREATE
Arguments
Path Parameters
Headers
parameters_data = Map();
parameters_data.put("field1", "value1")
parameters_data.put("field2", "value2")
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media"
type: POST
headers: headers_data
parameters: parameters_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("multipart/form-data; boundary=---011000010111000001101001");
RequestBody body = RequestBody.create(mediaType, "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n");
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media")
.post(body)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.addHeader("content-type", "multipart/form-data; boundary=---011000010111000001101001")
.build();
Response response = client.newCall(request).execute();
const form = new FormData();
form.append("field1", "value1");
form.append("field2", "value2");
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN',
'content-type': 'multipart/form-data; boundary=---011000010111000001101001'
}
};
options.body = form;
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
payload = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n"
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN",
'content-type': "multipart/form-data; boundary=---011000010111000001101001"
}
conn.request("POST", "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "POST",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN",
"content-type": "multipart/form-data; boundary=---011000010111000001101001"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n");
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media");
var request = new RestRequest(Method.POST);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
request.AddHeader("content-type", "multipart/form-data; boundary=---011000010111000001101001");
request.AddParameter("multipart/form-data; boundary=---011000010111000001101001", "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
Content = new MultipartFormDataContent
{
new StringContent("value1")
{
Headers =
{
ContentDisposition = new ContentDispositionHeaderValue("form-data")
{
Name = "field1",
}
}
},
new StringContent("value2")
{
Headers =
{
ContentDisposition = new ContentDispositionHeaderValue("form-data")
{
Name = "field2",
}
}
},
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field1\"\r\n\r\nvalue1\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"field2\"\r\n\r\nvalue2\r\n-----011000010111000001101001--\r\n")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
req.Header.Add("content-type", "multipart/form-data; boundary=---011000010111000001101001")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = new FormData();
data.append("field1", "value1");
data.append("field2", "value2");
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request POST \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: multipart/form-data' \
--form field1=value1 \
--form field2=value2
{
"file": "<binary media file>"
}
{...}
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Template has a translation that is currently under review. Revoke first before uploading media"
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "file_too_large",
"message": "The uploaded file exceeds the maximum allowed size."
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Delete Draft Media for a Translation
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Deletes the draft media file for a specific translation language. Published media is unaffected. Blocked if the translation is currently under_review. Returns an error if no draft media exists for this translation.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 10 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.DELETE
Path Parameters
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media"
type: DELETE
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media")
.delete(null)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'DELETE',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("DELETE", "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "DELETE",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media");
var request = new RestRequest(Method.DELETE);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("DELETE", "https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request DELETE \
--url https://business.arattai.in/api/v1/messagetemplates/TEMPLATE_ID/translations/fr/media \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"message": "The request cannot be performed."
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_operation",
"message": "Template has a translation that is currently under review. Revoke first before deleting media"
}
{
"code": "not_found",
"message": "No draft media found for this translation."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}
Get Template Summary
AI Tools
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Open in ChatGPT
Open in ChatGPT to ask questions about this page
Open in Claude
Open in Claude to ask questions about this page
Copy as Markdown
Copy this page as markdown to use with AI assistants
View as Markdown
Open this page as markdown in a new tab
Returns the total number of templates and a breakdown by category scoped to the current company.
Rate Limits
- Threshold Limit (Number of API calls allowed within a minute) - 30 requests per minute
- Lock Period (Wait time before consecutive API requests) - 10 minutes
OAuth Scope : ArattaiBusiness.messagetemplates.READ
Headers
headers_data = Map();
headers_data.put("Arattai-CompanyId", "SOME_STRING_VALUE");
headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN");
response = invokeUrl
[
url: "https://business.arattai.in/api/v1/templatesummary"
type: GET
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/templatesummary")
.get()
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'GET',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/templatesummary', options)
.then(response => response.json())
.then(response => console.log(response))
.catch(err => console.error(err));
import http.client
conn = http.client.HTTPSConnection("business.arattai.in")
headers = {
'Arattai-CompanyId': "SOME_STRING_VALUE",
'Authorization': "Bearer REPLACE_BEARER_TOKEN"
}
conn.request("GET", "/api/v1/templatesummary", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const http = require("https");
const options = {
"method": "GET",
"hostname": "business.arattai.in",
"port": null,
"path": "/api/v1/templatesummary",
"headers": {
"Arattai-CompanyId": "SOME_STRING_VALUE",
"Authorization": "Bearer REPLACE_BEARER_TOKEN"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
var client = new RestClient("https://business.arattai.in/api/v1/templatesummary");
var request = new RestRequest(Method.GET);
request.AddHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
IRestResponse response = client.Execute(request);
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://business.arattai.in/api/v1/templatesummary"),
Headers =
{
{ "Arattai-CompanyId", "SOME_STRING_VALUE" },
{ "Authorization", "Bearer REPLACE_BEARER_TOKEN" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://business.arattai.in/api/v1/templatesummary"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Arattai-CompanyId", "SOME_STRING_VALUE")
req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://business.arattai.in/api/v1/templatesummary");
xhr.setRequestHeader("Arattai-CompanyId", "SOME_STRING_VALUE");
xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN");
xhr.send(data);
curl --request GET \
--url https://business.arattai.in/api/v1/templatesummary \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"total": 80,
"by_category": {
"promotion": 30,
"transaction": 40,
"authentication": 10
}
}
{
"code": "invalid_oauthtoken",
"message": "You are not authenticated to do this operation."
}
{
"code": "invalid_method",
"message": "Invalid method"
}
{
"code": "too_many_requests",
"message": "You have reached the maximum number of requests"
}