FleetbaseFleetbase

Chat Channels

Chat channels organize conversations between users and participants in an organization. Use chat channel endpoints to create rooms, send messages, manage participants, and record read receipts.

The Chat Channel object

A chat channel groups participants and messages for organization-scoped conversations.
Attributes
idstringoptional

Public identifier of the chat channel.

created_bystringoptional

Public user ID of the user that created the channel.

namestringoptional

Channel name.

titlestringoptional

Display title for the channel.

last_messageobjectoptional

Most recent chat message for the channel, when available.

unread_countintegeroptional

Unread message count for the current session user when session context is available.

slugstringoptional

URL-friendly channel slug.

feedarray of objectsoptional

Messages and feed entries returned for the channel.

participantsarray of objectsoptional

Chat participants in the channel.

metaobjectoptional

Arbitrary metadata stored with the channel.

updated_attimestampoptional

Time the channel was last updated.

created_attimestampoptional

Time the channel was created.

deleted_attimestampoptional

Time the channel was deleted, when soft deleted.

The Chat Channel object
{
  "id": "chat_channel_5VUl2v4",
  "created_by": "user_8xP2L1d",
  "name": "Dispatch updates",
  "title": "Dispatch updates",
  "last_message": null,
  "slug": "dispatch-updates",
  "feed": [],
  "participants": [],
  "meta": {},
  "updated_at": "2026-05-07T09:30:00Z",
  "created_at": "2026-05-07T09:30:00Z",
  "deleted_at": null
}
GET/v1/chat-channels/available-participants

List Available Participants

Lists users in the current organization that can be added to a chat channel. When a channel ID is provided, users already participating in that channel are excluded.

Query parameters
channelstringoptional

Channel value for this chat channels request.

GET/v1/chat-channels/available-participants
curl https://api.fleetbase.io/v1/chat-channels/available-participants?channel={{chat_channel_id}} \
  -H "Authorization: Bearer flb_live_…"
POST/v1/chat-channels/:id/send-message

Send Message

Sends a message to a chat channel as an existing chat participant. File IDs can be included to attach previously uploaded files to the message.

Body parameters
senderstringrequired

Public ID of the chat participant sending the message.

contentstringoptional

Message text to publish to the channel.

filesarray of stringsoptional

Public IDs of uploaded files to attach to the message.

POST/v1/chat-channels/:id/send-message
curl -X POST https://api.fleetbase.io/v1/chat-channels/:id/send-message \
  -H "Authorization: Bearer flb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "sender": "{{chat_participant_id}}",
  "content": "Hello from Fleetbase API",
  "files": []
}'
DELETE/v1/chat-channels/delete-message/:chatMessageId

Delete Message

Deletes a chat message by ID. Use this when a previously sent message should be removed from the channel feed.

DELETE/v1/chat-channels/delete-message/:chatMessageId
curl -X DELETE https://api.fleetbase.io/v1/chat-channels/delete-message/:chatMessageId \
  -H "Authorization: Bearer flb_live_…"
POST/v1/chat-channels/read-message/:chatMessageId

Create Read Receipt

Marks a chat message as read for a participant. If a receipt already exists for the message and participant, Fleetbase returns the existing receipt.

Body parameters
participantstringrequired

Public ID of the chat participant that read the message.

POST/v1/chat-channels/read-message/:chatMessageId
curl -X POST https://api.fleetbase.io/v1/chat-channels/read-message/:chatMessageId \
  -H "Authorization: Bearer flb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "participant": "{{chat_participant_id}}"
}'
POST/v1/chat-channels

Create Chat Channel

Creates a chat channel for the current organization. Include participant user IDs to add those users to the channel immediately after it is created.

Body parameters
namestringrequired

Name of the chat channel.

participantsarray of stringsoptional

Public user IDs to add as participants after the channel is created.

POST/v1/chat-channels
curl -X POST https://api.fleetbase.io/v1/chat-channels \
  -H "Authorization: Bearer flb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Dispatch",
  "participants": [
    "{{user_id}}"
  ]
}'
PUT/v1/chat-channels/:id

Update Chat Channel

Updates a chat channel's name. The response returns the updated chat channel resource.

Body parameters
namestringrequired

Updated channel name.

PUT/v1/chat-channels/:id
curl -X PUT https://api.fleetbase.io/v1/chat-channels/:id \
  -H "Authorization: Bearer flb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Dispatch Updates"
}'
GET/v1/chat-channels

Query Chat Channels

Returns chat channels visible to the current organization. Use query parameters to filter, sort, and paginate the result set.

Query parameters
limitstringoptional

Limit value for this chat channels request.

offsetstringoptional

Offset value for this chat channels request.

sortstringoptional

Sort value for this chat channels request.

GET/v1/chat-channels
curl https://api.fleetbase.io/v1/chat-channels?limit=25&offset=0&sort=created_at \
  -H "Authorization: Bearer flb_live_…"
GET/v1/chat-channels/:id

Retrieve Chat Channel

Retrieves a chat channel by ID, including its participants, feed, and latest message metadata.

GET/v1/chat-channels/:id
curl https://api.fleetbase.io/v1/chat-channels/:id \
  -H "Authorization: Bearer flb_live_…"
DELETE/v1/chat-channels/:id

Delete Chat Channel

Deletes a chat channel by ID. The response returns a deleted-resource envelope for the removed channel.

DELETE/v1/chat-channels/:id
curl -X DELETE https://api.fleetbase.io/v1/chat-channels/:id \
  -H "Authorization: Bearer flb_live_…"
POST/v1/chat-channels/:id/add-participant

Add Participant

Adds a user in the current organization to an existing chat channel. The response returns the created chat participant resource.

Body parameters
userstringrequired

Public ID of the user to add to the chat channel.

POST/v1/chat-channels/:id/add-participant
curl -X POST https://api.fleetbase.io/v1/chat-channels/:id/add-participant \
  -H "Authorization: Bearer flb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "user": "{{user_id}}"
}'
DELETE/v1/chat-channels/remove-participant/:participantId

Remove Participant

Removes a participant from a chat channel by participant ID. The channel remains active for the remaining participants.

DELETE/v1/chat-channels/remove-participant/:participantId
curl -X DELETE https://api.fleetbase.io/v1/chat-channels/remove-participant/:participantId \
  -H "Authorization: Bearer flb_live_…"
Chat Channels | Fleetbase