| Object | Unique Identifier |
|---|---|
| Version | Not Applicable |
| Scheme | name |
| Role | name |
| Emoji | name |
| Team | name |
| Channel | name, team |
| User | username |
| UserNotifyProps | username |
| UserTeamMembership | team, username |
| UserChannelMembership | team, channel, username |
| Post | channel, message, create_at |
| Reply | post, message, create_at |
| Reaction | post, emoji_name, create_at |
| Attachment | path |
| DirectChannel | members |
| DirectPost | channel_members, user, message, create_at |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| type | string | Must be the string "version" | Yes | Yes |
| version | number | Must be the number 1. | Yes | Yes |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| name | string | The scheme name. Must start with and contain only lowercase letters ([a-z0-9]) or _, and must be between 2-64 characters in length. | Yes | Yes |
| display_name | string | The display name for the scheme. | Yes | Yes |
| scope | string | The scope for the scheme. Must be either "team" or "channel". | Yes | Yes |
| description | string | The description of the scheme. | Yes | No |
| default_team_admin_role | Role object | The default role applied to team admins in teams using this scheme. This field is mandatory if the scheme scope is set to "team", otherwise must not be present. | Yes | No |
| default_team_user_role | Role object | The default role applied to Team Users in teams using this scheme. This field is mandatory if the scheme scope is set to "team", otherwise must not be present. | Yes | No |
| default_channel_admin_role | Role object | The default role applied to channel admins in channels using this scheme. This field is mandatory for both "team" and "channel" scope schemes. | Yes | Yes |
| default_channel_user_role | Role object | The default role applied to Channel Users in channels using this scheme. This field is mandatory for both "team" and "channel" scope schemes. | Yes | Yes |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| name | string | The scheme name. | Yes | Yes |
| display_name | string | The display name for the scheme. | Yes | Yes |
| description | string | The description of the scheme. | Yes | No |
| permissions | array | The permissions the role should grant. This is an array of strings where the strings are the names of individual permissions in the Mattermost permissions system. | Yes | No |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| name | string | The emoji name. | Yes | Yes |
| image | string | The path (either absolute or relative to the current working directory) to the image file for this emoji. | No | Yes |
| [1] Not validated, but an error occurs if no such scheme exists when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| name | string | The team name. | Yes | Yes |
| display_name | string | The display name for the team. | Yes | Yes |
| type | string | The type of team. Can have one the following values: O for an open team I for an invite-only team. |
Yes | Yes |
| description | string | The team description. | Yes | No |
| allow_open_invite | bool | Whether to allow open invitations. Must have one of the following values: true false |
Yes | No |
| scheme | string | The name of the Scheme that should be applied to this team. | No [1] | No |
| [1] Not validated, but an error occurs if no such team/scheme exists when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| team | string | The name of the team this channel belongs to. | No [1] | Yes |
| name | string | The name of the channel. Must start with and contain only lowercase letters ([a-z0-9]) or - or _. | Yes | Yes |
| display_name | string | The display name for the channel. | Yes | yes |
| type | string | The type of channel. Can have one the following values: O for a public channel. P for a private channel. |
Yes | Yes |
| header | string | The channel header. | Yes | No |
| purpose | string | The channel purpose. | Yes | No |
| scheme | string | The name of the Scheme that should be applied to this team. | No [1] | No |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| profile_image | string | The user’s profile image. This must be an existing file path. | Yes | No |
| username | string | The user’s username. This is the unique identifier for the user. | Yes | Yes |
| string | The user’s email address. | Yes | Yes | |
| auth_service | string | The authentication service to use for this user account. If not provided, it defaults to password-based authentication. Must be one of the following values: "" or not provided - password authentication. "gitlab" - GitLab authentication. "ldap" - LDAP authentication (Enterprise and Professional) "saml" - Generic SAML based authentication (Enterprise) "google" - Google OAuth authentication (Enterprise) "office365" - Microsoft Entra ID OAuth Authentication (Enterprise) |
No | No |
| auth_data | string | The authentication data if auth_service is used. The value depends on the auth_service that is specified. The data comes from the following fields for the respective auth_services: "" or not provided - must be omitted. "gitlab" - The value of the Id attribute provided in the GitLab auth data. "ldap" - The value of the LDAP attribute specified as the "ID Attribute" in the Mattermost LDAP configuration. "saml" - The value of the SAML Email address attribute. "google" - The value of the OAuth Id attribute. "office365" - The value of the OAuth Id attribute. |
No | No |
| password | string | A password for the user. Can be present only when password-based authentication is used. When password-based authentication is used and the password is not present, the bulk import command generates a password. | Yes | No |
| nickname | string | The user’s nickname. | Yes | No |
| first_name | string | The user’s first name. | Yes | No |
| last_name | string | The user’s last name. | Yes | No |
| position | string | The user’s position. | Yes | No |
| roles | string | The user’s roles. Must be one of the following values: "system_user" "system_admin system_user" |
Yes | No |
| locale | string | The user’s locale. This must be a valid locale for which Mattermost has been localised. | No | No |
| delete_at | int64 | Timestamp for when the user was deactivated. | No | No |
| teams | array | The teams which the user will be made a member of. Must be an array of UserTeamMembership objects. | Yes | No |
| theme | string | The user’s theme. Formatted as a Mattermost theme string. | No | No |
| military_time | string | How times should be displayed to this user. Must be one of the following values: "true" - Use 24 hour clock. "false" - Use 12 hour clock. |
No | No |
| collapse_previews | string | Whether to collapse or expand link previews by default. Must be one of the following values: "true" - Collapsed by default. "false" - Expanded by default. |
No | No |
| message_display | string | Which style to use for displayed messages. Must be one of the following values: "clean" - Use the standard style. "compact" - Use the compact style. |
No | No |
| channel_display_mode | string | How to display channel messages. Must be one of the following values: "full" - Use the full width of the screen. "centered" - Use a fixed width, centered block. |
No | No |
| tutorial_step | string | Where to start the user tutorial. Must be one of the following values: "1", "2" or "3" - Start from the specified tutorial step. "999" - Skip the user tutorial. |
No | No |
| use_markdown_preview | bool | Enable preview of message markdown formatting. Can have one the following values: "True" "False" |
Yes | Yes |
| use_formatting | bool | Enable post formatting for links, emoji, text styles and line breaks. Can have one the following values: "True" "False" |
Yes | Yes |
| show_unread_section | bool | Enable showing unread messages at top of channel sidebar. Can have one the following values: "True" "False" |
Yes | Yes |
| email_interval | string | Specify an email batching interval during bulk import. Can have one of the following values: "immediately" - Emails are sent immediately. "fifteen" - Emails are batched and sent every 15 minutes. "hour" - Emails are batched and sent every hour. |
Yes | Yes |
| notify_props | UserNotifyProps object | The user’s notify preferences, as defined by the UserNotifyProps object. | Yes | No |
| [1] Not validated, but an error occurs if no such team exists when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| desktop | string | Preference for sending desktop notifications. Must be one of the following values: "all" - For all activity. "mention" - Only for mentions. "none" - Never. |
Yes | No |
| desktop_sound | string | Preference for whether desktop notification sound is played. Must be one of the following values: "true" - Sound is played. "false" - Sound is not played. |
Yes | No |
| string | Preference for email notifications. Must be one of the following values: "true" - Email notifications are sent based on the email_interval setting "false" - Email notifications are not sent. |
No | No | |
| mobile | string | Preference for sending mobile push notifications. Must be one of the following values: "all" - For all activity. "mention" - Only for mentions. "none" - Never. |
Yes | No |
| mobile_push_status | string | Preference for when push notifications are triggered. Must be one of the following values: "online" - When online, away or offline. "away" - When away or offline. "offline" - When offline. |
Yes | No |
| channel | string | Whether @all, @channel and @here trigger mentions. Must be one of the following values: "true" - Mentions are triggered. "false" - Mentions are not triggered. |
Yes | No |
| comments | string | Preference for reply mention notifications. Must be one of the following values: "any" - Trigger notifications on messages in reply threads that the user starts or participates in. "root" - Trigger notifications on messages in threads that the user starts. "never" - Do not trigger notifications on messages in reply threads unless the user is mentioned. |
Yes | No |
| mention_keys | string | Preference for custom non-case sensitive words that trigger mentions. Words must be separated by commas. | No | No |
| [1] Not validated, but an error occurs if no such team exists when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| name | string | The name of the team this user should be a member of. | No [1] | Yes |
| theme | string | The user’s theme for the specified team. Formatted as a Mattermost theme string. | Yes | No |
| roles | string | The roles the user should have within this team. Must be one of the following values: "team_user" "team_admin team_user" |
Yes | No |
| channels | array | The channels within this team that the user should be made a member of. Must be an array of UserChannelMembership objects. | Yes | No |
| [1] Not validated, but an error occurs if the parent channel does not exist when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| name | string | The name of the channel in the parent team that this user should be a member of. | No [1] | Yes |
| roles | string | The roles the user should have within this channel. Must be one of the following values: "channel_user" "channel_user channel_admin" |
Yes | No |
| notify_props | object | The notify preferences for this user in this channel. Must be a ChannelNotifyProps object | Yes | No |
| favorite | boolean | Whether to favorite the channel. Must be one of the following values: "true" - Yes. "false" - No. |
No | No |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| desktop | string | Preference for sending desktop notifications. Must be one of the following values: "default" - Global default. "all" - For all activity. "mention" - Only for mentions. "none" - Never. |
Yes | No |
| mobile | string | Preference for sending mobile notifications. Must be one of the following values: "default" - Global default. "all" - For all activity. "mention" - Only for mentions. "none" - Never. |
Yes | No |
| mark_unread | string | Preference for marking channel as unread. Must be one of the following values: "all" - For all unread messages. "mention" - Only for mentions. |
Yes | No |
| [1] Not validated, but an error occurs if the team does not exist when running in apply mode. [2] Not validated, but an error occurs if the channel does not exist in the corresponding team when running in apply mode. [3] Not validated, but an error occurs if the user does not exist when running in apply mode. |
||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| team | string | The name of the team that this post is in. | No [1] | Yes |
| channel | string | The name of the channel that this post is in. | No [2] | Yes |
| user | string | The username of the user for this post. | No [3] | Yes |
| message | string | The message that the post contains. | Yes | Yes |
| props | object | The props for a post. Contains additional formatting information used by integrations and bot posts. For a more detailed explanation see the message attachments documentation. | Yes | Yes |
| create_at | int | The timestamp for the post, in milliseconds since the Unix epoch. | Yes | Yes |
| flagged_by | array | Must contain a list of members who have flagged the post. | No | No |
| replies | array | The posts in reply to this post. Must be an array of Reply objects. | Yes | No |
| reactions | array | The emoji reactions to this post. Must be an array of Reaction objects. | Yes | No |
| attachments | array | File attachments associated with this post. Must be an array of Attachment objects. | Yes | No |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| user | string | The username of the user for this reply. | No [3] | Yes |
| message | string | The message that the reply contains. | Yes | Yes |
| create_at | int | The timestamp for the reply, in milliseconds since the Unix epoch. | Yes | Yes |
| flagged_by | array | Must contain a list of members who have flagged the post. | No | No |
| reactions | array | The emoji reactions to this post. Must be an array of Reaction objects. | Yes | No |
| attachments | array | The file attachments to this post. Must be an array of Attachment objects. | Yes | No |
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| user | string | The username of the user for this reply. | No [3] | Yes |
| emoji_name | string | The emoji of the reaction. | Yes | Yes |
| create_at | int | The timestamp for the reply, in milliseconds since the Unix epoch. | Yes | Yes |
| [1] Not validated, but an error occurs if the file path is not found or accessible when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| path | string | The path to the file to be attached to the post. | No [1] | Yes |
| [1] Not validated, but an error occurs if one or more of the users don't exist when running in apply mode. | ||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| members | array | Must contain a list of members, with a minimum of two usernames and a maximum of eight usernames. | No [1] | Yes |
| header | string | The channel header. | Yes | No |
| favorited_by | array | Must contain a list of members who have favorited the channel. | No | No |
| [1] Not validated, but an error occurs if no channels contain an identical list when running in apply mode. [2] Not validated, but an error occurs if the user does not exist when running in apply mode. |
||||
| Field name | Type | Description | Validated | Mandatory |
|---|---|---|---|---|
| channel_members | array | Must contain a list of members, with a minimum of two usernames and a maximum of eight usernames. | No [1] | Yes |
| user | string | The username of the user for this post. | No [2] | Yes |
| message | string | The message that the post contains. | Yes | Yes |
| create_at | int | The timestamp for the post, in milliseconds since the Unix epoch. | Yes | Yes |
| flagged_by | array | Must contain a list of members who have flagged the post. | No | No |
| replies | array | The posts in reply to this direct post. Must be an array of Reply objects. | Yes | No |
| reactions | array | The emoji reactions to this direct post. Must be an array of Reaction objects. | Yes | No |
| attachments | array | The attachments to this direct post. Must be an array of Attachment objects. | Yes | No |