megaphone icon We're improving your developer experience.
Edit on GitHub

Apps structure

Apps consist of three kinds of assets:

  • manifest.json file

  • Call handlers, starting with /bindings (see Bindings) and /on_install (see Manifest). Call handlers are typically source files in a programming language like JavaScript, Python, or Go.

  • Static assets, currently solely icon files

Interactivity: Bindings and forms 

  • To interact with users an App must bind a call to a location in the Mattermost user interface. These locations may be /-commands, toolbar and menu items, and embedded in posts.

  • A binding may display a Form, or it may invoke a Call that will return a Form. Forms allow to gather fields with limited dynamic behavior (dynamically-populated selects, form refresh on field changes). A Form invokes a Call when it is submitted. A /-command is just another way of filling out a Form and submitting it.

Use Mattermost APIs 

Apps can use all general Mattermost REST APIs, as well as special services that are provided to the apps.

See Authenticating with Mattermost for how to authenticate to all these services.

App services:

  • KV Store - store and retrive app-specific data.

  • OAuth2 Store - store, expand, and retrieve user and app OAuth2 configuration data.

  • Calling other Apps - use the Call API to invoke other apps (experimental).


  • Subscriptions covers how to subscribe to notifications abdout Mattermost events. Examples of a subscription include having your App notified whenever a message is posted in a channel that mentions your @bot account.

  • External webhooks covers subscribing to webhooks from third-party systems.

  • Lifecycle covers lifecycle callback API, i. e. on_install. This is useful for calling your app when it is first installed, or the user is attempting to uninstall it and gives you a chance to initialize or clean up data (such as from the KV store) before uninstalling your app.