Skip to main content
POST
/
v1
/
portal
/
chats
/
{chat_id}
/
timeout
curl -X POST https://portal-api.7331.org/v1/portal/chats/42/timeout \
  -H "Content-Type: application/json" \
  -b "psession=YOUR_SESSION" \
  -d '{"user_id": 7, "duration": 3600, "reason": "Harassment"}'
{
  "ok": true
}

Documentation Index

Fetch the complete documentation index at: https://docs.7331.org/llms.txt

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

Applies a time-limited punishment to a user. The timeout is platform-scoped (stored in the DB) — the user will be unable to access the platform until the timeout expires. Their active sessions are force-disconnected via IPC. Authorization: Chat owner can always timeout in their own chat. For public/official chats, any user who outranks the chat owner (via permission hierarchy) can also timeout. Moderators cannot timeout in private chats — only the chat owner or Admin+ can.
chat_id
integer
required
Chat ID (used for authorization context and system message).
user_id
integer
required
Entity ID of the user to timeout.
duration
integer
required
Timeout duration in seconds. Minimum: 60 (1 minute). Maximum: 2592000 (30 days).
reason
string
Reason for the timeout. Max 500 characters.

Response

ok
boolean
required
true if the timeout was applied.
curl -X POST https://portal-api.7331.org/v1/portal/chats/42/timeout \
  -H "Content-Type: application/json" \
  -b "psession=YOUR_SESSION" \
  -d '{"user_id": 7, "duration": 3600, "reason": "Harassment"}'
{
  "ok": true
}
Timeouts are platform-wide. The user will be disconnected from all chats and unable to reconnect until the timeout expires.
For a permanent removal, use Ban User instead.