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
The node provides server-side operations for managing users in a Stream Chat application. Specifically, the "User Deactivate" operation allows you to deactivate a user account by their unique identifier. This is useful when you want to disable a user's access without deleting their data, for example, when a user leaves your platform or violates terms of service.
Practical examples:
- Automatically deactivate users who have been inactive for a long time.
- Temporarily disable user accounts during investigations or moderation.
- Integrate with HR systems to deactivate employees' chat accounts upon termination.
Properties
| Name | Meaning |
|---|---|
| User ID | A unique identifier for the user to be deactivated. Can be any string (e.g., "john_doe"). |
Output
The output JSON contains the response from the Stream Chat API after attempting to deactivate the specified user. It typically includes details about the deactivated user or confirmation of the action. The exact structure depends on the API but generally confirms success or provides error information.
No binary data is output by this operation.
Example output snippet (conceptual):
{
"id": "user123",
"deactivated": true,
"updated_at": "2024-01-01T12:00:00Z"
}
Dependencies
- Requires an API key credential configured in n8n to authenticate with the Stream Chat service.
- The node uses the Stream Chat server-side client library internally.
- Ensure the API key has permissions to perform user management operations, including deactivation.
Troubleshooting
Common issues:
- Invalid or missing User ID: The operation requires a valid user identifier; ensure it is provided and correctly formatted.
- Insufficient permissions: The API key must have rights to deactivate users; otherwise, the request will fail.
- Network or API errors: Connectivity issues or rate limits may cause failures.
Error messages:
"Unsupported operation: user.deactivateUser": Indicates the operation name might be incorrect or not supported; verify the operation parameter.- API errors returned from Stream Chat will be included in the node's error output; check the message for details like invalid user or permission denied.
To resolve errors, verify input parameters, API credentials, and network connectivity.