aboutsummaryrefslogtreecommitdiffstats
path: root/docs/configuration.md
blob: 081b7ad2aa79f22f43dc52e2bcd9e3a8b5a821c4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# Integration Config

A [Ferdium](https://ferdium.org) recipe is a node module. In order to learn more about node modules and their configuration check the official [Node.js documentation](https://nodejs.org/api/modules.html) / [npm package.json documentation](https://docs.npmjs.com/files/package.json).

## Table of Contents

- [Integration Config](#integration-config)
  - [Table of Contents](#table-of-contents)
  - [Config flags](#config-flags)
  - [Example](#example)

## Config flags

`string` **id** _mandatory_<br />
Unique identifier name of the plugin. The name of the plugin folder has to be the same.

This ID cannot contain any special characters or spaces.

`string` **name** _mandatory_<br />
Display name of the service.

`string` **version** _mandatory_<br />
Version number. Will be used for auto updating the integrations. The version number must be in a semver compatible format: eg `1.0.0`.
**important:** the version will be used to figure out if a new recipe update should be deployed to the user. If you make changes to a recipe, **always** increase the version number or Ferdium won't update your recipe.

`string` **license**<br />
The license of the integration. We prefer MIT, but here is a list of all the available SPDX licenses http://spdx.org/licenses/

`string` **repository**<br />
Link to your Github, Gitlab or Bitbucket public repository. Not used in the application, but is very helpful if we need to log bugs or update to newer versions, etc.

`array[string]` **aliases**<br />
The list of alternate names that this recipe can be called

`object` **config** _mandatory_<br />
This is the Ferdium-specific integration config.

* `string` **serviceURL**<br/>
Defines the URL that should be loaded into the Ferdium webview.
<br /><br />
If you want to load a simple URL like `https://www.messenger.com`, you can simply define it via the `serviceURL` parameter. If your service URL is team based, e.g. Slack you can use `https://{teamId}.slack.com`.
<br /><br />
If your service works with custom URLs, just leave this empty.
<br /><br />
**Examples**

```json
{
    "serviceURL": "https://www.messenger.com"
}
```

<br />

```json
{
    "serviceURL": "https://{teamId}.slack.com"
}
```

* `boolean` **hasTeamId** _default: false_<br />
Is this a team based service? If true, the interface to add the service will require a team identifier. e.g. `[teamId]`.slack.com
* `string` **urlInputPrefix**<br />
This option is only used in combination with `hasTeamId: true` in order to display the value of `urlInputPrefix` before the input for TeamId to make it obvious to the user what input is required from them. Eg. _&lt;TeamID&gt;.slack.com_
* `string` **urlInputSuffix**<br />
This option is only used in combination with `hasTeamId: true` in order to display the value of `urlInputSuffix` after the input for TeamId to make it obvious to the user what input is required from them. Eg. _&lt;TeamID&gt;.slack.com_
* `boolean` **hasHostedOption** _default: false_<br />
If a service can be hosted and has a teamId or customUrl
* `boolean` **hasCustomUrl** _default: false_<br />
On-premise services like Mattermost, ... require a custom URL. This option enables the user to enter a custom URL when adding the service.
* `boolean` **hasNotificationSound** _default: false_<br />
Some services provide their own notification sound. In order to avoid multiple sounds when the user receives a message set this to `true`. If the service has no built in notification sound set this to `false`.
* `boolean` **hasDirectMessages** _default: true_<br />
Some services have direct 1x1 messages e.g. a mention or message to every user in a channel (@channel). If this flag is set to `true`, the user can enable/disable if there should be a badge for direct messages.
* `boolean` **hasIndirectMessages** _default: false_<br />
Services like Slack have direct messages e.g. a mention or message to every user in a channel (@channel) and indirect messages e.g. general discussion in a channel. If this flag is set to `true`, the user can enable/disable if there should be a badge for indirect messages.
* `string` **message**<br />
Info message that will be displayed in the add/edit service preferences screen.
* `boolean` **disablewebsecurity** _default: false_<br />
Some services like hangoutschat need the web security disabled.
* `boolean` **allowFavoritesDelineationInUnreadCount** _default: false_<br />
Services like Outlook differentiate between favorites vs other folders. Setting this to `true` will allow the exclusion of the message counts from those non-favorite folders.

## Example

The [mattermost configuration](https://github.com/ferdium/ferdium-recipes/blob/master/recipes/mattermost/package.json) is a typical example.