Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
9 changes: 5 additions & 4 deletions scripts/plugin-jsdocs.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,11 @@ const methodsOutput = pluginRegistryClassMethods.map((statement) => {
s => s.type === "ArrowFunctionExpression"
);
if (funcExpr && funcExpr[0]) {
params = funcExpr[0].params.map(param => {
return param.properties.map(prop => {
return prop.key.name;
});
params = funcExpr[0].params.flatMap(param => {
if (param.properties) {
return param.properties.map(prop => prop.key.name);
}
return param.name ? [param.name] : [];
});
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ When sending a message, you can use any of the following to format how you want

`requested_ack`: If set to `true`, the message will be marked as requiring an acknowledgment from the users by displaying a checkmark icon next to the message. Keep in mind that this requires the message priority to be set to _Important_ or _Urgent_.

`persistent_notifications`: Only for _Urgent_ messages. If set to `true` recipients will receive a persistent notification every five minutes until they acknowledge the message.
`persistent_notifications`: Only for _Urgent_ messages. If set to `true` recipients will receive a persistent notification every five minutes until they acknowledge the message. Mutually exclusive with the [`silent`]({{< ref "/integrate/webhooks/incoming#parameters" >}}) field on incoming webhooks — a post cannot be both persistent and silent.

## Example of post priority

Expand Down
2 changes: 1 addition & 1 deletion site/content/integrate/slash-commands/custom/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ Slash command responses support more than just the `text` field. Here is a full
| `type` | Sets the post `type`, mainly for use by plugins.<br/> If not blank, must begin with `custom_`. Passing `attachments` will ignore this field and set the type to `slack_attachment`. | No |
| `extra_responses` | An array of responses used to send more than one post in your response. Each item in this array takes the shape of its own command response, so it can include any of the other parameters listed here, except `goto_location` and `extra_responses` itself. Available from Mattermost v5.6. | No |
| `skip_slack_parsing` | If set to `true` Mattermost will skip the [Slack compatibility]({{< ref "/integrate/slash-commands/slack" >}}) handling. Useful if the post contains text or code which is incorrectly handled by the Slack compatibility logic. Available from Mattermost v5.20. | No |
| `props` | Sets the post `props`, a JSON property bag for storing extra or meta data on the post. Mainly used by other integrations accessing posts through the {{< newtabref title="REST API" href="https://api.mattermost.com" >}}.<br/>The following keys are reserved: `from_webhook`, `override_username`, `override_icon_url` and `attachments`. | No |
| `props` | Sets the post `props`, a JSON property bag for storing extra or meta data on the post. Mainly used by other integrations accessing posts through the {{< newtabref title="REST API" href="https://api.mattermost.com" >}}.<br/>The following keys are reserved and ignored if supplied: `from_webhook`, `from_bot`, `from_oauth_app`, `from_plugin`, `force_notification`, `silent_notification`, `override_username`, `override_icon_url`, `override_icon_emoji`, `webhook_display_name`, `card`, and `attachments`. | No |

An response payload using several parameters could look like this:

Expand Down
3 changes: 2 additions & 1 deletion site/content/integrate/webhooks/incoming/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,9 @@ Incoming webhooks support more than just the `text` field. Here is a full list o
| `icon_emoji` | Overrides the profile picture and `icon_url` parameter.<br/>Defaults to none and is not set during webhook creation.<br/>The expected value is an emoji name as typed in a message, either with or without colons (`:`).<br/>The {{<newtabref title="Enable integrations to override profile picture icons" href="https://docs.mattermost.com/configure/configuration-settings.html#enable-integrations-to-override-profile-picture-icons">}} configuration setting must be enabled for the override to take effect.. | No |
| `attachments` | [Message attachments]({{<ref "/integrate/reference/message-attachments">}}) used for richer formatting options. | If `text` is not set, yes |
| `type` | Sets the post `type`, mainly for use by plugins.<br/>If not blank, must begin with `custom_` unless set to `burn_on_read`. | No |
| `props` | Sets the post `props`, a JSON property bag for storing extra or meta data on the post.<br/>Mainly used by other integrations accessing posts through the REST API.<br/>The following keys are reserved: `from_webhook`, `override_username`, `override_icon_url`, `override_icon_emoji`, `webhook_display_name`, `card`, and `attachments`.<br/>Props `card` allows for extra information (Markdown-formatted text) to be sent to Mattermost that will only be displayed in the RHS panel after a user selects the **info** icon displayed alongside the post.<br/>The **info** icon cannot be customized and is only rendered visible to the user if there is `card` data passed into the message.<br/>This property is available from Mattermost v5.14.<br/>There is currently no Mobile support for `card` functionality. | No |
| `props` | Sets the post `props`, a JSON property bag for storing extra or meta data on the post.<br/>Mainly used by other integrations accessing posts through the REST API.<br/>The following keys are reserved and ignored if supplied: `from_webhook`, `from_bot`, `from_oauth_app`, `from_plugin`, `force_notification`, `silent_notification` (use the top-level `silent` field instead), `override_username`, `override_icon_url`, `override_icon_emoji`, `webhook_display_name`, `card`, and `attachments`.<br/>Props `card` allows for extra information (Markdown-formatted text) to be sent to Mattermost that will only be displayed in the RHS panel after a user selects the **info** icon displayed alongside the post.<br/>The **info** icon cannot be customized and is only rendered visible to the user if there is `card` data passed into the message.<br/>This property is available from Mattermost v5.14.<br/>There is currently no Mobile support for `card` functionality. | No |
| `priority` | Set the priority of the message. See [Message Priority](/integrate/reference/message-priority/) | No |
| `silent` | When `true`, the post is delivered silently: visible in the channel but produces no desktop/push/email notifications, no unread or mention count increments, and no "New Messages" line. Use for routine bot status updates or audit-trail posts. Mutually exclusive with `priority.persistent_notifications`. Defaults to `false`. | No |

An example request using more parameters would look like this:

Expand Down
Loading