Skip to main content
GET
/
v1
/
portal
/
chats
/
{chat_id}
/
invites
curl https://portal-api.7331.org/v1/portal/chats/42/invites \
  -b "psession=YOUR_SESSION"
{
  "invites": [
    {
      "code": "abc123def456ghi7",
      "chat_id": 42,
      "created_by_id": 1,
      "created_at": "2026-03-16T12:00:00Z",
      "expires_at": "2026-05-01T00:00:00Z",
      "uses": 3,
      "max_uses": 10
    }
  ]
}

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.

Requires an active session cookie. Access is controlled by can_manage_room() hierarchy:
  • Private chats: owner only.
  • Public / Official chats: chat owner, or any user whose permission level lets them act on the chat owner (e.g. Mods can manage User-owned chats, Admins can manage Mod/User-owned chats, Owners can manage any chat).
Only returns invites that have not yet expired and have not been exhausted.
chat_id
integer
required
Chat ID.

Response

invites
array
required
List of active invite codes. Each entry contains:
curl https://portal-api.7331.org/v1/portal/chats/42/invites \
  -b "psession=YOUR_SESSION"
{
  "invites": [
    {
      "code": "abc123def456ghi7",
      "chat_id": 42,
      "created_by_id": 1,
      "created_at": "2026-03-16T12:00:00Z",
      "expires_at": "2026-05-01T00:00:00Z",
      "uses": 3,
      "max_uses": 10
    }
  ]
}