API Docs
/
No Results Found
Channels

Channels 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

Channels, in Arattai are designed for one-way communication, which makes them ideal for announcements and updates to a large audience. Unlike group chats, where everyone can participate, only channel admins can post messages. Subscribers can interact by reacting to messages, depending on the channel's settings.

Public channels are searchable by anyone and are ideal for broadcasting news and community discussions.

The Channels API enables users to retrieve detailed information about a channel they own, administer, or are a member of.

Download Channels OpenAPI Document
End Points

Get Channels 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

Use this API to retrieve a list of channels the authenticated user is part of or has access to.

Threshold limit: 100 requests per min per user
Number of API calls allowed within a minute.

Lock period: 10 minutes
Wait time before consecutive API requests.


OAuth Scope : Arattai.Channels.READ

Query Parameters

limit
integer
Number of channels to retrieve.
next_token
string
Token obtained from a previous response to fetch the next page of results.

Note: Once the last page has been reached, the data array in the response will be empty. This is expected and indicates that there are no more channels to fetch, not an error.

Maximum length: 250 characters.

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN"); response = invokeUrl [ url: "https://api.arattai.in/restapi/v4/channels" type: GET headers: headers_data connection: <connection_name> ]; info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.arattai.in/restapi/v4/channels") .get() .addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN") .build(); Response response = client.newCall(request).execute();
const options = {method: 'GET', headers: {Authorization: 'Bearer REPLACE_BEARER_TOKEN'}}; fetch('https://api.arattai.in/restapi/v4/channels', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("api.arattai.in") headers = { 'Authorization': "Bearer REPLACE_BEARER_TOKEN" } conn.request("GET", "/restapi/v4/channels", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "GET", "hostname": "api.arattai.in", "port": null, "path": "/restapi/v4/channels", "headers": { "Authorization": "Bearer REPLACE_BEARER_TOKEN" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
var client = new RestClient("https://api.arattai.in/restapi/v4/channels"); var request = new RestRequest(Method.GET); request.AddHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN"); IRestResponse response = client.Execute(request);
var client = new HttpClient(); var request = new HttpRequestMessage { Method = HttpMethod.Get, RequestUri = new Uri("https://api.arattai.in/restapi/v4/channels"), Headers = { { "Authorization", "Bearer REPLACE_BEARER_TOKEN" }, }, }; using (var response = await client.SendAsync(request)) { response.EnsureSuccessStatusCode(); var body = await response.Content.ReadAsStringAsync(); Console.WriteLine(body); }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "https://api.arattai.in/restapi/v4/channels" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("Authorization", "Bearer REPLACE_BEARER_TOKEN") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
const data = null; const xhr = new XMLHttpRequest(); xhr.withCredentials = true; xhr.addEventListener("readystatechange", function () { if (this.readyState === this.DONE) { console.log(this.responseText); } }); xhr.open("GET", "https://api.arattai.in/restapi/v4/channels"); xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN"); xhr.send(data);
curl --request GET \ --url https://api.arattai.in/restapi/v4/channels \ --header 'Authorization: Bearer REPLACE_BEARER_TOKEN'

Response Example

{ "url": "/restapi/v4/channels", "type": "channel", "data": [ { "owner": { "name": "Ryan West", "id": "20034503234" }, "id": "CT_1468515074926458190_20034503234-PC", "photo_id": "CT_1468515074926458190_20034503234-PC|1793180886045", "creator": { "name": "Ryan West", "id": "20034503234" }, "role": "owner", "last_message": { "sender": { "id": "20034503234" }, "message": { "type": "info", "data": { "type": "new_channel", "title": "Design Discussions" }, "time": 1793180886263, "id": "1793180886263%206474491127" } }, "type": "public", "title": "Design Discussions", "created_time": 1793180886172, "participant_count": 1 }, { "owner": { "name": "Ryan West", "id": "20034503234" }, "id": "CT_1463817946756310789_20034503234-PC", "photo_id": "CT_1463817946756310789_20034503234-PC|1789641750559", "creator": { "name": "Ryan West", "id": "20034503234" }, "role": "owner", "last_message": { "sender": { "name": "Ryan West", "id": "20034503234" }, "message": { "type": "text", "content": "Here's the updated color palette for review.", "time": 1792993752944, "id": "1792993752944%20839511013232" } }, "type": "public", "title": "Product Updates", "created_time": 1789641750671, "participant_count": 2 } ] }

Send a message in a channel 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

Use this API to send a message in a specific channel. You can identify the channel using either its unique channel ID or its channel username (unique name).

Supported message types:

Note:
  • The sample request shown below illustrates a channel message payload using application/json.
  • Use this format for text, sticker, GIF, contact, and location messages.
  • For File messages, send the request as multipart/form-data instead, with the file and comment attached as form fields (see file in Arguments).

Threshold limit: 50 requests per min per user
Number of API calls allowed within a minute.

Lock period: 10 minutes
Wait time before consecutive API requests.


OAuth Scope : Arattai.Messages.CREATE

Arguments

text
string
  • Use this when you want to send a plain announcement, status update, or short message to the channel. Ideal for everyday communication and quick information sharing.
  • Maximum length: 1,000,000 characters.
unfurl
boolean
If true, the first link in the message will be unfurled into a rich preview.
sticker
object
Use this for fun or expressive replies and quick reactions in a channel. This is useful when a short visual response is more engaging than text.
Show Sub-Attributes arrow
type
string
(Required)
Type of sticker to be sent.
  • default: Use one of the predefined default stickers.
  • custom: Use a custom sticker uploaded by the user or workspace.
id
string
(Required)
  • Unique identifier of the sticker (e.g., :bunny#08_Bunny:). See the list of default sticker IDs for all accepted values.
  • Maximum length: 50 characters.
gif
object
Use this to share a reaction, meme, or animated visual that adds context or emotion to a channel update. Best suited for informal or engaging communication.
Show Sub-Attributes arrow
url
uri
(Required)
  • URL of the GIF to be sent. Must point to a valid GIF file.
  • Maximum length: 2,000 characters.
height
integer
Height of the GIF in pixels.
width
integer
Width of the GIF in pixels.
comment
string
  • Optional comment displayed with the GIF.
  • Maximum length: 1,000 characters.
contact
object
Use this when you want to share a person's contact information such as their name, phone number, or email in the channel.
Show Sub-Attributes arrow
name
string
(Required)
  • Full name of the contact.
  • Maximum length: 500 characters.
company
string
  • Contact's company name.
  • Maximum length: 500 characters.
photo
byte
  • Base64-encoded profile image of the contact.
  • Maximum length: 40,000 characters.
birthday
string
Contact's birthday in YYYY-MM-DD format.
phones
array
(Required)
  • List of phone numbers belonging to the contact.
  • Maximum items: 10.
Show Sub-Attributes arrow
phone
string
(Required)
Phone number in E.164 format.
type
string
Free-form label for the phone number type. This is not a fixed enum; any string is accepted. Common values include:
  • personal
  • home
  • work
  • mobile
emails
array
  • List of email addresses belonging to the contact.
  • Maximum items: 10.
Show Sub-Attributes arrow
email
email
(Required)
Email address.
type
string
Free-form label for the email address type. This is not a fixed enum; any string is accepted. Common values include:
  • home
  • work
  • other
location
object
Use this when you need to share a meeting point, office address, event venue, or place for group coordination in the channel.
Show Sub-Attributes arrow
name
string
(Required)
  • Name or label of the location.
  • Maximum length: 500 characters.
latitude
string
(Required)
  • Latitude coordinate of the location.
  • Maximum length: 500 characters.
longitude
string
(Required)
  • Longitude coordinate of the location.
  • Maximum length: 500 characters.
location
string
  • Human-readable address or place description for the coordinates above (e.g., street address, venue name, or city/state/country). This is a separate text field from the location object that contains it.
  • Maximum length: 500 characters.
file
binary
(Required) Required for File messages
  • Use this when you want to share a document, image, or video file in the channel.
  • Send this as a multipart/form-data form field named file (not nested inside a JSON body).
  • Note: Maximum allowed file size is 4 GB. Uploaded files are scanned for viruses before delivery.
comment
string
  • Optional caption shown alongside the uploaded file.
  • Send this as a multipart/form-data form field named comment.
  • Maximum length: 64,000 characters.

Path Parameters

CHANNEL_ID
string
(Required)
Unique identifier or unique name (username) of the channel where the message is to be posted.

You can use either:
  • Channel ID: The system-generated unique identifier (e.g., CT_12091PUB).
  • Channel unique name: The human-readable channel username (e.g., design_discussions). This avoids the need to look up the channel ID separately.

Request Example

Click to copy
parameters_data='{"field1":"value1","field2":"value2"}'; headers_data = Map(); headers_data.put("Authorization", "Bearer REPLACE_BEARER_TOKEN"); response = invokeUrl [ url: "https://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages" 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://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages") .post(body) .addHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN") .addHeader("content-type", "application/json") .build(); Response response = client.newCall(request).execute();
const options = { method: 'POST', headers: { Authorization: 'Bearer REPLACE_BEARER_TOKEN', 'content-type': 'application/json' }, body: '{"field1":"value1","field2":"value2"}' }; fetch('https://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("api.arattai.in") payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}" headers = { 'Authorization': "Bearer REPLACE_BEARER_TOKEN", 'content-type': "application/json" } conn.request("POST", "/restapi/v4/channels/CHANNEL_ID/messages", payload, headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "POST", "hostname": "api.arattai.in", "port": null, "path": "/restapi/v4/channels/CHANNEL_ID/messages", "headers": { "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://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages"); var request = new RestRequest(Method.POST); 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://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages"), Headers = { { "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://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages" payload := strings.NewReader("{\"field1\":\"value1\",\"field2\":\"value2\"}") req, _ := http.NewRequest("POST", url, payload) 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://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages"); xhr.setRequestHeader("Authorization", "Bearer REPLACE_BEARER_TOKEN"); xhr.setRequestHeader("content-type", "application/json"); xhr.send(data);
curl --request POST \ --url https://api.arattai.in/restapi/v4/channels/CHANNEL_ID/messages \ --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \ --header 'content-type: application/json' \ --data '{"field1":"value1","field2":"value2"}'

Body Parameters

Click to copy
{ "text": "Hello team, please review the latest project updates" }
{ "sticker": { "type": "default", "id": ":bunny#08_Bunny:" } }
{ "gif": { "url": "https://media.tenor.com/8cp2iBtz68kAAAAC/fall-fall-season.gif", "height": 328, "width": 498, "comment": "Autumn vibes!" } }
{ "contact": { "name": "John Doe", "photo": "iVBORw0KGgoAAAANSUhEUgAAAAEAAwMCAO+j0X8AAAAASUVORK5CYII=", "phones": [ { "phone": "+1234567890", "type": "work" } ] } }
{ "location": { "name": "Central Park", "location": "New York, NY, USA", "latitude": "40.785091", "longitude": "-73.968285" } }
{ "file": "<binary file data>", "comment": "Here's the final design file." }

Response Example

{...}