Skip to content
This repository was archived by the owner on Jun 29, 2023. It is now read-only.

Fix few docs tickets #448

Closed
wants to merge 23 commits into from
Closed
Changes from 12 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
186 changes: 184 additions & 2 deletions v4/source/introduction.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -214,23 +214,205 @@ tags:

The list of Mattermost WebSocket events are:
- added_to_team
```
{
'event': 'added_to_team',
'seq': '<seq_id>'
'data': {
'team_id': '<team_id>',
'user_id': '<user_id>'
},
'broadcast': {
'omit_users': null,
'user_id': '<user_id>',
'channel_id': '<channel_id>',
'team_id': '<team_id>'
}
}
```
- authentication_challenge
- channel_converted
- channel_created
```
{
'event': 'channel_created',
'seq' : '<seq_id>',
'data' : {
'channel_id': '<channel_id>',
'team_id' : '<team_id>'
},
'broadcast': {
'omit_users': null,
'channel_id': '<channel_id>',
'team_id': '<team_id>',
'user_id': '<user_id>'
}
}
```
- channel_deleted
- channel_member_updated
```
{
'event': 'channel_deleted',
'seq': '<seq_id>'
'data': {
'channel_id': '<channel_id>'
},
'broadcast': {
'omit_users': null,
'user_id': '<user_id>',
'channel_id': '<channel_id>',
'team_id': '<team_id>'
},

```
- channel_updated
```
{
'event': 'channel_updated',
'seq': '<seq_id>'
'data': {
'channel': {
'id': '<channel_id>',
'create_at': '<timestamp>',
'update_at': '<timestamp>',
'delete_at': '<timestamp>',
'team_id': '<team_id>',
'type': 'O',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be 'P', 'D' or 'G' as well

'display_name':'<channel_id>',
'name': '<channel_name>',
'header': 'header',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be a blank string right?

'purpose': '',
'last_post_at': '<timestamp>',
'total_msg_count': '<total_msg_count>',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There shouldn't be quotes here as this is a number. Same with the timestamp fields

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a lot of other cases throughout the changes with this issue

'extra_update_at': '<timestamp>',
'creator_id': '<basic_user_id>'
},
'broadcast': {
'omit_users': null,
'user_id': '',
'channel_id': '<channel_id>',
'team_id': '<team_id>'
},
}
```
- channel_viewed
```
{
'event': 'channel_viewed',
'seq': '<seq_id>'
'data': {
'channel_id': '<channel_id>'
},
'broadcast': {
'omit_users': null,
'user_id': '<user_id>',
'channel_id': '<channel_id>',
'team_id': '<team_id>'
}
}
```
- config_changed
```
{
'event': 'config_changed',
'data': {
'config': {
'EnableCustomEmoji': '<true/false>',
'EnableLinkPreviews': '<true/false>'
}
}
}
```
- delete_team
```
{
'teamname': '<team_name>',
'teamid': '<team_id>',
'state': '<success/error>'
}
```
- direct_added
```
{
'event': '<direct_added>',
'seq': '<seq_id>'
'data': {
'teammate_id': '<teammate_id>'
},
'broadcast': {
'omit_users': null,
'user_id': '<user_id>',
'channel_id': '<channel.id>',
'team_id': '<team_id>'
}
}
```
- emoji_added
```
{
'event': 'emoji_added',
'seq': '<seq_id>'
'data': {
'emoji': {
'id': '<id>',
'create_at': '<timestamp>',
'update_at': '<timestamp>',
'delete_at': '<timestamp>',
'creator_id': '<creator_id>',
'name': 'name'
}
},
'broadcast': {
'omit_users': null,
'user_id': '',
'channel_id': '',
'team_id': ''
}
}
```
- ephemeral_message
```
{
'message': '<message>'
}
```
- group_added
- hello
```
{
'message': '<message>'
}
```
- leave_team
```
{
'event': 'leave_team',
'seq': '<seq_id>'
'data': {
'team_id': '<team_id>',
'user_id': '<user_id>'
},
'broadcast': {
'omit_users': null,
'user_id': '<user_id>',
'channel_id': '<channel_id>',
'team_id': '<team_id>'
}
}
```
- license_changed
```
{
'type': 'GeneralTypes.CLIENT_LICENSE_RECEIVED',
'data': 'msg.data.license'
}
```
- memberrole_updated
```
{
'type': 'TeamTypes.RECEIVED_MY_TEAM_MEMBER',
'data': 'msg.data.member',
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one should have a seq_id and broadcast right?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

```
- new_user
- plugin_disabled
- plugin_enabled
Expand Down