Webhook Management
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 webhooks that receive real-time event notifications from Arattai. Webhooks can be scoped to a company, a business, or a business number. When a conversation event occurs, Arattai sends a signed HTTP POST request to the configured webhook URL.
Host: https://business.arattai.in/api/v1
Required headers:
Arattai-CompanyId: Required for all APIs. If you're a BSP creating a webhook on behalf of a business you manage, pass your BSP company's ID here.
The full set of attributes returned for a webhook is documented under the Webhook schema in the API reference below.
Supported Events
chat.message.receivedchat.message.editedchat.message.deletedchat.message.reactedchat.message.sentchat.message.deliveredchat.message.readchat.message.failedbusiness.blockeduser.preference.updatedminiapp.closedmessagetemplate.approval.updated- Delivered only to company-scoped webhooks, and only valid for webhooks of typepromotion,transaction, orauthentication.
Key Object
{"id": "...", "key": "...", "selected": true|false, "created_time": "...", "creator": {"id": "...", "name": "...", "email": "...", "zuid": "..."}}. The creator sub-object is omitted if it cannot be resolved.
Notes
- The
all=trueparam onGET /webhooksreturns webhooks across all scopes (company + business + business number). - String fields such as
descriptionare omitted from the response when not set. To clear such a field, send an empty string ("") in the update payload. - Up to 2 secret keys can exist per webhook. Only one key can be selected for signing at a time. Attempting to create a 3rd key for the same webhook returns 400
invalid_operation. - Company-level, business-level, and business-number-level webhooks are independent of each other. Configuring a webhook at one scope does not disable or replace delivery to webhooks configured at another scope for the same events.
- An event name in
eventsthat does not match one of the Supported Events values above is accepted at request time but has no effect - it is silently dropped rather than rejected, and no error is returned.
Error Response Format
{"code": "error_code", "message": "A human-readable description."}
Attribute
/webhooks/{id}.Allowed values:
conversation- Chat and conversation events, such as messages received, sent, and read.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.miniapp- Events related to mini app sessions.
webhook (a signed HTTP POST to the configured URL).Allowed values:
enabled- The webhook receives event notifications for its configuredevents.disabled- The webhook is configured but does not receive any event notifications.
Allowed values:
chat.message.received- A message was received in a conversation.chat.message.edited- A message was edited.chat.message.deleted- A message was deleted.chat.message.reacted- A reaction was added to a message.chat.message.sent- A message was sent.chat.message.delivered- A sent message was delivered to the recipient.chat.message.read- A sent message was read by the recipient.chat.message.failed- A sent message failed to deliver.business.blocked- A user blocked the business.user.preference.updated- A user updated their messaging preferences.miniapp.closed- A user closed a mini app session.messagetemplate.approval.updated- A message template's approval status changed. Delivered only to company-scoped webhooks, and only valid for webhooks of typepromotion,transaction, orauthentication.
keys, when the webhook is BSP-managed and the requesting company (identified by the Arattai-CompanyId header) is not the owning BSP."") in the update payload to clear it.company object. Omitted for business-scoped and business-number-scoped webhooks.selected: true is the one currently used for signing. Omitted from the response when empty, or hidden per the url BSP-visibility rule.Allowed values:
bsp- Managed by a Business Solution Provider acting on behalf of the business.company- Managed directly by the owning company.
creator. Falls back to creator if the webhook has never been modified.{
"id": "210889000000883005",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/webhooklistener",
"description": "My webhook",
"company_id": "501000000000001",
"company": {
"id": "501000000000001",
"name": "Northbrook Retail"
},
"businessnumber_id": "501000000003001",
"business": {
"id": "501000000002005",
"name": "BMW",
"reference_id": "1K3M5X2"
},
"businessnumber": {
"id": "501000000003001",
"phone_country_code": "+91",
"phonenumber": "9443789765"
},
"keys": [
{
"id": "1769946328774",
"key": "O2yg0MDKpOFHAwR7fZtNg2ltBQ0fr7buWRy7qyToBfqJ6-f-uHHF1_r9fTz3hfvo",
"selected": true,
"created_time": "1769946328774",
"creator": {
"id": "501000000002001",
"name": "Ryan West",
"email": "ryan.west@northbrook.com",
"zuid": "12345678"
}
}
],
"source": "company",
"creator": {
"id": "501000000002001",
"name": "Ryan West"
},
"modifier": {
"id": "501000000002001",
"name": "Ryan West"
},
"created_time": "1726981030134",
"modified_time": "1726981427656",
"bsp": {
"id": "501000000001001",
"name": "Northbrook Solutions"
}
}
Create a Webhook for the Company
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
Create a company-scoped webhook. Company-scoped webhooks receive events for all businesses and business numbers under the company.
url is validated synchronously at creation time using the same challenge-response check as the standalone Verify a Webhook URL endpoint. Creation fails with 400 invalid_verification_token if the URL does not pass.
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.webhooks.CREATE
Arguments
Allowed values:
chat.message.received- A new inbound message was received in the conversation.chat.message.edited- An existing message was edited.chat.message.deleted- An existing message was deleted.chat.message.reacted- A reaction was added to a message.chat.message.sent- An outbound message sent by the business was accepted by Arattai.chat.message.delivered- An outbound message was delivered to the recipient's device.chat.message.read- An outbound message was read by the recipient.chat.message.failed- An outbound message failed to deliver.business.blocked- A user blocked the business.user.preference.updated- A user updated their messaging preferences.miniapp.closed- A mini app session was closed.messagetemplate.approval.updated- A message template's approval status changed. Delivered only to company-scoped webhooks, and only valid for webhooks of typepromotion,transaction, orauthentication.
Allowed values:
conversation- Chat and messaging events for one-to-one conversations.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.miniapp- Events related to mini app sessions.
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/webhooks"
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/webhooks")
.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/webhooks', 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/webhooks", 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/webhooks",
"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/webhooks");
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/webhooks"),
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/webhooks"
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/webhooks");
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/webhooks \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"events": [
"chat.message.received",
"chat.message.edited",
"chat.message.deleted"
],
"type": "conversation",
"url": "https://salesiq.zoho.com/webhooklistener"
}
{
"url": "/api/v1/webhooks",
"type": "workflow",
"data": {
"id": "210889000000883005",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/webhooklistener",
"company_id": "501000000000001",
"company": {
"id": "501000000000001",
"name": "Northbrook Retail"
},
"keys": [],
"creator": {
"id": "501000000002001",
"name": "Ryan West"
},
"created_time": "1726981030134",
"modified_time": "1726981030134",
"source": "company"
}
}
{
"code": "invalid_verification_token",
"message": "The webhook URL could not be verified"
}
{
"code": "invalid_input",
"message": "Either the input stream or parameter is invalid or absent."
}
{
"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"
}
List Company Webhooks
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
List webhooks scoped to the current company. Use ?all=true to retrieve webhooks across all scopes (company, business, and business number) in a single call. Use index and limit to paginate.
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.webhooks.READ
Query Parameters
true, returns webhooks across all scopes (company-level, business-level, and business-number-level).Allowed values:
conversation- Chat and messaging events for one-to-one conversations.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.
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/webhooks"
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/webhooks")
.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/webhooks', 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/webhooks", 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/webhooks",
"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/webhooks");
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/webhooks"),
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/webhooks"
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/webhooks");
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/webhooks \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"url": "/api/v1/webhooks",
"data": [
{
"id": "501000000013001",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/webhooklistener",
"company": {
"id": "501000000000001",
"name": "Northbrook Retail"
},
"created_time": "1769942287291",
"modified_time": "1769942287291"
}
]
}
{
"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"
}
Create a Webhook 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
Create a business-scoped webhook. Business-scoped webhooks receive events for all business numbers under the specified business.
url is validated synchronously at creation time using the same challenge-response check as the standalone Verify a Webhook URL endpoint. Creation fails with 400 invalid_verification_token if the URL does not pass.
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.webhooks.CREATE
Arguments
Allowed values:
chat.message.received- A new inbound message was received in the conversation.chat.message.edited- An existing message was edited.chat.message.deleted- An existing message was deleted.chat.message.reacted- A reaction was added to a message.chat.message.sent- An outbound message sent by the business was accepted by Arattai.chat.message.delivered- An outbound message was delivered to the recipient's device.chat.message.read- An outbound message was read by the recipient.chat.message.failed- An outbound message failed to deliver.business.blocked- A user blocked the business.user.preference.updated- A user updated their messaging preferences.miniapp.closed- A mini app session was closed.messagetemplate.approval.updated- A message template's approval status changed. Delivered only to company-scoped webhooks, and only valid for webhooks of typepromotion,transaction, orauthentication.
Allowed values:
conversation- Chat and messaging events for one-to-one conversations.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.miniapp- Events related to mini app sessions.
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/webhooks"
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/webhooks")
.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/webhooks', 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/webhooks", 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/webhooks",
"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/webhooks");
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/webhooks"),
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/webhooks"
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/webhooks");
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/webhooks \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"events": [
"chat.message.received"
],
"type": "conversation",
"url": "https://salesiq.zoho.com/businesswebhook"
}
{
"url": "/api/v1/businesses/501000000002005/webhooks",
"type": "workflow",
"data": {
"id": "210889000000883006",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/businesswebhook",
"business": {
"id": "501000000002005",
"name": "Northbrook Retail",
"reference_id": "BIZ-2005"
},
"keys": [],
"creator": {
"id": "501000000002001",
"name": "Ryan West"
},
"created_time": "1726981030134",
"modified_time": "1726981030134",
"source": "company"
}
}
{
"code": "invalid_verification_token",
"message": "The webhook URL could not be verified"
}
{
"code": "invalid_input",
"message": "Either the input stream or parameter is invalid or absent."
}
{
"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"
}
List Webhooks 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
List webhooks scoped to a specific business.
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.webhooks.READ
Path Parameters
Query Parameters
Allowed values:
conversation- Chat and messaging events for one-to-one conversations.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.
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/webhooks"
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/webhooks")
.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/webhooks', 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/webhooks", 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/webhooks",
"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/webhooks");
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/webhooks"),
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/webhooks"
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/webhooks");
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/webhooks \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"url": "/api/v1/businesses/501000000002005/webhooks",
"data": [
{
"id": "501000000013001",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/businesswebhook",
"business": {
"id": "501000000002005",
"name": "Northbrook Retail"
},
"created_time": "1769942287291",
"modified_time": "1769942287291"
}
]
}
{
"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"
}
Create a Webhook for a Business Number
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
Create a business-number-scoped webhook. Receives events only for the specified business number.
url is validated synchronously at creation time using the same challenge-response check as the standalone Verify a Webhook URL endpoint. Creation fails with 400 invalid_verification_token if the URL does not pass.
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.webhooks.CREATE
Arguments
Allowed values:
chat.message.received- A new inbound message was received in the conversation.chat.message.edited- An existing message was edited.chat.message.deleted- An existing message was deleted.chat.message.reacted- A reaction was added to a message.chat.message.sent- An outbound message sent by the business was accepted by Arattai.chat.message.delivered- An outbound message was delivered to the recipient's device.chat.message.read- An outbound message was read by the recipient.chat.message.failed- An outbound message failed to deliver.business.blocked- A user blocked the business.user.preference.updated- A user updated their messaging preferences.miniapp.closed- A mini app session was closed.messagetemplate.approval.updated- A message template's approval status changed. Delivered only to company-scoped webhooks, and only valid for webhooks of typepromotion,transaction, orauthentication.
Allowed values:
conversation- Chat and messaging events for one-to-one conversations.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.miniapp- Events related to mini app sessions.
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks"
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks")
.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/businessnumbers/BUSINESS_NUMBER_ID/webhooks', 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/businessnumbers/BUSINESS_NUMBER_ID/webhooks", 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/businessnumbers/BUSINESS_NUMBER_ID/webhooks",
"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/businessnumbers/BUSINESS_NUMBER_ID/webhooks");
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks"),
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks"
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks");
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"events": [
"chat.message.received"
],
"type": "conversation",
"url": "https://salesiq.zoho.com/numberwebhook"
}
{
"url": "/api/v1/businessnumbers/501000000003001/webhooks",
"type": "workflow",
"data": {
"id": "210889000000883007",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/numberwebhook",
"businessnumber_id": "501000000003001",
"businessnumber": {
"id": "501000000003001",
"phone_country_code": "+91",
"phonenumber": "8883169888"
},
"keys": [],
"creator": {
"id": "501000000002001",
"name": "Ryan West"
},
"created_time": "1726981030134",
"modified_time": "1726981030134",
"source": "company"
}
}
{
"code": "invalid_verification_token",
"message": "The webhook URL could not be verified"
}
{
"code": "invalid_input",
"message": "Either the input stream or parameter is invalid or absent."
}
{
"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"
}
List Webhooks for a Business Number
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
List webhooks scoped to a specific business number.
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.webhooks.READ
Path Parameters
Query Parameters
Allowed values:
conversation- Chat and messaging events for one-to-one conversations.promotion- Events related to promotional message templates.transaction- Events related to transactional message templates.authentication- Events related to authentication message templates.
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks"
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks")
.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/businessnumbers/BUSINESS_NUMBER_ID/webhooks', 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/businessnumbers/BUSINESS_NUMBER_ID/webhooks", 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/businessnumbers/BUSINESS_NUMBER_ID/webhooks",
"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/businessnumbers/BUSINESS_NUMBER_ID/webhooks");
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks"),
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks"
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks");
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/businessnumbers/BUSINESS_NUMBER_ID/webhooks \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"url": "/api/v1/businessnumbers/501000000003001/webhooks",
"data": [
{
"id": "501000000013002",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"events": [
"chat.message.received"
],
"url": "https://salesiq.zoho.com/numberwebhook",
"businessnumber": {
"id": "501000000003001",
"phone_country_code": "+91",
"phonenumber": "8883169888"
},
"created_time": "1769942287291",
"modified_time": "1769942287291"
}
]
}
{
"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 Webhook
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
Update an existing webhook. Only the fields included in the request body are updated; omitted fields retain their current value.
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.webhooks.UPDATE
Arguments
Allowed values:
enabled- The webhook is active and will receive event notifications.disabled- The webhook is paused and will not receive event notifications.
Allowed values:
chat.message.received- A new inbound message was received in the conversation.chat.message.edited- An existing message was edited.chat.message.deleted- An existing message was deleted.chat.message.reacted- A reaction was added to a message.chat.message.sent- An outbound message sent by the business was accepted by Arattai.chat.message.delivered- An outbound message was delivered to the recipient's device.chat.message.read- An outbound message was read by the recipient.chat.message.failed- An outbound message failed to deliver.business.blocked- A user blocked the business.user.preference.updated- A user updated their messaging preferences.miniapp.closed- A mini app session was closed.messagetemplate.approval.updated- A message template's approval status changed. Delivered only to company-scoped webhooks, and only valid for webhooks of typepromotion,transaction, orauthentication.
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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_ID \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"url": "https://cliq.zoho.com/webhooklistener",
"description": "Cliq webhook",
"status": "enabled",
"events": [
"chat.message.edited",
"chat.message.received"
]
}
{
"url": "/api/v1/webhooks/210889000000883005",
"type": "workflow",
"data": {
"id": "210889000000883005",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"url": "https://cliq.zoho.com/webhooklistener",
"events": [
"chat.message.edited",
"chat.message.received"
]
}
}
{
"code": "invalid_verification_token",
"message": "The webhook URL could not be verified"
}
{
"code": "invalid_input",
"message": "Either the input stream or parameter is invalid or absent."
}
{
"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"
}
Get a Webhook
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
Retrieve the full details of a specific webhook by its ID, including its event subscriptions, URL, status, scope, and any associated secret keys.
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.webhooks.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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_ID \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"id": "210889000000883005",
"type": "conversation",
"connector": "webhook",
"status": "enabled",
"description": "My webhook",
"events": [
"chat.message.received",
"chat.message.edited",
"chat.message.deleted"
],
"url": "https://salesiq.zoho.com/webhooklistener",
"company": {
"id": "501000000000001",
"name": "Northbrook Retail"
},
"keys": [
{
"id": "1769946328774",
"key": "O2yg0MDKpOFHAwR7fZtNg2ltBQ0fr7buWRy7qyToBfqJ6-f-uHHF1_r9fTz3hfvo",
"selected": false,
"created_time": "1769946328774",
"creator": {
"id": "501000000002001",
"name": "Ryan West",
"email": "ryan.west@northbrook.com",
"zuid": "12345678"
}
}
],
"creator": {
"id": "501000000002001",
"name": "Ryan West"
},
"modifier": {
"id": "501000000002001",
"name": "Ryan West"
},
"created_time": "1726981030134",
"modified_time": "1726981427656"
}
{
"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 Webhook
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
Delete a webhook. All associated secret keys are also deleted.
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.webhooks.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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_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/webhooks/WEBHOOK_ID \
--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"
}
Create a Secret Key
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
Create a new secret key for a webhook. Secret keys are used for HMAC-SHA256 signing of outbound webhook payloads. Up to 2 keys can exist per webhook. This endpoint does not accept a request body.
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.webhooks.CREATE
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/webhooks/WEBHOOK_ID/keys"
type: POST
headers: headers_data
connection: <connection_name>
];
info response;
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://business.arattai.in/api/v1/webhooks/WEBHOOK_ID/keys")
.post(null)
.addHeader("Arattai-CompanyId", "SOME_STRING_VALUE")
.addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {
'Arattai-CompanyId': 'SOME_STRING_VALUE',
Authorization: 'Bearer REPLACE_BEARER_TOKEN'
}
};
fetch('https://business.arattai.in/api/v1/webhooks/WEBHOOK_ID/keys', 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("POST", "/api/v1/webhooks/WEBHOOK_ID/keys", headers=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/webhooks/WEBHOOK_ID/keys",
"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/webhooks/WEBHOOK_ID/keys");
var request = new RestRequest(Method.POST);
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.Post,
RequestUri = new Uri("https://business.arattai.in/api/v1/webhooks/WEBHOOK_ID/keys"),
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/webhooks/WEBHOOK_ID/keys"
req, _ := http.NewRequest("POST", 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("POST", "https://business.arattai.in/api/v1/webhooks/WEBHOOK_ID/keys");
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/webhooks/WEBHOOK_ID/keys \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"data": {
"id": "1769946328774",
"key": "O2yg0MDKpOFHAwR7fZtNg2ltBQ0fr7buWRy7qyToBfqJ6-f-uHHF1_r9fTz3hfvo",
"selected": false,
"created_time": "1769946328774"
},
"type": "key",
"url": "/api/v1/webhooks/501000000015001/keys"
}
{
"code": "invalid_operation",
"message": "A webhook can have a maximum of 2 secret keys"
}
{
"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"
}
List Secret Keys
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
List all secret keys for a webhook.
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.webhooks.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/webhooks/WEBHOOK_ID/keys"
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/webhooks/WEBHOOK_ID/keys")
.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/webhooks/WEBHOOK_ID/keys', 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/webhooks/WEBHOOK_ID/keys", 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/webhooks/WEBHOOK_ID/keys",
"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/webhooks/WEBHOOK_ID/keys");
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/webhooks/WEBHOOK_ID/keys"),
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/webhooks/WEBHOOK_ID/keys"
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/webhooks/WEBHOOK_ID/keys");
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/webhooks/WEBHOOK_ID/keys \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN'
{
"url": "/api/v1/webhooks/501000000015001/keys",
"type": "keys",
"data": [
{
"id": "1769946328774",
"key": "O2yg0MDKpOFHAwR7fZtNg2ltBQ0fr7buWRy7qyToBfqJ6-f-uHHF1_r9fTz3hfvo",
"selected": true,
"created_time": "1769946328774"
}
]
}
{
"url": "/api/v1/webhooks/501000000015001/keys",
"type": "keys",
"data": []
}
{
"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"
}
Select or Unselect a Secret Key
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
Select or unselect a specific secret key for signing outbound webhook payloads. The selected key is the one currently used for HMAC-SHA256 signing. Only one key can be selected at a time.
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.webhooks.UPDATE
Arguments
true) or unselect (false) this key for signing.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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_ID \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"selected": true
}
{
"id": "1769946328774",
"key": "O2yg0MDKpOFHAwR7fZtNg2ltBQ0fr7buWRy7qyToBfqJ6-f-uHHF1_r9fTz3hfvo",
"selected": true,
"created_time": "1769946328774"
}
{
"code": "invalid_input",
"message": "Either the input stream or parameter is invalid or absent."
}
{
"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 Secret Key
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
Delete a specific secret key from a webhook.
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.webhooks.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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_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/webhooks/WEBHOOK_ID/keys/WEBHOOK_KEY_ID \
--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"
}
Verify a Webhook URL
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
Performs a challenge-response handshake to verify that a URL is a valid, reachable HTTPS webhook endpoint before registering it.
How it works:
- The platform sends a GET request to the URL with a random UUID as a query parameter:
GET <url>?challenge=<uuid> - The endpoint must respond with HTTP 200 and echo the challenge value in a JSON body:
{"challenge": "<uuid>"} - If the response matches, verification succeeds and 204 is returned.
- URL must use HTTPS (HTTP is rejected with 400)
- Response must be HTTP 200
- Response body must be valid JSON with the challenge field echoed back
- Endpoint must respond within 20 seconds
- Redirects are not followed
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.webhooks.CREATE
Arguments
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/webhookverification"
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/webhookverification")
.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/webhookverification', 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/webhookverification", 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/webhookverification",
"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/webhookverification");
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/webhookverification"),
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/webhookverification"
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/webhookverification");
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/webhookverification \
--header 'Arattai-CompanyId: SOME_STRING_VALUE' \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"url": "https://salesiq.zoho.com/webhooklistener"
}
{
"code": "invalid_verification_token",
"message": "The webhook URL could not be verified"
}
{
"code": "invalid_input",
"message": "Either the input stream or parameter is invalid or absent."
}
{
"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"
}