Skip to main content

ClientMessage

The primary message type sent from client to server. Contains a request ID and one of 80 possible RPC methods.

Protocol Definition

message ClientMessage {
  uint32 id = 1;
  oneof message {
    auth.SignIn auth_sign_in = 2;
    auth.SignUp auth_sign_up = 3;
    messages.SendMessage messages_send_message = 4;
    messages.GetHistory messages_get_history = 5;
    communities.CreateCommunity communities_create_community = 6;
    communities.GetCommunities communities_get_communities = 7;
    communities.CreateChannel communities_create_channel = 8;
    communities.GetChannels communities_get_channels = 9;
    friends.GetRelationships friends_get_relationships = 10;
    chats.GetChats chats_get_chats = 11;
    media.UploadFilePart media_upload_file_part = 12;
    media.DownloadFilePart media_download_file_part = 13;
    chats.CreateChatInvite chats_create_chat_invite = 14;
    auth.LookupInvite auth_lookup_invite = 15;
    auth.UseInvite auth_use_invite = 16;
    messages.DeleteMessage messages_delete_message = 17;
    communities.GetChannelMembers communities_get_channel_members = 18;
    Initialize core_initialize = 19;
    auth.Authorize auth_authorize = 20;
    chats.MarkChatRead chats_mark_chat_read = 21;
    settings.EditProfilePhoto settings_edit_profile_photo = 22;
    communities.EditPhoto communities_edit_photo = 23;
    communities.DeleteChannel communities_delete_channel = 24;
    chats.GetChat chats_get_chat = 25;
    messages.EditMessage messages_edit_message = 26;
    communities.GetRoles communities_get_roles = 27;
    chats.SetTyping chats_set_typing = 28;
    communities.CreateRole communities_create_role = 29;
    communities.EditRole communities_edit_role = 30;
    communities.DeleteRole communities_delete_role = 31;
    communities.EditMember communities_edit_member = 32;
    communities.CreateChannelOverride communities_create_channel_override = 33;
    communities.DeleteChannelOverride communities_delete_channel_override = 34;
    communities.GetChannelOverrides communities_get_channel_overrides = 35;
    communities.LeaveCommunity communities_leave_community = 36;
    communities.DeleteCommunity communities_delete_community = 37;
    friends.SyncFriends friends_sync_friends = 38;
    communities.EditChannel communities_edit_channel = 39;
    communities.EditCommunity communities_edit_community = 40;
    auth.GetSessions auth_get_sessions = 41;
    auth.RevokeSessions auth_revoke_sessions = 42;
    settings.RegisterPushSubscription settings_register_push_subscription = 43;
    settings.UnregisterPushSubscription settings_unregister_push_subscription = 44;
    auth.ResetPassword auth_reset_password = 45;
    auth.VerifyEmail auth_verify_email = 46;
    auth.ResendEmailVerification auth_resend_email_verification = 47;
    users.LookupUsername users_lookup_username = 48;
    communities.RemoveMembers communities_remove_members = 49;
    chats.CreateChat chats_create_chat = 50;
    friends.ChangeRelationship friends_change_relationship = 51;
    chats.UpdateChat chats_update_chat = 52;
    chats.RemoveChatMember chats_remove_chat_member = 53;
    voice.RequestRoom voice_request_room = 54;
    messages.Search messages_search = 55;
    messages.GetEmbedPreview messages_get_embed_preview = 56;
    users.GetProfile users_get_profile = 57;
    communities.EditDefaultPermissions communities_edit_default_permissions = 58;
    chats.DeleteChatInvite chats_delete_chat_invite = 59;
    communities.GetRemovedMembers communities_get_removed_members = 60;
    chats.ListChatInvites chats_list_chat_invites = 61;
    messages.ReportMessage messages_report_message = 62;
    reactions.AddReaction reactions_add_reaction = 63;
    reactions.RemoveReaction reactions_remove_reaction = 64;
    messages.ForwardMessage messages_forward_message = 65;
    stickers.GetSavedStickers stickers_get_saved_stickers = 66;
    stickers.GetStickerFiles stickers_get_sticker_files = 67;
    stickers.GetStickerPack stickers_get_sticker_pack = 68;
    stickers.AddStickerToPack stickers_add_sticker_to_pack = 69;
    stickers.RemoveStickerFromPack stickers_remove_sticker_from_pack = 70;
    billing.RequestPaymentLink billing_request_payment_link = 71;
    billing.CancelSubscription billing_cancel_subscription = 72;
    settings.ChangeNotificationPreferences settings_change_notification_preferences = 73;
    settings.EditProfile settings_edit_profile = 74;
    settings.GetAccount settings_get_account = 75;
    settings.ChangePassword settings_change_password = 76;
    settings.ChangeEmail settings_change_email = 77;
    communities.UnbanMembers communities_unban_members = 78;
    communities.GetMembers communities_get_members = 79;
    settings.ChangeStatus settings_change_status = 80;
    communities.EditSettings communities_edit_settings = 81;
  }
}

ServerMessage

The primary message type sent from server to client. Contains either an update or an RPC result.
id
uint32
Message sequence number
message
oneof
The message payload. Exactly one of the following:
update
tangle.client.updates.Update
A server-initiated update (e.g., new message, user status change)
result
RPCResult
Response to a client RPC request

Protocol Definition

message ServerMessage {
  uint32 id = 1;
  oneof message {
    tangle.client.updates.Update update = 2;
    RPCResult result = 3;
  }
}

RPCResult

Contains the result of an RPC request, either success data or an error.
req_id
uint32
The request ID from the corresponding ClientMessage
result
oneof
The RPC result. Exactly one of the following:
error
RPCError
Error information if the request failed
sent_message
messages.SentMessage
Result of sending a message
authorization
auth.Authorization
Result of authentication
communities
communities.Communities
List of communities
channels
communities.Channels
List of channels
messages
messages.Messages
List of messages
relationships
friends.Relationships
List of friend relationships
chats
chats.Chats
List of chats
file_part
media.FilePart
A chunk of file data
created_invite
auth.CreatedInvite
Details of created invite
member_list
communities.MemberList
List of community members
initialized
Initialized
Connection initialization result
chat
chats.Chat
Chat details
community_roles
communities.CommunityRoles
List of community roles
channel_override
communities.ChannelOverride
Channel permission override
channel_overrides
communities.ChannelOverrides
List of channel permission overrides
sessions
auth.Sessions
List of active sessions
user_details
users.UserDetails
Detailed user information
removed_members
communities.RemovedMembers
List of removed/banned members
group
types.Group
Group chat details
invite_preview
auth.InvitePreview
Invite preview information
room_info
voice.RoomInfo
Voice room information
media_embed
media.MediaEmbed
Media embed preview data
profile
users.Profile
User profile
invite_list
auth.InviteList
List of invites
saved_stickers
stickers.SavedStickers
Saved sticker packs
files
media.Files
File metadata
sticker_pack
stickers.StickerPack
Sticker pack details
Payment link for billing
account
settings.Account
Account settings and information
members
communities.Members
Community members list
community_settings
communities.CommunitySettings
Community settings

Protocol Definition

message RPCResult {
  uint32 req_id = 1;
  oneof result {
    RPCError error = 2;
    messages.SentMessage sent_message = 3;
    auth.Authorization authorization = 4;
    communities.Communities communities = 5;
    communities.Channels channels = 6;
    messages.Messages messages = 7;
    friends.Relationships relationships = 8;
    chats.Chats chats = 9;
    media.FilePart file_part = 10;
    auth.CreatedInvite created_invite = 11;
    communities.MemberList member_list = 13;
    Initialized initialized = 14;
    chats.Chat chat = 15;
    communities.CommunityRoles community_roles = 16;
    communities.ChannelOverride channel_override = 17;
    communities.ChannelOverrides channel_overrides = 18;
    auth.Sessions sessions = 19;
    users.UserDetails user_details = 20;
    communities.RemovedMembers removed_members = 21;
    types.Group group = 22;
    auth.InvitePreview invite_preview = 23;
    voice.RoomInfo room_info = 24;
    media.MediaEmbed media_embed = 25;
    users.Profile profile = 26;
    auth.InviteList invite_list = 27;
    stickers.SavedStickers saved_stickers = 28;
    media.Files files = 29;
    stickers.StickerPack sticker_pack = 30;
    billing.PaymentLink payment_link = 31;
    settings.Account account = 32;
    communities.Members members = 33;
    communities.CommunitySettings community_settings = 34;
  }
  reserved 12;
}

RPCError

Contains error information when an RPC request fails.
error_code
uint32
Numeric error code
error_message
string
Human-readable error description

Protocol Definition

message RPCError {
  uint32 error_code = 1;
  string error_message = 2;
}

Initialize

Initialization request sent as the first message after connecting.

Protocol Definition

message Initialize {
  uint32 client_id = 1;
  string device_type = 2;
  string device_version = 3;
  string app_version = 4;
  bool no_subscribe = 5;
}

Initialized

Response to Initialize request containing connection configuration.
entrypoints
Entrypoints
Available server entrypoints for connection
vapid_public_key
string
VAPID public key for push notifications

Protocol Definition

message Initialized {
  Entrypoints entrypoints = 1;
  optional string vapid_public_key = 2;
}

message Entrypoints {
  repeated types.Entrypoint entrypoints = 1;
}

Build docs developers (and LLMs) love