Stream Chat icon

Stream Chat

Server-side Stream Chat operations

Overview

The node performs server-side operations on Stream Chat channels, enabling management and manipulation of chat channels within the Stream Chat platform. Specifically, the Delete Channel operation allows users to delete a channel identified by its type and ID, with an option for hard deletion (permanent removal).

This operation is useful in scenarios such as:

  • Removing obsolete or inactive chat channels.
  • Cleaning up test or temporary channels.
  • Enforcing moderation policies by deleting problematic channels.

For example, you might delete a group chat channel named "team-alpha" of type "team" when the project ends, optionally choosing to permanently remove all associated data.

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).
Hard Delete Boolean flag indicating whether to permanently delete the channel (true) or perform a soft delete (false).

Output

The output JSON contains the response from the Stream Chat API after attempting to delete the specified channel. This typically includes confirmation details about the deletion status or any relevant metadata returned by the API.

No binary data is output by this operation.

Example output structure (simplified):

{
  "channel": {
    "type": "team",
    "id": "team-alpha",
    "deleted_at": "2024-06-01T12:00:00Z"
  },
  "hard_delete": true,
  "status": "success"
}

(Note: Actual fields depend on the Stream Chat API response.)

Dependencies

  • Requires a valid API key credential for Stream Chat with permissions to manage channels.
  • The node uses the Stream Chat server-side client SDK internally.
  • Proper configuration of the API credentials in n8n is necessary for authentication.

Troubleshooting

  • Common issues:

    • Invalid or missing Channel ID or Channel Type parameters.
    • Insufficient permissions in the API key to delete channels.
    • Attempting to delete a non-existent channel.
  • Error messages:

    • "Unsupported operation: channel.deleteChannel": Indicates the operation was not recognized; ensure the correct resource and operation are selected.
    • API errors related to authorization or invalid parameters will be passed through; check that the channel exists and credentials have proper rights.
  • Resolution tips:

    • Verify the Channel ID and Channel Type inputs are correct and correspond to existing channels.
    • Confirm the API key has channel deletion permissions.
    • Use the "Hard Delete" option carefully; if unsure, start with soft delete (false).

Links and References


This summary focuses on the Channel > Delete operation as requested, based on static analysis of the provided source code and property definitions.

Discussion