Actions60
- User Actions
- Channel Actions
- Accept Invite
- Add Members
- Add Moderators
- Archive
- Ban User
- Create
- Delete
- Delete File
- Delete Image
- Demote Moderators
- Disable Slow Mode
- Enable Slow Mode
- Get Config
- Hide
- Invite Members
- Mark Read
- Mark Unread
- Mute
- Mute Status
- Pin
- Query Channels
- Query Members
- Reject Invite
- Remove Members
- Send Action
- Send File
- Send Image
- Show
- Stop Watching
- Truncate
- Unarchive
- Unban User
- Unmute
- Unpin
- Update
- Watch
- Message Actions
- Moderation Actions
Overview
This node performs server-side operations on Stream Chat channels, enabling management and interaction with chat channels in a programmatic way. It is useful for automating channel administration tasks such as pinning or unpinning channels for specific users, managing memberships, archiving, muting, sending files, and more.
For the Pin operation on the Channel resource, the node pins a specified channel for a given user. Pinning a channel typically makes it more accessible or highlighted in the user's chat interface, helping users quickly find important or frequently used channels.
Practical example:
- Automatically pin a team channel for new members when they join to ensure they see critical announcements.
- Pin a support channel for customer service agents so it stays at the top of their chat list.
Properties
| Name | Meaning |
|---|---|
| Channel Type | The type of the channel. Common options: "messaging" (1-on-1 chats), "team" (group channels), "livestream" (broadcast channels). |
| Channel ID | Unique identifier for the channel (e.g., "general", "random", "team-alpha"). Combined with type to form the full channel ID (CID). |
| User ID | The user ID for whom the channel will be pinned. This identifies the user performing the pin action. |
Output
The output JSON contains the response from the Stream Chat API after attempting to pin the channel for the user. This typically includes details about the updated channel state or confirmation of the pin action.
Example output structure:
{
"pinned": true,
"channel": {
"cid": "messaging:general",
"id": "general",
"type": "messaging",
...
},
"user_id": "user123"
}
No binary data is output by this operation.
Dependencies
- Requires an API key credential for authenticating with the Stream Chat service.
- The node uses the official Stream Chat server-side client library to perform operations.
- Proper permissions must be granted to the API key to allow channel pinning actions.
Troubleshooting
Common issues:
- Invalid or missing
channelIdoruserIdparameters will cause errors. - Insufficient permissions on the API key may result in authorization errors.
- Specifying a non-existent channel or user will lead to not found errors.
- Invalid or missing
Error messages:
"Unsupported operation: channel.pin"— indicates the operation is not recognized; verify the resource and operation names.- API errors related to authentication or permissions should be resolved by checking the API key credentials.
- Errors mentioning invalid channel or user IDs require verifying that these identifiers exist in your Stream Chat app.
Links and References
- Stream Chat Documentation – Official docs for Stream Chat API and features.
- Stream Chat Server SDK – Details on server-side client usage.
- n8n Documentation – For general guidance on using n8n nodes and credentials.