Channels API
Further chat apps a workspace may connect, from its country pack.
The same operations are in the interactive API reference, and the whole contract is in the OpenAPI document.
GET/v1/channels/catalogue
Chat apps you can connect
The chat apps your country's pack names, in order, and whether each can be connected: it needs a connection built for it and its business terms checked within the year. Needs channels:read.
Scope channels:read. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |
GET/v1/channels
Connected chat apps
The accounts connected for the apps in the catalogue. Needs channels:read.
Scope channels:read. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |
POST/v1/channels
Connect a chat app
Checks the app is offered and its terms are fresh, checks the details with the app, seals the secrets and points the app's messages at AirFone. An admin only. Needs channels:write.
Scope channels:write. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |
POST/v1/channels/{id}/disconnect
Disconnect a chat app
Stops the app sending messages here. History stays. An admin only. Needs channels:write.
Scope channels:write. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | The resource id. |
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |
POST/v1/channels/{id}/messages
Send a message on a chat app
Queues a message. Before it goes, the sender checks that the person has not unsubscribed. Needs channels:write.
Scope channels:write. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | The resource id. |
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |
GET/v1/channels/sessions
Personal accounts of chat apps
For each app the pack names, whether a person's own account on it may be connected, and why not when it may not. It is off until the pack records, with a date and a source, that the app's terms allow software to use such an account, an adapter exists and the owner accepts the risk. Needs channels:read.
Scope channels:read. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |
POST/v1/channels/{id}/sign-in
Sign a personal account in
Passes on the code or password the app asked for. The account is active once nothing more is asked. Needs the right to change settings.
Scope channels:write. Accepts: API key or personal access token. Open in the API reference
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | The id. |
AirFone-Version | header | string | No | The API version to use, as a date. Defaults to the version the account was pinned to. |