Reference: protocol.chat.v1

Services

ChatService

The core of Harmony’s chat operations. Fields

CreateGuild

protocol.chat.v1.CreateGuildRequest -> protocol.chat.v1.CreateGuildResponse

Endpoint to create a guild.


CreateGuildRequest

Request type used in CreateGuild endpoint.

Fields

name

Type: optional string

The name of the guild.

picture

Type: optional string

The picture HMC of the guild.

metadata

Type: optional protocol.harmonytypes.v1.Metadata

Metadata of the guild.


CreateGuildResponse

Used in the CreateGuild endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild that was created.


CreateRoom

protocol.chat.v1.CreateRoomRequest -> protocol.chat.v1.CreateRoomResponse

Endpoint to create a “room” guild.


CreateRoomRequest

Request type used in CreateRoom endpoint.

Fields

name

Type: optional string

The name of the guild.

picture

Type: optional string

The picture HMC of the guild.

metadata

Type: optional protocol.harmonytypes.v1.Metadata

Metadata of the guild.


CreateRoomResponse

Used in the CreateRoom endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild that was created.


CreateDirectMessage

protocol.chat.v1.CreateDirectMessageRequest -> protocol.chat.v1.CreateDirectMessageResponse

Endpoint to create a “direct message” guild.

  • The inviter and the invitee that join the created guild will both be owners.
  • The guild should be created on the server that inviter is on.
  • The server should send a guild invite to the invitee (specified in the request), using the UserInvited postbox event if the invitee is on another server, otherwise see the below item.
  • The server should process this as follows: adding the invite to their pending invite list and sending an InviteReceived event over their event stream if the invitee is on this server.
  • The invitee may or may not use the invite. Only the invitee may use the invite.

CreateDirectMessageRequest

Used in the CreateDirectMessage endpoint.

Fields

user_name

Type: optional string

The user name of the user to DM with.

server_id

Type: optional string

The server ID of the server the user is on.

Should be left unspecified if it’s a user on the homeserver.


CreateDirectMessageResponse

Used in the CreateDirectMessage endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the just created “direct message” guild.


UpgradeRoomToGuild

protocol.chat.v1.UpgradeRoomToGuildRequest -> protocol.chat.v1.UpgradeRoomToGuildResponse

Endpoint to upgrade a “room” guild to a “normal” guild.


UpgradeRoomToGuildRequest

Used in the UpgradeRoomToGuild endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the “room” guild to upgrade to a “normal” guild.


UpgradeRoomToGuildResponse

Used in the UpgradeRoomToGuild endpoint.

This item has no fields.


CreateInvite

protocol.chat.v1.CreateInviteRequest -> protocol.chat.v1.CreateInviteResponse

Endpoint to create an invite.


CreateInviteRequest

Used in the CreateInvite endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild to create an invite in.

name

Type: optional string

The name of the invite.

possible_uses

Type: optional uint32

The possible uses of the invite.

A possible use of 0 means that the invite can be used infinitely many times.


CreateInviteResponse

Used in the CreateInvite endpoint.

Fields

invite_id

Type: optional string

The invite ID of the invite that was created.


CreateChannel

protocol.chat.v1.CreateChannelRequest -> protocol.chat.v1.CreateChannelResponse

Endpoint to create a channel.


CreateChannelRequest

Channel Kinds:

Channel kinds specified in an official Harmony protocol will start with a “h.” prefix. Third-party extensions should not use the “h.” prefix. If no kind is specified, the channel is a text channel.

Kinds indicate additional functionality a channel may have: for example, h.voice can indicate that a channel has voice functionalities alongside the usual text fare.

Used in the CreateChannel endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild to create a channel in.

channel_name

Type: optional string

The name of this channel.

kind

Type: UNHANDLED | TYPE

The kind of this channel.

metadata

Type: optional protocol.harmonytypes.v1.Metadata

The metadata of this channel.

position

Type: optional protocol.harmonytypes.v1.ItemPosition

The position of your new channel in the channel list.

If not specified, it will be put at the bottom of the channel list.


CreateChannelResponse

Used in the CreateChannel endpoint.

Fields

channel_id

Type: optional uint64

ID of the channel that was created.


GetGuildList

protocol.chat.v1.GetGuildListRequest -> protocol.chat.v1.GetGuildListResponse

Endpoint to get your guild list.


GetGuildListRequest

Used in the GetGuildList endpoint.

This item has no fields.


GetGuildListResponse

Used in the GetGuildList endpoint.

Fields

guilds

Type: repeated protocol.chat.v1.GuildListEntry

Guild list returned by the server.


InviteUserToGuild

protocol.chat.v1.InviteUserToGuildRequest -> protocol.chat.v1.InviteUserToGuildResponse

Endpoint to invite a user to a guild.


InviteUserToGuildRequest

Used in InviteUserToGuild endpoint.

Fields

user_name

Type: optional string

User name of the user to invite.

server_id

Type: optional string

Server ID of the user if they are on another server.

guild_id

Type: optional uint64

Guild ID of the guild to invite to.


InviteUserToGuildResponse

Used in InviteUserToGuild endpoint.

This item has no fields.


GetPendingInvites

protocol.chat.v1.GetPendingInvitesRequest -> protocol.chat.v1.GetPendingInvitesResponse

Endpoint to get your pending invites.


GetPendingInvitesRequest

Used in GetPendingInvites endpoint.

This item has no fields.


GetPendingInvitesResponse

Used in GetPendingInvites endpoint.

Fields

pending_invites

Type: repeated protocol.chat.v1.PendingInvite

The pending invite(s).


RejectPendingInvite

protocol.chat.v1.RejectPendingInviteRequest -> protocol.chat.v1.RejectPendingInviteResponse

Endpoint to reject (delete with notification to the inviter) an invite from your pending invite list.

If the invitee is on a different server than the inviter, the invitee’s server should send a UserRejectedInvite postbox event to the inviter’s server.

The “notification” is sending a InviteRejected stream event to the inviter. If the guild’s kind is DirectMessage, the server should also set the rejected field of the guild’s kind to true.


RejectPendingInviteRequest

Used in RejectPendingInvite endpoint.

Fields

invite_id

Type: optional string

Invite ID of the pending invite to reject.

server_id

Type: optional string

Server ID of the pending invite to reject.


RejectPendingInviteResponse

Used in RejectPendingInvite endpoint.

This item has no fields.


IgnorePendingInvite

protocol.chat.v1.IgnorePendingInviteRequest -> protocol.chat.v1.IgnorePendingInviteResponse

Endpoint to ignore (delete without notification to the inviter) an invite from your pending invite list.


IgnorePendingInviteRequest

Used in IgnorePendingInvite endpoint.

Fields

invite_id

Type: optional string

ID of the pending invite to ignore.

server_id

Type: optional string

Server ID of the pending invite to reject.


IgnorePendingInviteResponse

Used in IgnorePendingInvite endpoint.

This item has no fields.


GetGuild

protocol.chat.v1.GetGuildRequest -> protocol.chat.v1.GetGuildResponse

Endpoint to get information about a guild.


GetGuildRequest

Used in the GetGuild endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild to get information about.


GetGuildResponse

Used in the GetGuild endpoint.

Fields

guild

Type: optional protocol.chat.v1.Guild

The information of the guild requested.


GetGuildInvites

protocol.chat.v1.GetGuildInvitesRequest -> protocol.chat.v1.GetGuildInvitesResponse

Endpoint to get the invites of a guild.

This requires the “invites.view” permission.


GetGuildInvitesRequest

Used in the GetGuildInvites endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you want to get invites of.


GetGuildInvitesResponse

Used in the GetGuildInvites endpoint.

Fields

invites

Type: repeated protocol.chat.v1.InviteWithId

The invites of the guild, with IDs.


GetGuildMembers

protocol.chat.v1.GetGuildMembersRequest -> protocol.chat.v1.GetGuildMembersResponse

Endpoint to get the members of a guild.


GetGuildMembersRequest

Used in the GetGuildMembers endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you want to get members of.


GetGuildMembersResponse

Used in the GetGuildMembers endpoint.

Fields

members

Type: repeated uint64

User IDs of all the guild members.


GetGuildChannels

protocol.chat.v1.GetGuildChannelsRequest -> protocol.chat.v1.GetGuildChannelsResponse

Endpoint to get the channels of a guild.

You will only be informed of channels you have the “messages.view” permission for.


GetGuildChannelsRequest

Used in the GetGuildChannels endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you want to get channels from.


GetGuildChannelsResponse

Used in the GetGuildChannels endpoint.

Fields

channels

Type: repeated protocol.chat.v1.ChannelWithId

Channels' data and ID the server responded with.


GetChannelMessages

protocol.chat.v1.GetChannelMessagesRequest -> protocol.chat.v1.GetChannelMessagesResponse

Endpoint to get the messages from a guild channel.


GetChannelMessagesRequest

Used in the GetChannelMessages endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild that has the channel.

channel_id

Type: optional uint64

Channel ID of the channel to get messages from.

message_id

Type: optional uint64

The ID of the message that will be used as an “anchor” point to figure out where to get the messages. If not specified, the direction will be ignored and the newest messages will be returned.

direction

Type: UNHANDLED | TYPE

On which direction to get the messages.

  • By default, it is “before”, which means you will get messages before the message_id message.
  • If it is “around”, you will get the messages around the message_id message. This will include the message_id message itself, as the middle item of the list returned.
  • If it is “after”, you will get the messages after the message_id message.
count

Type: optional uint32

How many messages to get.

  • If 0, a recommended message count to return is 25. If the direction is “around”, the recommended value is 12.
  • If the direction to get the messages is “around”, this count will not be the total count of messages to return, but instead the count of messages to return for each direction, before and after.
  • Servers should enforce their own maximum limit, and clamp this value to the limit.

GetChannelMessagesResponse

Used in the GetChannelMessages endpoint.

Fields

reached_top

Type: optional bool

Has reached the top (first message) of the message history.

reached_bottom

Type: optional bool

Has reached the bottom (last message) of the message history.

messages

Type: repeated protocol.chat.v1.MessageWithId

The messages requested.


GetMessage

protocol.chat.v1.GetMessageRequest -> protocol.chat.v1.GetMessageResponse

Endpoint to get a single message from a guild channel.


GetMessageRequest

Used in the GetMessage endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message you want to get.


GetMessageResponse

Used in the GetMessage endpoint.

Fields

message

Type: optional protocol.chat.v1.Message

The message requested.


UpdateGuildInformation

protocol.chat.v1.UpdateGuildInformationRequest -> protocol.chat.v1.UpdateGuildInformationResponse

Endpoint to update a guild’s information.


UpdateGuildInformationRequest

Used in the UpdateGuildInformation endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you want to update the information of.

new_name

Type: optional string

New name for the guild.

new_picture

Type: optional string

New picture for the guild.

new_metadata

Type: optional protocol.harmonytypes.v1.Metadata

New metadata for the guild.


UpdateGuildInformationResponse

Used in the UpdateGuildInformation endpoint.

This item has no fields.


UpdateChannelInformation

protocol.chat.v1.UpdateChannelInformationRequest -> protocol.chat.v1.UpdateChannelInformationResponse

Endpoint to update a channel’s information.


UpdateChannelInformationRequest

Used in the UpdateChannelInformation endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel you want to change the information of.

new_name

Type: optional string

New name to set for this channel.

new_metadata

Type: optional protocol.harmonytypes.v1.Metadata

New metadata to set for this channel.


UpdateChannelInformationResponse

Used in the UpdateChannelInformation endpoint.

This item has no fields.


UpdateChannelOrder

protocol.chat.v1.UpdateChannelOrderRequest -> protocol.chat.v1.UpdateChannelOrderResponse

Endpoint to change the position of a channel in the channel list.


UpdateChannelOrderRequest

Used in the UpdateChannelOrder endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild that has the channel.

channel_id

Type: optional uint64

Channel ID of the channel that you want to move.

new_position

Type: optional protocol.harmonytypes.v1.ItemPosition

The new position of this channel.


UpdateChannelOrderResponse

Used in the UpdateChannelOrder endpoint.

This item has no fields.


UpdateAllChannelOrder

protocol.chat.v1.UpdateAllChannelOrderRequest -> protocol.chat.v1.UpdateAllChannelOrderResponse

Endpoint to change the position of all channels in the guild; must specifcy all channels or fails


UpdateAllChannelOrderRequest

Request specifiying the order of all channels in a guild at once

Fields

guild_id

Type: optional uint64

guild_id: the guild to specify the new channel order for

channel_ids

Type: repeated uint64

channel_ids: the new order of channel ids


UpdateAllChannelOrderResponse

Used in the UpdateAllChannelOrder endpoint.

This item has no fields.


UpdateMessageText

protocol.chat.v1.UpdateMessageTextRequest -> protocol.chat.v1.UpdateMessageTextResponse

Endpoint to change the text of a message.


UpdateMessageTextRequest

Used in the UpdateMessageText endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message you want to edit the text of.

new_content

Type: optional protocol.chat.v1.FormattedText

New content for this message.


UpdateMessageTextResponse

Used in the UpdateMessageText endpoint.

This item has no fields.


DeleteGuild

protocol.chat.v1.DeleteGuildRequest -> protocol.chat.v1.DeleteGuildResponse

Endpoint to delete a guild. Can only be invoked if there’s one owner.


DeleteGuildRequest

Used in the DeleteGuild endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you want to delete.


DeleteGuildResponse

Used in the DeleteGuild endpoint.

This item has no fields.


DeleteInvite

protocol.chat.v1.DeleteInviteRequest -> protocol.chat.v1.DeleteInviteResponse

Endpoint to delete an invite.


DeleteInviteRequest

Used in the DeleteInvite endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the invite is located.

invite_id

Type: optional string

Invite ID of the invite you want to delete.


DeleteInviteResponse

Used in the DeleteInvite endpoint.

This item has no fields.


DeleteChannel

protocol.chat.v1.DeleteChannelRequest -> protocol.chat.v1.DeleteChannelResponse

Endpoint to delete a channel.


DeleteChannelRequest

Used in the DeleteChannel endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild that has the channel.

channel_id

Type: optional uint64

Channel ID of the channel you want to delete.


DeleteChannelResponse

Used in the DeleteChannel endpoint.

This item has no fields.


DeleteMessage

protocol.chat.v1.DeleteMessageRequest -> protocol.chat.v1.DeleteMessageResponse

Endpoint to delete a message.

This requires the “messages.manage.delete” permission if you are not the message author.


DeleteMessageRequest

Used in the DeleteMessage endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message you want to delete.


DeleteMessageResponse

Used in the DeleteMessage endpoint.

This item has no fields.


JoinGuild

protocol.chat.v1.JoinGuildRequest -> protocol.chat.v1.JoinGuildResponse

Endpoint to join a guild.

  • If the invite used is in a user’s “pending invites” list, it should be removed from there.

JoinGuildRequest

Used in the JoinGuild endpoint.

Fields

invite_id

Type: optional string

Invite ID of the guild you want to join.


JoinGuildResponse

Used in the JoinGuild endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you joined.


LeaveGuild

protocol.chat.v1.LeaveGuildRequest -> protocol.chat.v1.LeaveGuildResponse

Endpoint to leave a guild.

  • If you’re the only owner, you can’t leave a guild. Exception to this rule are “direct message” guilds.
  • When the last member in a “direct message” guild leaves it, that guild should be deleted.

LeaveGuildRequest

Used in the LeaveGuild endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild you want to leave.


LeaveGuildResponse

Used in the LeaveGuild endpoint.

This item has no fields.


TriggerAction

protocol.chat.v1.TriggerActionRequest -> protocol.chat.v1.TriggerActionResponse

Endpont to trigger an action.


TriggerActionRequest

Used in the TriggerAction endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message you want to trigger an action in.

payload

Type: optional protocol.chat.v1.ActionPayload

Payload of action data.


TriggerActionResponse

Used in the TriggerAction endpoint.

This item has no fields.


SendMessage

protocol.chat.v1.SendMessageRequest -> protocol.chat.v1.SendMessageResponse

Endpoint to send a message.


SendMessageRequest

Used in the SendMessage endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel you want to send a message in.

content

Type: optional protocol.chat.v1.Content

Content of the new message.

echo_id

Type: optional uint64

Echo ID of the new message. This can be used by clients to determine whether a message is sent.

overrides

Type: optional protocol.chat.v1.Overrides

The overrides of this new message.

in_reply_to

Type: optional uint64

The message this new message is a reply to.

metadata

Type: optional protocol.harmonytypes.v1.Metadata

The metadata of this new message.


SendMessageResponse

Used in the SendMessage endpoint.

Fields

message_id

Type: optional uint64

Message ID of the message sent.


QueryHasPermission

protocol.chat.v1.QueryHasPermissionRequest -> protocol.chat.v1.QueryHasPermissionResponse

Endpoint to query if a user has a permission.


QueryHasPermissionRequest

Used in the QueryHasPermission endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to query permissions for

channel_id

Type: optional uint64

the channel ID to query permissions for. If not set, it will query permissions for the guild.

as

Type: optional uint64

the user ID to query permissions for (if not provided, the current user is assumed).

check_for

Type: optional string

the permission node to check for.


QueryHasPermissionResponse

Used in the QueryHasPermission endpoint.

Fields

ok

Type: optional bool

the permissions for the given node.


SetPermissions

protocol.chat.v1.SetPermissionsRequest -> protocol.chat.v1.SetPermissionsResponse

Endpoint to set permissions for a role in a guild.


SetPermissionsRequest

Used in the SetPermissions endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to set permissions for.

channel_id

Type: optional uint64

the channel ID to set permissions for. Only set if the role is for a channel.

role_id

Type: optional uint64

the role ID to set permissions for.

perms_to_give

Type: repeated protocol.chat.v1.Permission

the permission list to give.

There is no “perms_to_take” because not given permissions are by default not allowed.


SetPermissionsResponse

Used in the SetPermissions endpoint.

This item has no fields.


GetPermissions

protocol.chat.v1.GetPermissionsRequest -> protocol.chat.v1.GetPermissionsResponse

Endpoint to get permissions for a role in a guild.


GetPermissionsRequest

Used in the GetPermissions endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to get permissions for.

channel_id

Type: optional uint64

the channel ID to get permissions for. Only applicable for roles in a channel.

role_id

Type: optional uint64

the role ID to get permissions for.


GetPermissionsResponse

Used in the GetPermissions endpoint.

Fields

perms

Type: repeated protocol.chat.v1.Permission

the permissions list for the given role.


MoveRole

protocol.chat.v1.MoveRoleRequest -> protocol.chat.v1.MoveRoleResponse

Endpoint to change the position of a role in the role list in a guild.


MoveRoleRequest

Used in the MoveRole endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to move the role in.

role_id

Type: optional uint64

the role ID to move.

new_position

Type: optional protocol.harmonytypes.v1.ItemPosition

the new position of the role.


MoveRoleResponse

Used in the MoveRole endpoint.

This item has no fields.


GetGuildRoles

protocol.chat.v1.GetGuildRolesRequest -> protocol.chat.v1.GetGuildRolesResponse

Endpoint to get the roles from a guild.


GetGuildRolesRequest

Used in the GetGuildRoles endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to get roles for.


GetGuildRolesResponse

Used in the GetGuildRoles endpoint.

Fields

roles

Type: repeated protocol.chat.v1.RoleWithId

the list of roles in the guild.


AddGuildRole

protocol.chat.v1.AddGuildRoleRequest -> protocol.chat.v1.AddGuildRoleResponse

Endpoint to add a role to a guild.


AddGuildRoleRequest

Used in the AddGuildRole endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to add the role to.

name

Type: optional string

the role name.

color

Type: optional int32

the role color.

hoist

Type: optional bool

whether the role is hoisted or not.

pingable

Type: optional bool

whether the role is mentionable or not.


AddGuildRoleResponse

Used in the AddGuildRole endpoint.

Fields

role_id

Type: optional uint64

the ID of the newly created role.


ModifyGuildRole

protocol.chat.v1.ModifyGuildRoleRequest -> protocol.chat.v1.ModifyGuildRoleResponse

Endpoint to a modify a role from a guild.


ModifyGuildRoleRequest

Used in the ModifyGuildRole endpoint.

Fields

guild_id

Type: optional uint64

the ID of the guild where the role is located

role_id

Type: optional uint64

the ID of the role to modify

new_name

Type: optional string

the new name of the role

new_color

Type: optional int32

the new color of the role

new_hoist

Type: optional bool

the new hoist status of the role

new_pingable

Type: optional bool

the new pingable status of the role


ModifyGuildRoleResponse

Used in the ModifyGuildRole endpoint.

This item has no fields.


DeleteGuildRole

protocol.chat.v1.DeleteGuildRoleRequest -> protocol.chat.v1.DeleteGuildRoleResponse

Endpoint to delete a role from a guild.


DeleteGuildRoleRequest

Used in the DeleteGuildRole endpoint.

Fields

guild_id

Type: optional uint64

the guild ID to delete the role from.

role_id

Type: optional uint64

the role ID to delete.


DeleteGuildRoleResponse

Used in the DeleteGuildRole endpoint.

This item has no fields.


ManageUserRoles

protocol.chat.v1.ManageUserRolesRequest -> protocol.chat.v1.ManageUserRolesResponse

Endpoint to manage the roles of a guild member.


ManageUserRolesRequest

Used in the ManageUserRoles endpoint.

Fields

guild_id

Type: optional uint64

the ID of the guild where the user is being managed

user_id

Type: optional uint64

the ID of the user to modify

give_role_ids

Type: repeated uint64

the IDs of the roles to add

take_role_ids

Type: repeated uint64

the IDs of the roles to remove


ManageUserRolesResponse

Used in the ManageUserRoles endpoint.

This item has no fields.


GetUserRoles

protocol.chat.v1.GetUserRolesRequest -> protocol.chat.v1.GetUserRolesResponse

Endpoint to get the roles a guild member has.


GetUserRolesRequest

Used in the GetUserRoles endpoint.

Fields

guild_id

Type: optional uint64

the ID of the guild where the user is located

user_id

Type: optional uint64

the ID of the user to get roles for


GetUserRolesResponse

Used in the GetUserRoles endpoint.

Fields

roles

Type: repeated uint64

a list of IDs of the roles the user has


Typing

protocol.chat.v1.TypingRequest -> protocol.chat.v1.TypingResponse

Endpoint to send a typing notification in a guild channel.


TypingRequest

Used in Typing endpoint.

Fields

guild_id

Type: optional uint64

The guild id of the channel the user is typing in.

channel_id

Type: optional uint64

The channel id of the channel the user is typing in.


TypingResponse

Used in Typing endpoint.

This item has no fields.


PreviewGuild

protocol.chat.v1.PreviewGuildRequest -> protocol.chat.v1.PreviewGuildResponse

Endpoint to “preview” a guild, which returns some information about a guild.

  • Guilds with the “direct message” kind can only be previewed by the user who is invited to the guild.

PreviewGuildRequest

Used in the PreviewGuild endpoint.

Fields

invite_id

Type: optional string

Invite ID of the guild you want to get information from.


PreviewGuildResponse

Used in the PreviewGuild endpoint.

Fields

name

Type: optional string

Name of the guild requested.

picture

Type: optional string

Picture of the guild requested.

member_count

Type: optional uint64

Member count of the guild requested.


GetBannedUsers

protocol.chat.v1.GetBannedUsersRequest -> protocol.chat.v1.GetBannedUsersResponse

Endpoint to get banned users in a guild.


GetBannedUsersRequest

Used in GetBannedUsers endpoint.

Fields

guild_id

Type: optional uint64

Guild ID to get banned users for.


GetBannedUsersResponse

Used in GetBannedUsers endpoint.

Fields

banned_users

Type: repeated uint64

The user IDs of banned users.


BanUser

protocol.chat.v1.BanUserRequest -> protocol.chat.v1.BanUserResponse

Endpoint to ban a user from a guild.


BanUserRequest

Used in BanUser endpoint.

Fields

guild_id

Type: optional uint64

The guild ID of the guild to ban the user from.

user_id

Type: optional uint64

The ID of the user to ban.


BanUserResponse

Used in BanUser endpoint.

This item has no fields.


KickUser

protocol.chat.v1.KickUserRequest -> protocol.chat.v1.KickUserResponse

Endpoint to kick a user from a guild.


KickUserRequest

Used in KickUser endpoint.

Fields

guild_id

Type: optional uint64

The guild ID of the guild to kick the user from.

user_id

Type: optional uint64

The user ID of the user to kick.


KickUserResponse

Used in KickUser endpoint.

This item has no fields.


UnbanUser

protocol.chat.v1.UnbanUserRequest -> protocol.chat.v1.UnbanUserResponse

Endpoint to unban a user from a guild.


UnbanUserRequest

Used in UnbanUser endpoint.

Fields

guild_id

Type: optional uint64

The guild ID of the guild to unban the user from.

user_id

Type: optional uint64

The user ID of the user to unban.


UnbanUserResponse

Used in UnbanUser endpoint.

This item has no fields.


GetPinnedMessages

protocol.chat.v1.GetPinnedMessagesRequest -> protocol.chat.v1.GetPinnedMessagesResponse

Endpoint to get all pinned messages in a guild channel.


GetPinnedMessagesRequest

Used in the GetPinnedMessages endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel we want to get pins of.


GetPinnedMessagesResponse

Used in the GetPinnedMessages endpoint.

Fields

pinned_message_ids

Type: repeated uint64

The IDs of the pinned messages.


PinMessage

protocol.chat.v1.PinMessageRequest -> protocol.chat.v1.PinMessageResponse

Endpoint to pin a message in a guild channel.


PinMessageRequest

Used in the PinMessage endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message we want to pin.


PinMessageResponse

Used in the UnpinMessage endpoint.

This item has no fields.


UnpinMessage

protocol.chat.v1.UnpinMessageRequest -> protocol.chat.v1.UnpinMessageResponse

Endpoint to unpin a message in a guild channel.


UnpinMessageRequest

Used in the UnpinMessage endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message we want to unpin.


UnpinMessageResponse

Used in the UnpinMessage endpoint.

This item has no fields.


StreamEvents

streaming protocol.chat.v1.StreamEventsRequest -> streaming protocol.chat.v1.StreamEventsResponse

Endpoint to stream events from the homeserver. By default, this endpoint will subscribe to all events. Any guilds joined in the future will be added to the subscription as well. Use the UnsubscribeFromAll event for unsubscribing from all current subscriptions and disable the automatic guild subscriptions

StreamEventsResponse

Used in the StreamEvents endpoint.

Fields

chat

Type: optional protocol.chat.v1.StreamEvent

A chat event.

emote

Type: optional protocol.emote.v1.StreamEvent

A emote event.

profile

Type: optional protocol.profile.v1.StreamEvent

A profile event.


AddReaction

protocol.chat.v1.AddReactionRequest -> protocol.chat.v1.AddReactionResponse

Endpoint to add a reaction to a message.


AddReactionRequest

Used in AddReaction endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message we want to add a reaction to.

emote

Type: optional protocol.emote.v1.Emote

The emote we want to react with.


AddReactionResponse

Used in AddReaction endpoint.

This item has no fields.


RemoveReaction

protocol.chat.v1.RemoveReactionRequest -> protocol.chat.v1.RemoveReactionResponse

Endpoint to remove a reaction from a message.


RemoveReactionRequest

Used in RemoveReaction endpoint.

Fields

guild_id

Type: optional uint64

Guild ID of the guild where the channel is.

channel_id

Type: optional uint64

Channel ID of the channel where the message is.

message_id

Type: optional uint64

Message ID of the message we want to remove a reaction.

emote

Type: optional protocol.emote.v1.Emote

The emote we want to remove the react of.


RemoveReactionResponse

Used in RemoveReaction endpoint.

This item has no fields.


GrantOwnership

protocol.chat.v1.GrantOwnershipRequest -> protocol.chat.v1.GrantOwnershipResponse

Endpoint to give ownership to someone else.


GrantOwnershipRequest

Request for GrantOwnership

Fields

guild_id

Type: optional uint64

Guild ID of the guild to give a user ownership on.

new_owner_id

Type: optional uint64

The ID of the new owner to add.


GrantOwnershipResponse

Response for GrantOwnership

This item has no fields.


GiveUpOwnership

protocol.chat.v1.GiveUpOwnershipRequest -> protocol.chat.v1.GiveUpOwnershipResponse

Endpoint to give up your own ownership. Requires that at least one other person will still be owner.


GiveUpOwnershipRequest

Request for GiveUpOwnership

Fields

guild_id

Type: optional uint64

Guild ID to give up your ownership on.


GiveUpOwnershipResponse

Response for GiveUpOwnership

This item has no fields.

Standalone Message Types

Channel

An object representing a channel, without the ID.

Fields

channel_name

Type: optional string

The name of this channel.

kind

Type: UNHANDLED | TYPE

The kind of channel this is. Data does not get inherently stored in the Channel type Instead, clients who understand a certain ChannelKind should fetch them from a separate RPC.

metadata

Type: optional protocol.harmonytypes.v1.Metadata

The metadata of this channel.


ChannelWithId

The channel alongside with an ID.

Fields

channel_id

Type: optional uint64

ID of the channel.

channel

Type: optional protocol.chat.v1.Channel

The channel data.


GuildKind

The kind of a guild.

Fields

normal

Type: optional protocol.chat.v1.GuildKind.Normal

A “normal” guild.

room

Type: optional protocol.chat.v1.GuildKind.Room

A “room” guild.

direct_message

Type: optional protocol.chat.v1.GuildKind.DirectMessage

A “direct message” guild.


GuildKind.Normal

This item has no fields.


GuildKind.Room

This item has no fields.


GuildKind.DirectMessage

Fields

rejected

Type: optional bool


Guild

Object representing a guild without the ID part.

Fields

name

Type: optional string

The name of the guild.

This will be empty if the guild kind is “direct message”. See the documentation of “direct message” guild kind on how to display a name for those guilds.

picture

Type: optional string

The picture HMC of the guild.

owner_ids

Type: repeated uint64

User ID of the owners of the guild.

kind

Type: optional protocol.chat.v1.GuildKind

The kind of this guild.

metadata

Type: optional protocol.harmonytypes.v1.Metadata

Metadata of the guild.


GuildWithId

Object representing a guild with the ID part.

Fields

guild_id

Type: optional uint64

The ID of the guild.

guild

Type: optional protocol.chat.v1.Guild

The guild.


Invite

Object representing an invite without the ID part.

Fields

possible_uses

Type: optional uint32

Possible uses of this invite. A use of 0 means infinite uses.

use_count

Type: optional uint32

Total use count of this invite.


InviteWithId

Invite with ID.

Fields

invite_id

Type: optional string

ID of the invite.

invite

Type: optional protocol.chat.v1.Invite

The invite data.


PendingInvite

A pending invite.

Fields

invite_id

Type: optional string

Invite ID of the invite.

server_id

Type: optional string

Server ID of the server the inviter is on.

inviter_id

Type: optional uint64

User ID of the inviter.


GuildListEntry

Object representing a guild list entry.

Fields

guild_id

Type: optional uint64

Guild ID of this guild entry.

server_id

Type: optional string

Server ID of the homeserver of this guild.


Overrides

Overrides provide a way to override the name and avatar of a message.

Fields

username

Type: optional string

the overridden username.

avatar

Type: optional string

the overridden avatar.

user_defined

Type: optional string

a custom reason in case the builtin ones don’t fit

webhook

Type: optional protocol.harmonytypes.v1.Empty

the override occured because of a webhook

system_plurality

Type: optional protocol.harmonytypes.v1.Empty

plurality, not system as in computer

system_message

Type: optional protocol.harmonytypes.v1.Empty

the override occured because it was made by the server

Servers should reject messages sent by users with this override.

bridge

Type: optional protocol.harmonytypes.v1.Empty

the override occured because of bridging


ActionPayload

The payload sent to the bot when an action is triggered.

Fields

button

Type: optional protocol.chat.v1.ActionPayload.Button

Payload for a button

dropdown

Type: optional protocol.chat.v1.ActionPayload.Dropdown

Payload for a dropdown

input

Type: optional protocol.chat.v1.ActionPayload.Input

Payload for a text input


ActionPayload.Button

Fields

data

Type: optional bytes


ActionPayload.Dropdown

Fields

choice

Type: optional bytes


ActionPayload.Input

Fields

input

Type: optional string

data

Type: optional bytes


Action

Actions are interactive elements that can exist within an embed.

Fields

action_type

Type: UNHANDLED | TYPE

Type of the action.

button

Type: optional protocol.chat.v1.Action.Button

Button action.

dropdown

Type: optional protocol.chat.v1.Action.Dropdown

Dropdown action.

input

Type: optional protocol.chat.v1.Action.Input

Input action.


Action.Button

The action type. This is primarily used to change the look of the action to the user (example: Destructive actions will have a red background).

Fields

text

Type: optional string

a normal action.

data

Type: optional bytes

a primary action.

url

Type: optional string

A destructive / dangerous action.


Action.Dropdown

Fields

label

Type: optional string

entries

Type: repeated protocol.chat.v1.Action.Dropdown.Entry


Action.Dropdown.Entry

Fields

label

Type: optional string

data

Type: optional bytes


Action.Input

Fields

label

Type: optional string

multiline

Type: optional bool

data

Type: optional bytes


Embed

Object representing a message embed.

Fields

title

Type: optional string

Title of this embed.

body

Type: optional protocol.chat.v1.FormattedText

Body text of this embed.

color

Type: optional int32

Color of this embed.

header

Type: optional protocol.chat.v1.Embed.EmbedHeading

Embed heading for the header.

footer

Type: optional protocol.chat.v1.Embed.EmbedHeading

Embed heading for the footer.

fields

Type: repeated protocol.chat.v1.Embed.EmbedField

Fields of this embed.


Embed.EmbedHeading

Fields

text

Type: optional string

subtext

Type: optional string

url

Type: optional string

icon

Type: optional string


Embed.EmbedField

Fields

title

Type: optional string

subtitle

Type: optional string

body

Type: optional protocol.chat.v1.FormattedText

image_url

Type: optional string

presentation

Type: UNHANDLED | TYPE

actions

Type: repeated protocol.chat.v1.Action


Minithumbnail

Minithumbnail is an extremely low-quality JPEG thumbnail.

The resolution is usually no larger than 64x64.

Fields

width

Type: optional uint32

The width of the minithumbnail

height

Type: optional uint32

The height of the minithumbnail

data

Type: optional bytes

The JPEG data of the minithumbnail


Photo

Photo contains data about a photo.

Photo are always JPEG, and are constrained to the following rules:

  • width+height <= 10_000
  • width <= height*20
  • height <= width*20

Photos are preferably no more than 10MB in size, and servers may compress as necessary.

Fields

hmc

Type: optional string

The HMC URL of the photo.

name

Type: optional string

The filename of the photo.

file_size

Type: optional uint32

The size of the photo.

height

Type: optional uint32

The height of the photo, in pixels.

width

Type: optional uint32

The width of the photo, in pixels.

caption

Type: optional protocol.chat.v1.FormattedText

The photo’s caption.

minithumbnail

Type: optional protocol.chat.v1.Minithumbnail

A thumbnail representing the photo.


Attachment

Object representing a generic message attachment.

Fields

id

Type: optional string

File ID of this attachment.

name

Type: optional string

Filename of this attachment.

mimetype

Type: optional string

Mimetype of this attachment.

size

Type: optional uint32

Size of this attachment.

caption

Type: optional protocol.chat.v1.FormattedText

Caption of this attachment.


Content

Object representing a message’s content.

Fields

text_message

Type: optional protocol.chat.v1.Content.TextContent

Text content.

embed_message

Type: optional protocol.chat.v1.Content.EmbedContent

Embed content.

attachment_message

Type: optional protocol.chat.v1.Content.AttachmentContent

Attachment content.

photo_message

Type: optional protocol.chat.v1.Content.PhotoContent

Photo content.

invite_rejected

Type: optional protocol.chat.v1.Content.InviteRejected

A user rejected an invite.

invite_accepted

Type: optional protocol.chat.v1.Content.InviteAccepted

A user accepted an invite.

room_upgraded_to_guild

Type: optional protocol.chat.v1.Content.RoomUpgradedToGuild

A user upgraded a guild from “room” to “normal”.


Content.TextContent

Fields

content

Type: optional protocol.chat.v1.FormattedText


Content.EmbedContent

Fields

embeds

Type: repeated protocol.chat.v1.Embed


Content.AttachmentContent

Fields

files

Type: repeated protocol.chat.v1.Attachment


Content.PhotoContent

Fields

photos

Type: repeated protocol.chat.v1.Photo


Content.InviteRejected

Fields

invitee_id

Type: optional uint64

inviter_id

Type: optional uint64


Content.InviteAccepted

Fields

invitee_id

Type: optional uint64

inviter_id

Type: optional uint64


Content.RoomUpgradedToGuild

Fields

upgraded_by

Type: optional uint64


Reaction

Object representing a reaction.

Fields

emote

Type: optional protocol.emote.v1.Emote

Emote data for this reaction.

Emote’s image ID is used as an identifier for unique reactions. Emotes with the same names should be “deduplicated” by a client, by suffixing their names with ~1, ~2 and so on.

count

Type: optional uint32

How many reactions this reaction has.


Format

A format for text

Fields

start

Type: optional uint32

where the format begins to apply to

length

Type: optional uint32

how many characters the format is

bold

Type: optional protocol.chat.v1.Format.Bold

a text format for bold text

italic

Type: optional protocol.chat.v1.Format.Italic

a text format for italic text

underline

Type: optional protocol.chat.v1.Format.Underline

a text format for underline text

monospace

Type: optional protocol.chat.v1.Format.Monospace

a text format for monospace text

superscript

Type: optional protocol.chat.v1.Format.Superscript

a text format for superscript text

subscript

Type: optional protocol.chat.v1.Format.Subscript

a text format for subscript text

code_block

Type: optional protocol.chat.v1.Format.CodeBlock

a text format for a codeblock

user_mention

Type: optional protocol.chat.v1.Format.UserMention

a text format for a user mention

role_mention

Type: optional protocol.chat.v1.Format.RoleMention

a text format for a role mention

channel_mention

Type: optional protocol.chat.v1.Format.ChannelMention

a text format for a channel mention

guild_mention

Type: optional protocol.chat.v1.Format.GuildMention

a text format for a guild mention

emoji

Type: optional protocol.chat.v1.Format.Emoji

a text format for an emoji

color

Type: optional protocol.chat.v1.Format.Color

a text format for coloured text

localization

Type: optional protocol.chat.v1.Format.Localization

a text format for localization


Format.Bold

This item has no fields.


Format.Italic

This item has no fields.


Format.Underline

This item has no fields.


Format.Monospace

This item has no fields.


Format.Superscript

This item has no fields.


Format.Subscript

This item has no fields.


Format.CodeBlock

Fields

language

Type: optional string


Format.UserMention

Fields

user_id

Type: optional uint64


Format.RoleMention

Fields

role_id

Type: optional uint64


Format.ChannelMention

Fields

channel_id

Type: optional uint64


Format.GuildMention

Fields

guild_id

Type: optional uint64

homeserver

Type: optional string


Format.Emoji

Fields

image_hmc

Type: optional string

pack_id

Type: optional uint64


Format.Color

Fields

kind

Type: UNHANDLED | TYPE


Format.Localization

Fields

i18n_code

Type: optional string


FormattedText

Formatted text

Fields

text

Type: optional string

The textual content of a message

format

Type: repeated protocol.chat.v1.Format

The formats for a message


Message

Object representing a message without the ID part.

Fields

metadata

Type: optional protocol.harmonytypes.v1.Metadata

Metadata of this message.

overrides

Type: optional protocol.chat.v1.Overrides

Overrides of this message.

author_id

Type: optional uint64

User ID of the user who sent this message.

created_at

Type: optional uint64

When this message was created, in miliseconds since unix epoch

edited_at

Type: optional uint64

The most recent time this message was edited, in milliseconds since unix epoch

in_reply_to

Type: optional uint64

The message this message is a reply to.

content

Type: optional protocol.chat.v1.Content

The content of the message.

reactions

Type: repeated protocol.chat.v1.Reaction

The reactions of the message.


MessageWithId

Object representing a message with it’s ID.

Fields

message_id

Type: optional uint64

ID of the message.

message

Type: optional protocol.chat.v1.Message

The message data.


Permission

Object representing a single permission node.

Fields

matches

Type: optional string

the permission matcher. (example: roles.manage)

ok

Type: optional bool

whether the permission is allowed or not.


Role

Object representing a role without the ID.

Fields

name

Type: optional string

the role name.

color

Type: optional int32

the role color.

hoist

Type: optional bool

whether the role is hoisted or not.

pingable

Type: optional bool

whether the role is mentionable or not.


RoleWithId

Object representing a role with it’s ID.

The role ID for the default role in a guild should always be 0.

Fields

role_id

Type: optional uint64

ID of the role.

role

Type: optional protocol.chat.v1.Role

The role data.


StreamEventsRequest

Request type for use in the StreamEvents endpoint. By default, this endpoint will subscribe to all events. Any guilds joined in the future will be added to the subscription as well. Use the UnsubscribeFromAll event for unsubscribing from all current subscriptions and disable the automatic guild subscriptions

Fields

subscribe_to_guild

Type: optional protocol.chat.v1.StreamEventsRequest.SubscribeToGuild

Subscribe to the guild event source.

subscribe_to_actions

Type: optional protocol.chat.v1.StreamEventsRequest.SubscribeToActions

Subscribe to the action event source.

subscribe_to_homeserver_events

Type: optional protocol.chat.v1.StreamEventsRequest.SubscribeToHomeserverEvents

Subscribe to the homeserver event source.

unsubscribe_from_all

Type: optional protocol.chat.v1.StreamEventsRequest.UnsubscribeFromAll

Unsubscribe from all events.


StreamEventsRequest.SubscribeToGuild

Fields

guild_id

Type: optional uint64


StreamEventsRequest.SubscribeToActions

This item has no fields.


StreamEventsRequest.SubscribeToHomeserverEvents

This item has no fields.


StreamEventsRequest.UnsubscribeFromAll

This item has no fields.


StreamEvent

Describes an event.

Fields

guild_added_to_list

Type: optional protocol.chat.v1.StreamEvent.GuildAddedToList

Send the guild added to list event.

guild_removed_from_list

Type: optional protocol.chat.v1.StreamEvent.GuildRemovedFromList

Send the guild removed from list event.

action_performed

Type: optional protocol.chat.v1.StreamEvent.ActionPerformed

Send the action performed event.

sent_message

Type: optional protocol.chat.v1.StreamEvent.MessageSent

Send the message sent event.

edited_message

Type: optional protocol.chat.v1.StreamEvent.MessageUpdated

Send the message updated event.

deleted_message

Type: optional protocol.chat.v1.StreamEvent.MessageDeleted

Send the message deleted event.

created_channel

Type: optional protocol.chat.v1.StreamEvent.ChannelCreated

Send the channel created event.

edited_channel

Type: optional protocol.chat.v1.StreamEvent.ChannelUpdated

Send the channel updated event.

deleted_channel

Type: optional protocol.chat.v1.StreamEvent.ChannelDeleted

Send the channel deleted event.

edited_guild

Type: optional protocol.chat.v1.StreamEvent.GuildUpdated

Send the guild updated event.

deleted_guild

Type: optional protocol.chat.v1.StreamEvent.GuildDeleted

Send the guild deleted event.

joined_member

Type: optional protocol.chat.v1.StreamEvent.MemberJoined

Send the member joined event.

left_member

Type: optional protocol.chat.v1.StreamEvent.MemberLeft

Send the member left event.

typing

Type: optional protocol.chat.v1.StreamEvent.Typing

Send the typing event.

role_created

Type: optional protocol.chat.v1.StreamEvent.RoleCreated

Send the role created event.

role_deleted

Type: optional protocol.chat.v1.StreamEvent.RoleDeleted

Send the role deleted event.

role_moved

Type: optional protocol.chat.v1.StreamEvent.RoleMoved

Send the role moved event.

role_updated

Type: optional protocol.chat.v1.StreamEvent.RoleUpdated

Send the role updated event.

role_perms_updated

Type: optional protocol.chat.v1.StreamEvent.RolePermissionsUpdated

Send the role perms updated event.

user_roles_updated

Type: optional protocol.chat.v1.StreamEvent.UserRolesUpdated

Send the user roles updated event.

permission_updated

Type: optional protocol.chat.v1.StreamEvent.PermissionUpdated

Send the permission updated event.

channels_reordered

Type: optional protocol.chat.v1.StreamEvent.ChannelsReordered

The channels have been completely reordered.

edited_channel_position

Type: optional protocol.chat.v1.StreamEvent.ChannelPositionUpdated

Send the channel position updated event.

message_pinned

Type: optional protocol.chat.v1.StreamEvent.MessagePinned

Send the message pinned event.

message_unpinned

Type: optional protocol.chat.v1.StreamEvent.MessageUnpinned

Send the message unpinned event.

reaction_updated

Type: optional protocol.chat.v1.StreamEvent.ReactionUpdated

Send the reaction updated event.

owner_added

Type: optional protocol.chat.v1.StreamEvent.OwnerAdded

Send the owner added event.

owner_removed

Type: optional protocol.chat.v1.StreamEvent.OwnerRemoved

Send the owner removed event.

invite_received

Type: optional protocol.chat.v1.StreamEvent.InviteReceived

Send the guild invite received event.

invite_rejected

Type: optional protocol.chat.v1.StreamEvent.InviteRejected

Send the guild invite rejected event.


StreamEvent.MessageSent

Fields

echo_id

Type: optional uint64

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64

message

Type: optional protocol.chat.v1.Message


StreamEvent.MessageUpdated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64

edited_at

Type: optional uint64

new_content

Type: optional protocol.chat.v1.FormattedText


StreamEvent.MessageDeleted

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64


StreamEvent.ChannelCreated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

name

Type: optional string

position

Type: optional protocol.harmonytypes.v1.ItemPosition

kind

Type: UNHANDLED | TYPE

metadata

Type: optional protocol.harmonytypes.v1.Metadata


StreamEvent.ChannelUpdated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

new_name

Type: optional string

new_metadata

Type: optional protocol.harmonytypes.v1.Metadata


StreamEvent.ChannelPositionUpdated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

new_position

Type: optional protocol.harmonytypes.v1.ItemPosition


StreamEvent.ChannelsReordered

Fields

guild_id

Type: optional uint64

channel_ids

Type: repeated uint64


StreamEvent.ChannelDeleted

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64


StreamEvent.GuildUpdated

Fields

guild_id

Type: optional uint64

new_name

Type: optional string

new_picture

Type: optional string

new_metadata

Type: optional protocol.harmonytypes.v1.Metadata


StreamEvent.GuildDeleted

Fields

guild_id

Type: optional uint64


StreamEvent.MemberJoined

Fields

member_id

Type: optional uint64

guild_id

Type: optional uint64


StreamEvent.MemberLeft

Fields

member_id

Type: optional uint64

guild_id

Type: optional uint64

leave_reason

Type: UNHANDLED | TYPE


StreamEvent.GuildAddedToList

Fields

guild_id

Type: optional uint64

homeserver

Type: optional string


StreamEvent.GuildRemovedFromList

Fields

guild_id

Type: optional uint64

homeserver

Type: optional string


StreamEvent.ActionPerformed

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64

user_id

Type: optional uint64

payload

Type: optional protocol.chat.v1.ActionPayload


StreamEvent.RoleMoved

Fields

guild_id

Type: optional uint64

role_id

Type: optional uint64

new_position

Type: optional protocol.harmonytypes.v1.ItemPosition


StreamEvent.RoleDeleted

Fields

guild_id

Type: optional uint64

role_id

Type: optional uint64


StreamEvent.RoleCreated

Fields

guild_id

Type: optional uint64

role_id

Type: optional uint64

name

Type: optional string

color

Type: optional int32

hoist

Type: optional bool

pingable

Type: optional bool


StreamEvent.RoleUpdated

Fields

guild_id

Type: optional uint64

role_id

Type: optional uint64

new_name

Type: optional string

new_color

Type: optional int32

new_hoist

Type: optional bool

new_pingable

Type: optional bool


StreamEvent.RolePermissionsUpdated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

role_id

Type: optional uint64

new_perms

Type: repeated protocol.chat.v1.Permission


StreamEvent.UserRolesUpdated

Fields

guild_id

Type: optional uint64

user_id

Type: optional uint64

new_role_ids

Type: repeated uint64


StreamEvent.Typing

Fields

user_id

Type: optional uint64

guild_id

Type: optional uint64

channel_id

Type: optional uint64


StreamEvent.PermissionUpdated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

query

Type: optional string

ok

Type: optional bool


StreamEvent.MessagePinned

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64


StreamEvent.MessageUnpinned

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64


StreamEvent.ReactionUpdated

Fields

guild_id

Type: optional uint64

channel_id

Type: optional uint64

message_id

Type: optional uint64

reaction

Type: optional protocol.chat.v1.Reaction


StreamEvent.OwnerAdded

Fields

user_id

Type: optional uint64


StreamEvent.OwnerRemoved

Fields

user_id

Type: optional uint64


StreamEvent.InviteReceived

Fields

invite_id

Type: optional string

server_id

Type: optional string

inviter_id

Type: optional uint64


StreamEvent.InviteRejected

Fields

guild_id

Type: optional uint64

invite_id

Type: optional string

user_id

Type: optional uint64

Enums

ChannelKind

What kind the channel is.

CHANNEL_KIND_TEXT_UNSPECIFIED

A text channel. Allows you to simply send messages to a group of people.

CHANNEL_KIND_VOICE_MEDIA

A voice channel. Allows you to talk to other people with voice.

CHANNEL_KIND_CATEGORY

A category channel. All channels under this channel down to another category channel belongs to this category channel.


LeaveReason

A reason for why a user has left a guild.

LEAVE_REASON_WILLINGLY_UNSPECIFIED

The user left the guild willingly.

LEAVE_REASON_BANNED

The user was banned from the guild.

LEAVE_REASON_KICKED

The user was kicked from the guild.


Type

TYPE_NORMAL_UNSPECIFIED

TYPE_PRIMARY

TYPE_DESTRUCTIVE


Direction

DIRECTION_BEFORE_UNSPECIFIED

DIRECTION_AROUND

DIRECTION_AFTER


Embed.Presentation

PRESENTATION_DATA_UNSPECIFIED

PRESENTATION_CAPTIONED_IMAGE

PRESENTATION_ROW


Format.Kind

KIND_DIM_UNSPECIFIED

KIND_BRIGHT

KIND_NEGATIVE

KIND_POSITIVE

KIND_INFO

KIND_WARNING