Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.spojit.com/llms.txt

Use this file to discover all available pages before exploring further.

The Slack connector lets your workflows send messages, manage channels, search for content, and interact with your Slack workspace.
For the full API reference, see the Slack API documentation.

Connection setup

1

Create a Slack app

Go to api.slack.com/apps and click Create New App. Choose From scratch, name it (e.g., “Spojit”), and select your workspace.
2

Add bot token scopes

Navigate to OAuth & Permissions and add the following Bot Token Scopes:
  • chat:write — Send messages
  • channels:read — List channels
  • channels:history — Read message history
  • users:read — List users
  • reactions:write — Add/remove reactions
  • pins:write — Pin/unpin messages
  • search:read — Search messages
  • bookmarks:write — Manage bookmarks
3

Install to workspace

Click Install to Workspace and authorize the app. Copy the Bot User OAuth Token (starts with xoxb-).
4

Add the connection in Spojit

Go to Connections in Spojit, click Add Connection, select Slack, and enter:
  • Bot Token: The xoxb-... token you copied
Invite your Slack bot to channels where it needs to send messages. In Slack, open the channel and type /invite @YourBotName.

Tools

Messages

channel
string
required
Channel ID (e.g., C01234567).
text
string
required
Message text.
blocks
object[]
Block Kit blocks for rich formatting.
thread_ts
string
Parent message timestamp to reply in a thread.
Unfurl links in the message.
unfurl_media
boolean
default:"true"
Unfurl media in the message.
Example request:
{
  "channel": "C123ABC456",
  "text": "Here's a message for you"
}
Example response:
{
  "ok": true,
  "channel": "C123ABC456",
  "ts": "1503435956.000247",
  "message": {
    "text": "Here's a message for you",
    "username": "ecto1",
    "bot_id": "B123ABC456",
    "type": "message",
    "subtype": "bot_message",
    "ts": "1503435956.000247"
  }
}
channel
string
required
Channel ID.
ts
string
required
Message timestamp.
text
string
New message text.
blocks
object[]
Block Kit blocks for rich formatting.
Example request:
{
  "channel": "C123ABC456",
  "ts": "1401383885.000061",
  "text": "Updated text you carefully authored"
}
Example response:
{
  "ok": true,
  "channel": "C123ABC456",
  "ts": "1401383885.000061",
  "text": "Updated text you carefully authored",
  "message": {
    "text": "Updated text you carefully authored",
    "user": "U34567890"
  }
}
channel
string
required
Channel ID.
ts
string
required
Message timestamp.
Example request:
{
  "channel": "C123ABC456",
  "ts": "1401383885.000061"
}
Example response:
{
  "ok": true,
  "channel": "C123ABC456",
  "ts": "1401383885.000061"
}
query
string
required
Search query string.
sort
string
default:"score"
Sort by score or timestamp.
sort_dir
string
default:"desc"
Sort direction: asc or desc.
count
number
default:"20"
Number of results (max 100).
Example request:
{
  "query": "The meaning of life the universe and everything",
  "sort": "score",
  "sort_dir": "desc",
  "count": 20
}
Example response:
{
  "ok": true,
  "query": "The meaning of life the universe and everything",
  "messages": {
    "total": 2,
    "matches": [
      {
        "channel": {
          "id": "C12345678",
          "is_private": false,
          "name": "general"
        },
        "iid": "cb64bdaa-c1e8-4631-8a91-0f78080113e9",
        "permalink": "https://hitchhikers.slack.com/archives/C12345678/p1508284197000015",
        "team": "T12345678",
        "text": "The meaning of life the universe and everything is 42.",
        "ts": "1508284197.000015",
        "type": "message",
        "user": "U2U85N1RV",
        "username": "roach"
      }
    ],
    "pagination": {
      "first": 1,
      "last": 2,
      "page": 1,
      "page_count": 1,
      "per_page": 20,
      "total_count": 2
    }
  }
}

Channels

types
string
Comma-separated channel types to include.
exclude_archived
boolean
default:"false"
Exclude archived channels.
limit
number
default:"100"
Max results (max 1000).
cursor
string
Pagination cursor.
Example request:
{
  "exclude_archived": true,
  "limit": 100
}
Example response:
{
  "ok": true,
  "channels": [
    {
      "id": "C012AB3CD",
      "name": "general",
      "is_channel": true,
      "is_group": false,
      "is_im": false,
      "created": 1449252889,
      "creator": "U012A3CDE",
      "is_archived": false,
      "is_general": true,
      "name_normalized": "general",
      "is_shared": false,
      "is_private": false,
      "is_mpim": false,
      "topic": {
        "value": "Company-wide announcements and work-based matters",
        "creator": "",
        "last_set": 0
      },
      "purpose": {
        "value": "This channel is for team-wide communication and announcements.",
        "creator": "",
        "last_set": 0
      },
      "num_members": 4
    }
  ],
  "response_metadata": {
    "next_cursor": "dGVhbTpDMDYxRkE1UEI="
  }
}
channel
string
required
Channel ID.
Example request:
{
  "channel": "C012AB3CD"
}
Example response:
{
  "ok": true,
  "channel": {
    "id": "C012AB3CD",
    "name": "general",
    "is_channel": true,
    "is_group": false,
    "is_im": false,
    "is_mpim": false,
    "is_private": false,
    "created": 1654868334,
    "is_archived": false,
    "is_general": true,
    "name_normalized": "general",
    "creator": "U123ABC456",
    "topic": {
      "value": "For public discussion of generalities",
      "creator": "W012A3BCD",
      "last_set": 1449709364
    },
    "purpose": {
      "value": "This part of the workspace is for fun. Make fun here.",
      "creator": "W012A3BCD",
      "last_set": 1449709364
    },
    "previous_names": []
  }
}
channel
string
required
Channel ID.
limit
number
default:"100"
Max messages (max 1000).
cursor
string
Pagination cursor.
oldest
string
Only messages after this Unix timestamp.
latest
string
Only messages before this Unix timestamp.
Example request:
{
  "channel": "C123ABC456",
  "limit": 100
}
Example response:
{
  "ok": true,
  "messages": [
    {
      "type": "message",
      "user": "U123ABC456",
      "text": "I find you punny and would like to smell your nose letter",
      "ts": "1512085950.000216"
    },
    {
      "type": "message",
      "user": "U222BBB222",
      "text": "What, you want to smell my shoes better?",
      "ts": "1512104434.000490"
    }
  ],
  "has_more": true,
  "pin_count": 0,
  "response_metadata": {
    "next_cursor": "bmV4dF90czoxNTEyMDg1ODYxMDAwNTQz"
  }
}
channel
string
required
Channel ID.
ts
string
required
Parent message timestamp.
limit
number
default:"100"
Max replies (max 1000).
cursor
string
Pagination cursor.
Example request:
{
  "channel": "C123ABC456",
  "ts": "1482960137.003543",
  "limit": 100
}
Example response:
{
  "ok": true,
  "messages": [
    {
      "type": "message",
      "user": "U061F7AUR",
      "text": "island",
      "thread_ts": "1482960137.003543",
      "reply_count": 3,
      "subscribed": true,
      "ts": "1482960137.003543"
    },
    {
      "type": "message",
      "user": "U061F7AUR",
      "text": "one island",
      "thread_ts": "1482960137.003543",
      "parent_user_id": "U061F7AUR",
      "ts": "1483037603.017503"
    },
    {
      "type": "message",
      "user": "U061F7AUR",
      "text": "two island",
      "thread_ts": "1482960137.003543",
      "parent_user_id": "U061F7AUR",
      "ts": "1483051909.018632"
    }
  ],
  "has_more": true,
  "response_metadata": {
    "next_cursor": "bmV4dF90czoxNDg0Njc4MjkwNTE3MDkx"
  }
}
name
string
required
Channel name (lowercase, no spaces, max 80 characters).
is_private
boolean
default:"false"
Create as a private channel.
Example request:
{
  "name": "endeavor",
  "is_private": false
}
Example response:
{
  "ok": true,
  "channel": {
    "id": "C0EAQDV4Z",
    "name": "endeavor",
    "is_channel": true,
    "is_group": false,
    "is_im": false,
    "created": 1504554479,
    "creator": "U0123456",
    "is_archived": false,
    "is_general": false,
    "name_normalized": "endeavor",
    "is_shared": false,
    "is_private": false,
    "is_mpim": false,
    "topic": {
      "value": "",
      "creator": "",
      "last_set": 0
    },
    "purpose": {
      "value": "",
      "creator": "",
      "last_set": 0
    },
    "previous_names": [],
    "priority": 0
  }
}
channel
string
required
Channel ID.
users
string
required
Comma-separated user IDs.
Example request:
{
  "channel": "C012AB3CD",
  "users": "U123ABC456,U234BCD567"
}
Example response:
{
  "ok": true,
  "channel": {
    "id": "C012AB3CD",
    "name": "general",
    "is_channel": true,
    "is_group": false,
    "is_im": false,
    "created": 1449252889,
    "creator": "W012A3BCD",
    "is_archived": false,
    "is_general": true,
    "name_normalized": "general",
    "is_member": true,
    "is_private": false,
    "is_mpim": false,
    "topic": {
      "value": "For public discussion of generalities",
      "creator": "W012A3BCD",
      "last_set": 1449709364
    },
    "purpose": {
      "value": "This part of the workspace is for fun. Make fun here.",
      "creator": "W012A3BCD",
      "last_set": 1449709364
    },
    "previous_names": ["specifics", "abstractions", "etc"]
  }
}
channel
string
required
Channel ID.
topic
string
required
New topic text.
Example request:
{
  "channel": "C12345678",
  "topic": "Apply topically for best effects"
}
Example response:
{
  "ok": true,
  "channel": {
    "id": "C12345678",
    "name": "tips-and-tricks",
    "is_channel": true,
    "is_private": false,
    "created": 1649195947,
    "is_archived": false,
    "is_general": false,
    "name_normalized": "tips-and-tricks",
    "creator": "U12345678",
    "is_member": true,
    "topic": {
      "value": "Apply topically for best effects",
      "creator": "U12345678",
      "last_set": 1649952691
    },
    "purpose": {
      "value": "",
      "creator": "",
      "last_set": 0
    },
    "previous_names": []
  }
}

Users

limit
number
default:"100"
Max results (max 1000).
cursor
string
Pagination cursor.
Example request:
{
  "limit": 100
}
Example response:
{
  "ok": true,
  "members": [
    {
      "id": "W012A3CDE",
      "team_id": "T012AB3C4",
      "name": "spengler",
      "deleted": false,
      "color": "9f69e7",
      "real_name": "Egon Spengler",
      "tz": "America/Los_Angeles",
      "tz_label": "Pacific Daylight Time",
      "tz_offset": -25200,
      "profile": {
        "avatar_hash": "ge3b51ca72de",
        "status_text": "Print is dead",
        "status_emoji": ":books:",
        "real_name": "Egon Spengler",
        "display_name": "spengler",
        "email": "spengler@ghostbusters.example.com",
        "image_24": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
        "image_512": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
        "team": "T012AB3C4"
      },
      "is_admin": true,
      "is_owner": false,
      "is_bot": false,
      "updated": 1502138686,
      "has_2fa": false
    }
  ],
  "cache_ts": 1498777272,
  "response_metadata": {
    "next_cursor": "dXNlcjpVMEc5V0ZYTlo="
  }
}
user
string
required
User ID.
Example request:
{
  "user": "W012A3CDE"
}
Example response:
{
  "ok": true,
  "user": {
    "id": "W012A3CDE",
    "team_id": "T012AB3C4",
    "name": "spengler",
    "deleted": false,
    "color": "9f69e7",
    "real_name": "Egon Spengler",
    "tz": "America/Los_Angeles",
    "tz_label": "Pacific Daylight Time",
    "tz_offset": -25200,
    "profile": {
      "avatar_hash": "ge3b51ca72de",
      "status_text": "Print is dead",
      "status_emoji": ":books:",
      "real_name": "Egon Spengler",
      "display_name": "spengler",
      "real_name_normalized": "Egon Spengler",
      "display_name_normalized": "spengler",
      "email": "spengler@ghostbusters.example.com",
      "image_original": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
      "image_24": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
      "image_512": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
      "team": "T012AB3C4"
    },
    "is_admin": true,
    "is_owner": false,
    "is_primary_owner": false,
    "is_restricted": false,
    "is_ultra_restricted": false,
    "is_bot": false,
    "updated": 1502138686,
    "is_app_user": false,
    "has_2fa": false
  }
}
email
string
required
Email address.
Example request:
{
  "email": "spengler@ghostbusters.example.com"
}
Example response:
{
  "ok": true,
  "user": {
    "id": "W012A3CDE",
    "team_id": "T012AB3C4",
    "name": "spengler",
    "deleted": false,
    "color": "9f69e7",
    "real_name": "Egon Spengler",
    "tz": "America/Los_Angeles",
    "tz_label": "Pacific Daylight Time",
    "tz_offset": -25200,
    "profile": {
      "avatar_hash": "ge3b51ca72de",
      "status_text": "Print is dead",
      "status_emoji": ":books:",
      "real_name": "Egon Spengler",
      "display_name": "spengler",
      "email": "spengler@ghostbusters.example.com",
      "image_24": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
      "image_512": "https://.../avatar/e3b51ca72dee4ef87916ae2b9240df50.jpg",
      "team": "T012AB3C4"
    },
    "is_admin": true,
    "is_owner": false,
    "is_bot": false,
    "updated": 1502138686,
    "has_2fa": false
  }
}

Reactions

channel
string
required
Channel ID.
timestamp
string
required
Message timestamp.
name
string
required
Emoji name without colons (e.g., thumbsup).
Example request:
{
  "channel": "C123ABC456",
  "timestamp": "1503435956.000247",
  "name": "thumbsup"
}
Example response:
{
  "ok": true
}
channel
string
required
Channel ID.
timestamp
string
required
Message timestamp.
name
string
required
Emoji name without colons.
Example request:
{
  "channel": "C123ABC456",
  "timestamp": "1503435956.000247",
  "name": "thumbsup"
}
Example response:
{
  "ok": true
}

Pins

channel
string
required
Channel ID.
timestamp
string
required
Message timestamp.
Example request:
{
  "channel": "C123ABC456",
  "timestamp": "1508197641.000151"
}
Example response:
{
  "ok": true
}
channel
string
required
Channel ID.
timestamp
string
required
Message timestamp.
Example request:
{
  "channel": "C123ABC456",
  "timestamp": "1508197641.000151"
}
Example response:
{
  "ok": true
}
channel
string
required
Channel ID.
Example request:
{
  "channel": "C123ABC456"
}
Example response:
{
  "ok": true,
  "items": [
    {
      "channel": "C123ABC456",
      "created": 1508881078,
      "created_by": "U123ABC456",
      "message": {
        "permalink": "https://hitchhikers.slack.com/archives/C2U86NC6H/p1508197641000151",
        "pinned_to": ["C2U86NC6H"],
        "text": "What is the meaning of life?",
        "ts": "1508197641.000151",
        "type": "message",
        "user": "U123ABC456"
      },
      "type": "message"
    },
    {
      "channel": "C123ABC456",
      "created": 1508880991,
      "created_by": "U123ABC456",
      "message": {
        "permalink": "https://hitchhikers.slack.com/archives/C2U86NC6H/p1508284197000015",
        "pinned_to": ["C123ABC456"],
        "text": "The meaning of life, the universe, and everything is 42.",
        "ts": "1503289197.000015",
        "type": "message",
        "user": "U123ABC456"
      },
      "type": "message"
    }
  ]
}

Bookmarks

channel_id
string
required
Channel ID.
title
string
required
Bookmark title.
type
string
required
Bookmark type (e.g., link).
URL for the bookmark.
emoji
string
Emoji icon for the bookmark.
Example request:
{
  "channel_id": "C1RQ000",
  "title": "bookmark-1",
  "type": "link",
  "link": "https://google.com",
  "emoji": ":clap:"
}
Example response:
{
  "ok": true,
  "bookmark": {
    "id": "Bk033XFJ9BTJ",
    "channel_id": "C1RQ000",
    "title": "bookmark-1",
    "link": "https://google.com",
    "emoji": ":clap:",
    "icon_url": "https://www.google.com/favicon.ico",
    "type": "link",
    "date_created": 1644956055,
    "date_updated": 0,
    "rank": "g",
    "last_updated_by_user_id": "U0334B6G6G5",
    "last_updated_by_team_id": "T018DF03GHY"
  }
}

Advanced

method
string
required
Slack API method name (e.g., chat.postMessage).
http_method
string
required
HTTP method: GET or POST.
params
object
Request parameters.
Example request:
{
  "method": "chat.postMessage",
  "http_method": "POST",
  "params": {
    "channel": "C123ABC456",
    "text": "Hello from a raw API call!"
  }
}
Example response:
{
  "ok": true,
  "channel": "C123ABC456",
  "ts": "1503435956.000247",
  "message": {
    "text": "Hello from a raw API call!",
    "username": "ecto1",
    "bot_id": "B123ABC456",
    "type": "message",
    "subtype": "bot_message",
    "ts": "1503435956.000247"
  }
}