Command index
Every command is a JSON object sent over the WebSocket at /. The cmd field names the command. Each page lists the request fields, the response, who may call it, and the errors it returns.
Before sending commands, read the protocol model. It covers the rules every command shares: the handshake, authentication, the listener field for matching responses to requests, and error frames. Frames the server sends on its own, without a request, are listed under server events.
Connection and session
Section titled “Connection and session”Authenticate a connection, check features, and keep it alive.
auth, capabilities, typing, ping
Authentication
Section titled “Authentication”Sign in or create a local account on the server.
Access control
Section titled “Access control”Decide who can join: open, whitelist, password, application, or invite.
access_mode_get, access_mode_set, whitelist_add, whitelist_remove, whitelist_list, server_password_set, application_submit, application_list, application_review, application_delete, invite_create, invite_list, invite_delete
Channels
Section titled “Channels”List and manage channels.
channels_get, channel_get, channel_create, channel_update, channel_move, channel_delete
Messages
Section titled “Messages”Send, fetch, search, edit, and pin messages.
message_new, messages_batch, message_get, message_replies, messages_get, messages_around, messages_search, message_edit, message_delete, message_pin, message_unpin, messages_pinned
Reactions
Section titled “Reactions”React to messages. message_react_add and message_react_remove are aliases.
Vote in and close polls. Create a poll with message_new.
Fetch messages that mentioned you.
Unreads
Section titled “Unreads”Track read position per channel and thread.
Threads
Section titled “Threads”Create and manage threads and forum posts.
threads_get, thread_create, thread_get, thread_update, thread_delete, thread_join, thread_leave, thread_pin, thread_unpin
Users and presence
Section titled “Users and presence”List members, set presence, and moderate users.
users_list, users_online, status_get, status_set, user_update, user_leave, user_kick, user_timeout, user_ban, user_unban, users_banned
Manage roles and the roles users can pick for themselves.
roles_list, role_create, role_update, role_delete, role_reorder, user_roles_get, user_roles_set, self_roles_list, self_role_add, self_role_remove, self_roles_reorder
Attachments
Section titled “Attachments”Inspect and delete uploaded files. Uploads use HTTP.
attachment_get, attachment_list, attachment_delete
Manage custom emoji.
emoji_list, emoji_get, emoji_add, emoji_update, emoji_delete
Stickers
Section titled “Stickers”Manage custom stickers.
sticker_list, sticker_get, sticker_add, sticker_update, sticker_delete
Slash commands
Section titled “Slash commands”List, register, call, and answer slash commands.
slash_list, slash_register, slash_call, slash_response
Join voice channels and exchange WebRTC signalling.
voice_join, voice_leave, voice_mute, voice_unmute, voice_state
Reports
Section titled “Reports”Report content and review reports.
report_create, report_list, report_resolve
Audit log
Section titled “Audit log”Read the moderation audit log.
Server administration
Section titled “Server administration”Change server settings and run maintenance.
config_get, config_update, server_update, server_stats, server_maintenance
Webhooks
Section titled “Webhooks”Manage webhooks that post into channels.
webhook_list, webhook_get, webhook_create, webhook_update, webhook_regenerate, webhook_delete
Plugins
Section titled “Plugins”Install and edit server-side JavaScript plugins.
plugin_list, plugin_get, plugin_install, plugin_uninstall, plugin_enable, plugin_disable, plugin_reload, plugin_file_list, plugin_file_get, plugin_file_put
Legacy commands
Section titled “Legacy commands”poll_create and poll_results belong to the legacy Python server, and the OSL server doesn’t handle them. Create polls with a poll embed in message_new, and read results with poll_get. See legacy compatibility.
