# Your notifications

> Kontiga is document fraud detection by Bynn Intelligence for insurers, letting agents, lenders and HR screening teams: every document is compared with a proprietary library of more than 300 million original documents, gathered over 20 years.

Documentation index: https://kontiga.com/llms.txt

Section: Reference. URL: https://kontiga.com/docs/notifications

Your own notifications in a workspace: for each kind of event that concerns you, which channels it goes to (in the console, browser push, email, team chat or your own webhook), when email comes, and your quiet hours. Each call acts only on the member whose session or key makes it; no one changes another member's notifications. The workspace's team alerts are separate, in the workspace settings.

Updated November 29, 2026

## Your settings

One row for each kind of event, one column for each channel, and each cell on or off. A kind of a product your workspace does not use is not offered, and nothing of it is sent. The `kind` names always say case, whatever your team calls a case. The team's alerts are in [workspace settings](https://kontiga.com/docs/settings#alerts-and-notices).

The kinds of event

| Kind | Tells you | On at the start | Offered with |
| --- | --- | --- | --- |
| `case_assigned` | A case is assigned to you | In the console, Browser push, Email | Document collection or Identity verification |
| `case_ready` | A case of yours is ready for a decision | In the console | Document collection or Identity verification |
| `case_near_due` | A case of yours is near its due time | In the console | Document collection or Identity verification |
| `case_overdue` | A case of yours is overdue | In the console | Document collection or Identity verification |
| `case_escalated` | A case is escalated to you | In the console | Document collection or Identity verification |
| `decision_returned` | Your decision is approved or sent back | In the console | Document collection or Identity verification |
| `report_ready` | A case report you asked for is ready | In the console | Document collection or Identity verification |
| `task_assigned` | A task is given to you | In the console | Document collection or Identity verification |
| `task_due` | A task of yours is due today | In the console | Document collection or Identity verification |
| `mentioned` | Someone mentions you in a note | In the console | Document collection or Identity verification |
| `party_answered` | A party sent what was asked | In the console | Document collection |
| `party_undelivered` | A message to a party was not delivered | In the console | Document collection |
| `request_expired` | A request on your case expired | In the console | Document collection |
| `document_high_risk` | A document on your case is High risk | In the console | Document fraud detection |
| `document_failed` | A document on your case could not be checked | In the console | Document fraud detection or Document collection |
| `screening_match` | A screening on your case found a possible match | In the console | Identity verification |
| `identity_cluster_detected` | An identity cluster reaches your case | In the console | Document fraud detection or Document collection or Identity verification |
| `lookout_alert_created` | Lookout sends a heads-up | In the console | Document fraud detection or Document collection or Identity verification |
| `lookout_alert_updated` | A heads-up is given to you or changes | In the console | Document fraud detection or Document collection or Identity verification |
| `approval_waiting` | A decision waits for your approval | In the console | Document collection or Identity verification |
| `workflow_waiting` | A workflow waits for your approval | In the console | Document collection |
| `kompis_approval` | A Kompis needs your approval | In the console | Document collection |
| `kompis_paused` | A Kompis has paused | In the console | Document collection |
| `payment_failed` | A payment failed | In the console, Email | Every workspace, for owners, admins and billing |
| `credit_low` | Credit is running low | In the console | Every workspace, for owners, admins and billing |
| `plan_used_up` | The plan's included documents are used up | In the console | Every workspace, for owners, admins and billing |

The channels

| Channel | Sends | Needs first |
| --- | --- | --- |
| `console`, In the console | A short note while you work in the console, and a line in the bell. | Nothing. |
| `push`, Browser push | A notification from your browser, also when the console is not open. | Turn it on in each browser you use. |
| `email`, Email | An email to your account's address, at once or once a day. | Your account's email address. |
| `slack`, Team chat | A direct message in the workspace's team chat. | The workspace connects its team chat, then you link your own account. |
| `teams`, Team chat | A direct message in the workspace's team chat. | The workspace connects its team chat, then you link your own account. |
| `webhook`, Webhook | A signed POST to your own https address. | Your own https address. |

- A channel that is not set up yet keeps your choice, and starts once it is.
- Email goes to your account's address only, at once or as one summary a day at 08:00 in your time zone. Its cells are the same settings as your [email notices](https://kontiga.com/docs/account#email-notices).
- In quiet hours, Browser push, Email and Team chat stay silent, in your own time zone. The console and your webhook carry on, and the bell keeps everything.
- Events of test mode are never pushed.

**Your notification settings**
- `kinds` (array): Every kind your role gets, in the order above, with `channels`: each channel on or off.
- `channels` (object): Each channel's state: `ready`, and `needs`, what it needs first in plain words, while it is not. `detail` says what it is set up with.
- `email` (object): `address`, your account's, and `timing`: `at_once` or `daily`.
- `quiet_hours` (object): `on`, `from` and `to` as `HH:MM`, in `time_zone`, yours.
- `updated_at` (string): When you last changed them. `null` while they are as they started.

## Read your notification settings

For each kind of event that concerns you, which channels it goes to: in the console, browser push, email, Slack, Microsoft Teams or your webhook. With what each channel still needs, your email timing and your quiet hours.

`GET /v1/me/notification_preferences`. Who may: Every member, for themselves. CLI: `kontiga notifications get`. MCP tool: `get_my_notification_settings`.

**Parameters**

**Returns** notification preferences: Every kind of event with its channels, each channel's setup, the email timing and the quiet hours.

API:

```bash
curl -X GET https://api.kontiga.com/v1/me/notification_preferences \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga notifications get
```

MCP tool `get_my_notification_settings`:

```json
{
  "name": "get_my_notification_settings",
  "arguments": {}
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.notificationPreferences.get();
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.notification_preferences.get()
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.NotificationPreferences.Get(ctx)
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.notificationPreferences().get();
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.NotificationPreferences.GetAsync();
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->notificationPreferences->get();
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.notification_preferences.get
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .notification_preferences()
    .get()
    .await?;
```

Response, 200 OK:

```json
{
  "kinds": [
    {
      "kind": "case_assigned",
      "group": "my_cases",
      "label": "A case is assigned to you",
      "channels": {
        "console": true,
        "push": true,
        "email": true,
        "slack": false,
        "teams": false,
        "webhook": false
      }
    },
    {
      "kind": "mentioned",
      "group": "mentions",
      "label": "Someone mentions you in a note",
      "channels": {
        "console": true,
        "push": false,
        "email": true,
        "slack": false,
        "teams": false,
        "webhook": false
      }
    },
    {
      "kind": "document_high_risk",
      "group": "documents",
      "label": "A document on your case is High risk",
      "channels": {
        "console": true,
        "push": false,
        "email": false,
        "slack": false,
        "teams": false,
        "webhook": false
      }
    }
  ],
  "channels": {
    "console": {
      "ready": true,
      "needs": null,
      "detail": null
    },
    "push": {
      "ready": true,
      "needs": null,
      "detail": "1 browser"
    },
    "email": {
      "ready": true,
      "needs": null,
      "detail": "erik.haugen@halden.example"
    },
    "slack": {
      "ready": false,
      "needs": "Link your own account.",
      "detail": "halden-mutual"
    },
    "teams": {
      "ready": false,
      "needs": "Your workspace has not connected this team chat. An owner or admin connects it in Settings, Integrations.",
      "detail": null
    },
    "webhook": {
      "ready": false,
      "needs": "Add your webhook address.",
      "detail": null
    }
  },
  "email": {
    "address": "erik.haugen@halden.example",
    "timing": "at_once"
  },
  "quiet_hours": {
    "on": false,
    "from": "20:00",
    "to": "08:00",
    "time_zone": "Europe/Oslo"
  },
  "updated_at": null
}
```

## Change your notification settings

Turn channels on or off for kinds of events, choose email at once or once a day, and set quiet hours. A channel that is not set up yet keeps your choice and starts once it is.

`PATCH /v1/me/notification_preferences`. Who may: Every member, for themselves. CLI: `kontiga notifications set [--turn-on <kind:channel>,...] [--turn-off <kind:channel>,...] [--email-timing <at_once|daily>] [--quiet-hours <true|false>] [--quiet-from <HH:MM>] [--quiet-to <HH:MM>]`. MCP tool: `set_my_notification_settings`.

**Parameters**
- `turn_on` (array of string): Cells to turn on, each as `kind:channel`, such as `case_assigned:push`. At most 200 items.
- `turn_off` (array of string): Cells to turn off, in the same form. A cell is named once. At most 200 items.
- `email_timing` (enum): `at_once`, or `daily` for one summary a day.
- `quiet_hours` (boolean): Turn quiet hours on or off.
- `quiet_from` (string): When they start, as `HH:MM` in your time zone.
- `quiet_to` (string): When they end. They may cross midnight.

**Returns** notification preferences: Your notification settings, changed.

API:

```bash
curl -X PATCH https://api.kontiga.com/v1/me/notification_preferences \
  -H "Authorization: Bearer $KONTIGA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "turn_on": [
      "case_assigned:slack",
      "document_high_risk:push"
    ],
    "email_timing": "daily",
    "quiet_hours": true,
    "quiet_from": "20:00",
    "quiet_to": "07:30"
  }'
```

CLI:

```bash
kontiga notifications set \
  --turn-on case_assigned:slack,document_high_risk:push \
  --email-timing daily \
  --quiet-hours \
  --quiet-from 20:00 \
  --quiet-to 07:30
```

MCP tool `set_my_notification_settings`:

```json
{
  "name": "set_my_notification_settings",
  "arguments": {
    "turn_on": [
      "case_assigned:slack",
      "document_high_risk:push"
    ],
    "email_timing": "daily",
    "quiet_hours": true,
    "quiet_from": "20:00",
    "quiet_to": "07:30"
  }
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.notificationPreferences.set({
  turn_on: ["case_assigned:slack", "document_high_risk:push"],
  email_timing: "daily",
  quiet_hours: true,
  quiet_from: "20:00",
  quiet_to: "07:30",
});
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.notification_preferences.set(
    turn_on=["case_assigned:slack", "document_high_risk:push"],
    email_timing="daily",
    quiet_hours=True,
    quiet_from="20:00",
    quiet_to="07:30",
)
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.NotificationPreferences.Set(ctx, &kontiga.NotificationPreferencesSetParams{
	TurnOn:      []string{"case_assigned:slack", "document_high_risk:push"},
	EmailTiming: "daily",
	QuietHours:  true,
	QuietFrom:   "20:00",
	QuietTo:     "07:30",
})
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.notificationPreferences().set(NotificationPreferencesSetParams.builder()
    .turnOn(List.of("case_assigned:slack", "document_high_risk:push"))
    .emailTiming("daily")
    .quietHours(true)
    .quietFrom("20:00")
    .quietTo("07:30")
    .build());
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.NotificationPreferences.SetAsync(new NotificationPreferencesSetOptions
{
    TurnOn = new[] { "case_assigned:slack", "document_high_risk:push" },
    EmailTiming = "daily",
    QuietHours = true,
    QuietFrom = "20:00",
    QuietTo = "07:30",
});
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->notificationPreferences->set([
    'turn_on' => ['case_assigned:slack', 'document_high_risk:push'],
    'email_timing' => 'daily',
    'quiet_hours' => true,
    'quiet_from' => '20:00',
    'quiet_to' => '07:30',
]);
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.notification_preferences.set(
  turn_on: ["case_assigned:slack", "document_high_risk:push"],
  email_timing: "daily",
  quiet_hours: true,
  quiet_from: "20:00",
  quiet_to: "07:30"
)
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .notification_preferences()
    .set(kontiga::notification_preferences::SetParams {
        turn_on: vec!["case_assigned:slack".into(), "document_high_risk:push".into()],
        email_timing: "daily".into(),
        quiet_hours: true,
        quiet_from: "20:00".into(),
        quiet_to: "07:30".into(),
        ..Default::default()
    })
    .await?;
```

Response, 200 OK:

```json
{
  "kinds": [
    {
      "kind": "case_assigned",
      "group": "my_cases",
      "label": "A case is assigned to you",
      "channels": {
        "console": true,
        "push": true,
        "email": true,
        "slack": true,
        "teams": false,
        "webhook": false
      }
    },
    {
      "kind": "document_high_risk",
      "group": "documents",
      "label": "A document on your case is High risk",
      "channels": {
        "console": true,
        "push": true,
        "email": false,
        "slack": false,
        "teams": false,
        "webhook": false
      }
    }
  ],
  "email": {
    "address": "erik.haugen@halden.example",
    "timing": "daily"
  },
  "quiet_hours": {
    "on": true,
    "from": "20:00",
    "to": "07:30",
    "time_zone": "Europe/Oslo"
  },
  "updated_at": "2026-11-27T09:40:12Z"
}
```

## Browser push

Push is turned on in each browser, by you, in that browser: the browser asks your permission only then. You keep it on in 10 browsers at most. A click on a notification opens what it is about in the console, in a tab already open when there is one.

1. Read `application_server_key` with [List the browsers you get notifications in](https://kontiga.com/docs/notifications#list-your-browsers).
2. In the browser, subscribe with it: `registration.pushManager.subscribe({ userVisibleOnly: true, applicationServerKey })`.
3. Send what the browser answered to [Turn on notifications in a browser](https://kontiga.com/docs/notifications#turn-on-notifications-in-a-browser), with the browser's name.

> **Safari on iPhone and iPad** It shows browser push only for a site added to the Home Screen. Add Kontiga there first, open it from there, then turn notifications on.

**A notification**
- `v` (number): The shape's version: `1`.
- `id` (string): The notification's id, starting with `ntf_`.
- `kind` (string): The kind of event, from the table above, or `test`.
- `workspace` (object): The `id` and `name` of the workspace it comes from.
- `mode` (enum): `live` or `test`.
- `title` (string): Short, such as `HM-4554 assigned to you`.
- `body` (string): One line. It never holds a document's content or a score.
- `url` (string): The console page it opens, as a path.
- `object` (object): What it is about: its `type` (`case`, `document`, `request`, `screening`, `workflow_run`, `kompis_run`, `kompis`, `note`, `billing` or `none`) and its `id`.
- `created_at` (string): When the event happened.
- `icon` (string): The workspace's logo, or Kontiga's mark.
- `group` (object): `tag` is shared by one kind in one workspace, so a newer notification replaces one not shown yet; `many` is the line for several at once, `{count}` replaced by how many; `url` is what that line opens.

**A notification**

```json
{
  "v": 1,
  "id": "ntf_mih2k3q81",
  "kind": "case_assigned",
  "workspace": {
    "id": "ws_2Vp6Gh9",
    "name": "Halden Mutual"
  },
  "mode": "live",
  "title": "HM-4554 assigned to you",
  "body": "Ingrid Aasen: Water damage, Strandgata 14",
  "url": "/console/cases/case_3Fh8Nz5",
  "object": {
    "type": "case",
    "id": "case_3Fh8Nz5"
  },
  "created_at": "2026-11-27T09:42:10Z",
  "icon": "/android-icon-192x192.png",
  "group": {
    "tag": "ws_2Vp6Gh9:case_assigned",
    "many": "{count} cases assigned to you",
    "url": "/console/cases?view=mine"
  }
}
```

## List the browsers you get notifications in

Each browser you turned browser push on in, when it was turned on and last used, and the key a new browser subscribes with.

`GET /v1/me/push_subscriptions`. Who may: Every member, for themselves. CLI: `kontiga push list`. MCP tool: `list_my_push_browsers`.

**Parameters**

**Returns** list of push subscriptions: Your browsers, the most recently used first, and Kontiga's application server key.

API:

```bash
curl -X GET https://api.kontiga.com/v1/me/push_subscriptions \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga push list
```

MCP tool `list_my_push_browsers`:

```json
{
  "name": "list_my_push_browsers",
  "arguments": {}
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.pushSubscriptions.list();
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.list()
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PushSubscriptions.List(ctx)
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.pushSubscriptions().list();
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PushSubscriptions.ListAsync();
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->pushSubscriptions->list();
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.list
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .push_subscriptions()
    .list()
    .await?;
```

Response, 200 OK:

```json
{
  "application_server_key": "Bnb-nnRg9Yt4X5wbnAdFKgH8ipgk0evkyw-N3CKl7ZUXdljKRAXhdE19e0c5fwa0qA9BnLnL7XJ5xVDK43hYgYw",
  "subscriptions": [
    {
      "id": "psb_7Kd3Xq9",
      "browser": "Chrome on macOS",
      "endpoint": "https://push.example.net/wp/Rr-fGXNUceivZBgu0r8sAvVFszNiuMUi",
      "created_at": "2026-11-20T08:14:31Z",
      "last_used_at": "2026-11-27T09:42:10Z"
    }
  ]
}
```

## Turn on notifications in a browser

Keeps the subscription a browser made with Kontiga's key, so browser push reaches it. The same browser twice stays one.

`POST /v1/me/push_subscriptions`. Who may: Every member, for themselves. CLI: `kontiga push add --endpoint <https address> --keys <json> [--expiration-time <ms>] [--browser <browser on system>]`. MCP tool: `add_push_browser`.

**Parameters**
- `endpoint` (URL, required): The `endpoint` the browser's subscription holds. At most 2,048 characters.
- `keys` (object, required): Its `p256dh` key and `auth` secret, in base64url, as the browser gives them.
- `expiration_time` (integer): When the browser ends the subscription, in milliseconds since 1970, or `null`. `null` clears it.
- `browser` (string): The browser and the system, such as `Chrome on macOS`, as you will see it in your list. At most 60 characters.

**Returns** push subscription: The browser, on.

API:

```bash
curl -X POST https://api.kontiga.com/v1/me/push_subscriptions \
  -H "Authorization: Bearer $KONTIGA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "endpoint": "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
    "keys": {
      "p256dh": "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA",
      "auth": "gkAonV_rWZic5eMOTRQQiw"
    },
    "expiration_time": null,
    "browser": "Firefox on Windows"
  }'
```

CLI:

```bash
kontiga push add \
  --endpoint https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn \
  --keys '{"p256dh":"B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA","auth":"gkAonV_rWZic5eMOTRQQiw"}' \
  --expiration-time none \
  --browser 'Firefox on Windows'
```

MCP tool `add_push_browser`:

```json
{
  "name": "add_push_browser",
  "arguments": {
    "endpoint": "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
    "keys": {
      "p256dh": "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA",
      "auth": "gkAonV_rWZic5eMOTRQQiw"
    },
    "expiration_time": null,
    "browser": "Firefox on Windows"
  }
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.pushSubscriptions.create({
  endpoint: "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
  keys: { p256dh: "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA", auth: "gkAonV_rWZic5eMOTRQQiw" },
  expiration_time: null,
  browser: "Firefox on Windows",
});
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.create(
    endpoint="https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
    keys={"p256dh": "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA", "auth": "gkAonV_rWZic5eMOTRQQiw"},
    expiration_time=None,
    browser="Firefox on Windows",
)
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PushSubscriptions.Create(ctx, &kontiga.PushSubscriptionsCreateParams{
	Endpoint:       "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
	Keys:           map[string]any{"p256dh": "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA", "auth": "gkAonV_rWZic5eMOTRQQiw"},
	ExpirationTime: nil,
	Browser:        "Firefox on Windows",
})
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.pushSubscriptions().create(PushSubscriptionsCreateParams.builder()
    .endpoint("https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn")
    .keys(Map.of("p256dh", "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA", "auth", "gkAonV_rWZic5eMOTRQQiw"))
    .expirationTime(null)
    .browser("Firefox on Windows")
    .build());
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PushSubscriptions.CreateAsync(new PushSubscriptionsCreateOptions
{
    Endpoint = "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
    Keys = new Dictionary<string, object> { ["p256dh"] = "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA", ["auth"] = "gkAonV_rWZic5eMOTRQQiw" },
    ExpirationTime = null,
    Browser = "Firefox on Windows",
});
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->pushSubscriptions->create([
    'endpoint' => 'https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn',
    'keys' => ['p256dh' => 'B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA', 'auth' => 'gkAonV_rWZic5eMOTRQQiw'],
    'expiration_time' => null,
    'browser' => 'Firefox on Windows',
]);
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.create(
  endpoint: "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
  keys: { p256dh: "B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA", auth: "gkAonV_rWZic5eMOTRQQiw" },
  expiration_time: nil,
  browser: "Firefox on Windows"
)
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .push_subscriptions()
    .create(kontiga::push_subscriptions::CreateParams {
        endpoint: "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn".into(),
        keys: serde_json::json!({"p256dh":"B82vdfC09r4LUhMHYr9vnIU_9VtR1uHXgjmdkDpb-xRV9xQXTvqotYgJWPSnibvkeYlCEkpWremtjYStkC-rZFA","auth":"gkAonV_rWZic5eMOTRQQiw"}),
        expiration_time: None,
        browser: "Firefox on Windows".into(),
        ..Default::default()
    })
    .await?;
```

Response, 201 Created:

```json
{
  "id": "psb_2Wm8Tc4",
  "browser": "Firefox on Windows",
  "endpoint": "https://push.example.net/wp/fXbGBwiN82vdfC09r4LUhMHYr9vn",
  "created_at": "2026-11-27T09:45:02Z",
  "last_used_at": null
}
```

## Turn off notifications in a browser

That browser no longer gets browser push from Kontiga. Your other browsers stay on.

`DELETE /v1/me/push_subscriptions/{subscription_id}`. Who may: Every member, for themselves. CLI: `kontiga push remove <subscription_id>`. MCP tool: `remove_push_browser`.

**Parameters**
- `subscription_id` (id (psb_), required): The browser to turn off, from your list. In the path.

**Returns** push subscription, removed: The browser gets no more notifications.

API:

```bash
curl -X DELETE https://api.kontiga.com/v1/me/push_subscriptions/psb_2Wm8Tc4 \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga push remove psb_2Wm8Tc4
```

MCP tool `remove_push_browser`:

```json
{
  "name": "remove_push_browser",
  "arguments": {
    "subscription_id": "psb_2Wm8Tc4"
  }
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.pushSubscriptions.delete("psb_2Wm8Tc4");
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.delete("psb_2Wm8Tc4")
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PushSubscriptions.Delete(ctx, "psb_2Wm8Tc4")
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.pushSubscriptions().delete("psb_2Wm8Tc4");
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PushSubscriptions.DeleteAsync("psb_2Wm8Tc4");
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->pushSubscriptions->delete('psb_2Wm8Tc4');
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.delete("psb_2Wm8Tc4")
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .push_subscriptions()
    .delete("psb_2Wm8Tc4".into())
    .await?;
```

Response, 200 OK:

```json
{ "id": "psb_2Wm8Tc4", "removed": true }
```

## Send a test notification

Sends a test to every browser you turned on, or to one. It shows as any notification does.

`POST /v1/me/push_subscriptions/test`. Who may: Every member, for themselves. CLI: `kontiga push test [--subscription-id <psb_id>]`. MCP tool: `test_push_notifications`.

**Parameters**
- `subscription_id` (id (psb_)): One browser to test. Every browser you turned on when left out.

**Returns** push test: The browsers it was sent to, and the notification they were sent.

API:

```bash
curl -X POST https://api.kontiga.com/v1/me/push_subscriptions/test \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga push test
```

MCP tool `test_push_notifications`:

```json
{
  "name": "test_push_notifications",
  "arguments": {}
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.pushSubscriptions.test();
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.test()
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PushSubscriptions.Test(ctx)
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.pushSubscriptions().test();
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PushSubscriptions.TestAsync();
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->pushSubscriptions->test();
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.push_subscriptions.test
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .push_subscriptions()
    .test()
    .await?;
```

Response, 200 OK:

```json
{
  "sent": [
    {
      "subscription_id": "psb_7Kd3Xq9",
      "browser": "Chrome on macOS"
    }
  ],
  "payload": {
    "v": 1,
    "id": "ntf_mih2m0c42",
    "kind": "test",
    "workspace": {
      "id": "ws_2Vp6Gh9",
      "name": "Halden Mutual"
    },
    "mode": "live",
    "title": "Notifications are on",
    "body": "This browser will tell you when something in Halden Mutual needs you.",
    "url": "/console/account/notifications",
    "object": { "type": "none", "id": null },
    "created_at": "2026-11-27T09:46:20Z",
    "icon": "/android-icon-192x192.png",
    "group": {
      "tag": "ws_2Vp6Gh9:test",
      "many": "{count} test notifications",
      "url": "/console/account/notifications"
    }
  }
}
```

## Your webhook

Your own https address, for your own tools. Each notification is a POST of the notification's JSON, the same as a push, signed with a secret of your own. Kontiga sends only to public addresses.

The `Kontiga-Signature` header is `t=<unix time>,v1=<signature>`. The signature is the HMAC-SHA256, in hex, of the time, a full stop and the raw body, keyed with your secret. Compute it on the body exactly as it arrived, before you parse it, and compare in constant time.

**Check the signature**

TypeScript:

```typescript
import { createHmac, timingSafeEqual } from "node:crypto";

// header: the Kontiga-Signature header; body: the raw body, exactly as received
export function fromKontiga(header: string, body: string, secret: string): boolean {
  const parts = Object.fromEntries(header.split(",").map((p) => p.split("=", 2)));
  const expected = createHmac("sha256", secret).update(`${parts.t}.${body}`).digest("hex");
  const given = String(parts.v1 ?? "");
  return given.length === expected.length && timingSafeEqual(Buffer.from(given), Buffer.from(expected));
}
```

Python:

```python
import hashlib
import hmac

# header: the Kontiga-Signature header; body: the raw body, exactly as received
def from_kontiga(header: str, body: bytes, secret: str) -> bool:
    parts = dict(p.split("=", 1) for p in header.split(","))
    signed = parts.get("t", "").encode() + b"." + body
    expected = hmac.new(secret.encode(), signed, hashlib.sha256).hexdigest()
    return hmac.compare_digest(parts.get("v1", ""), expected)
```

## Read your webhook

Your own https address that gets your notifications as signed POSTs, the signing secret's last four characters and the last test.

`GET /v1/me/webhook`. Who may: Every member, for themselves. CLI: `kontiga me webhook get`. MCP tool: `get_my_webhook`.

**Parameters**

**Returns** personal webhook: Your webhook address, its secret's last four characters and the last test; the address is null when you have none.

API:

```bash
curl -X GET https://api.kontiga.com/v1/me/webhook \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga me webhook get
```

MCP tool `get_my_webhook`:

```json
{
  "name": "get_my_webhook",
  "arguments": {}
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.personalWebhook.get();
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.personal_webhook.get()
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PersonalWebhook.Get(ctx)
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.personalWebhook().get();
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PersonalWebhook.GetAsync();
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->personalWebhook->get();
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.personal_webhook.get
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .personal_webhook()
    .get()
    .await?;
```

Response, 200 OK:

```json
{
  "url": "https://ops.halden.example/kontiga/erik",
  "secret_last4": "a5Ue",
  "created_at": "2026-11-27T09:50:44Z",
  "last_test": {
    "at": "2026-11-27T09:51:03Z",
    "delivered": true,
    "status_code": 200,
    "duration_ms": 142,
    "message": "Delivered, 200 in 142 ms."
  }
}
```

## Set your webhook

The https address your notifications are sent to, each signed with a secret of your own. A new address or a new secret answers the secret once: copy it then.

`PUT /v1/me/webhook`. Who may: Every member, for themselves. CLI: `kontiga me webhook set --url <https address|null> [--roll-secret]`. MCP tool: `set_my_webhook`.

**Parameters**
- `url` (URL, required): Your https address, or `null` to remove the webhook. At most 2,048 characters. `null` clears it.
- `roll_secret` (boolean): Make a new secret. The old one stops at once.

**Returns** personal webhook: Your webhook, with the whole secret when it is new.

API:

```bash
curl -X PUT https://api.kontiga.com/v1/me/webhook \
  -H "Authorization: Bearer $KONTIGA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://ops.halden.example/kontiga/erik"
  }'
```

CLI:

```bash
kontiga me webhook set \
  --url https://ops.halden.example/kontiga/erik
```

MCP tool `set_my_webhook`:

```json
{
  "name": "set_my_webhook",
  "arguments": {
    "url": "https://ops.halden.example/kontiga/erik"
  }
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.personalWebhook.set({
  url: "https://ops.halden.example/kontiga/erik",
});
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.personal_webhook.set(url="https://ops.halden.example/kontiga/erik")
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PersonalWebhook.Set(ctx, &kontiga.PersonalWebhookSetParams{
	Url: "https://ops.halden.example/kontiga/erik",
})
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.personalWebhook().set(PersonalWebhookSetParams.builder()
    .url("https://ops.halden.example/kontiga/erik")
    .build());
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PersonalWebhook.SetAsync(new PersonalWebhookSetOptions
{
    Url = "https://ops.halden.example/kontiga/erik",
});
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->personalWebhook->set([
    'url' => 'https://ops.halden.example/kontiga/erik',
]);
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.personal_webhook.set(url: "https://ops.halden.example/kontiga/erik")
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .personal_webhook()
    .set(kontiga::personal_webhook::SetParams {
        url: "https://ops.halden.example/kontiga/erik".into(),
        ..Default::default()
    })
    .await?;
```

Response, 200 OK:

```json
{
  "url": "https://ops.halden.example/kontiga/erik",
  "secret_last4": "a5Ue",
  "secret": "whsec_Q7mTz2Kp9WcR4vNx8HbJ3sLd6YgFa5Ue",
  "created_at": "2026-11-27T09:50:44Z",
  "last_test": null
}
```

## Send a test to your webhook

Sends a signed test notification to your webhook and answers what came back.

`POST /v1/me/webhook/test`. Who may: Every member, for themselves. CLI: `kontiga me webhook test`. MCP tool: `test_my_webhook`.

**Parameters**

**Returns** webhook test: Whether it was delivered, the status and time, and the request exactly as sent.

API:

```bash
curl -X POST https://api.kontiga.com/v1/me/webhook/test \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga me webhook test
```

MCP tool `test_my_webhook`:

```json
{
  "name": "test_my_webhook",
  "arguments": {}
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.personalWebhook.test();
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.personal_webhook.test()
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.PersonalWebhook.Test(ctx)
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.personalWebhook().test();
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.PersonalWebhook.TestAsync();
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->personalWebhook->test();
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.personal_webhook.test
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .personal_webhook()
    .test()
    .await?;
```

Response, 200 OK:

```json
{
  "delivered": true,
  "status_code": 200,
  "duration_ms": 142,
  "message": "Delivered, 200 in 142 ms.",
  "request": {
    "url": "https://ops.halden.example/kontiga/erik",
    "headers": [
      ["Content-Type", "application/json"],
      ["User-Agent", "Kontiga-Notifications/1.0"],
      [
        "Kontiga-Signature",
        "t=1795773063,v1=272030c9ef6cb3fde8a212399e950cf8419f54e82c82fd9b68319c3ef281b74c"
      ]
    ],
    "body": "{\"v\":1,\"id\":\"ntf_mih2n1f53\",\"kind\":\"test\",\"workspace\":{\"id\":\"ws_2Vp6Gh9\",\"name\":\"Halden Mutual\"},\"mode\":\"live\",\"title\":\"Your webhook works\",\"body\":\"Your notifications from Halden Mutual will come to this address.\",\"url\":\"/console/account/notifications\",\"object\":{\"type\":\"none\",\"id\":null},\"created_at\":\"2026-11-27T09:51:03Z\",\"group\":{\"tag\":\"ws_2Vp6Gh9:test\",\"many\":\"{count} test notifications\",\"url\":\"/console/account/notifications\"},\"icon\":\"/android-icon-192x192.png\"}"
  }
}
```

## Team chat

Notifications come to you as direct messages, through the workspace's own team chat. An owner or admin connects it in [Integrations](https://kontiga.com/docs/settings#integrations); you then link your own account there, signing in as yourself.

## List your Slack and Teams links

Whether the workspace has Slack and Microsoft Teams connected, and whether your own account there is linked, so notifications reach you as direct messages.

`GET /v1/me/chat_links`. Who may: Every member, for themselves. CLI: `kontiga chat-links list`. MCP tool: `list_my_chat_links`.

**Parameters**

**Returns** list of chat links: Slack and Microsoft Teams: the workspace's connection and your own link.

API:

```bash
curl -X GET https://api.kontiga.com/v1/me/chat_links \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga chat-links list
```

MCP tool `list_my_chat_links`:

```json
{
  "name": "list_my_chat_links",
  "arguments": {}
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.chatLinks.list();
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.chat_links.list()
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.ChatLinks.List(ctx)
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.chatLinks().list();
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.ChatLinks.ListAsync();
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->chatLinks->list();
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.chat_links.list
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .chat_links()
    .list()
    .await?;
```

Response, 200 OK:

```json
[
  {
    "tool": "slack",
    "workspace_connected": true,
    "workspace_account": "halden.slack.com",
    "linked": false,
    "account": null,
    "linked_at": null
  },
  {
    "tool": "teams",
    "workspace_connected": false,
    "workspace_account": null,
    "linked": false,
    "account": null,
    "linked_at": null
  }
]
```

## Link your Slack or Teams account

Links your own Slack or Microsoft Teams account through the workspace's integration, so your notifications come as direct messages. You sign in there as yourself.

`POST /v1/me/chat_links`. Who may: Every member, for themselves. CLI: `kontiga chat-links link <slack|teams>`. MCP tool: `link_my_chat_account`.

**Parameters**
- `tool` (enum, required): `slack` or `teams`. Refused while the workspace has not connected it. When `authorize_url` is set, open it to sign in there.

**Returns** chat link: The link, and where to sign in when it is not made at once.

API:

```bash
curl -X POST https://api.kontiga.com/v1/me/chat_links \
  -H "Authorization: Bearer $KONTIGA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "tool": "slack"
  }'
```

CLI:

```bash
kontiga chat-links link slack
```

MCP tool `link_my_chat_account`:

```json
{
  "name": "link_my_chat_account",
  "arguments": {
    "tool": "slack"
  }
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.chatLinks.link({
  tool: "slack",
});
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.chat_links.link(tool="slack")
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.ChatLinks.Link(ctx, &kontiga.ChatLinksLinkParams{
	Tool: "slack",
})
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.chatLinks().link(ChatLinksLinkParams.builder()
    .tool("slack")
    .build());
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.ChatLinks.LinkAsync(new ChatLinksLinkOptions
{
    Tool = "slack",
});
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->chatLinks->link([
    'tool' => 'slack',
]);
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.chat_links.link(tool: "slack")
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .chat_links()
    .link(kontiga::chat_links::LinkParams {
        tool: "slack".into(),
        ..Default::default()
    })
    .await?;
```

Response, 200 OK:

```json
{
  "tool": "slack",
  "workspace_connected": true,
  "workspace_account": "halden.slack.com",
  "linked": true,
  "account": "@erik.haugen",
  "linked_at": "2026-11-27T09:55:18Z",
  "authorize_url": null
}
```

## Unlink your Slack or Teams account

Your notifications stop coming as direct messages there. The workspace's integration stays as it is.

`DELETE /v1/me/chat_links/{tool}`. Who may: Every member, for themselves. CLI: `kontiga chat-links unlink <slack|teams>`. MCP tool: `unlink_my_chat_account`.

**Parameters**
- `tool` (enum, required): `slack` or `teams`. In the path.

**Returns** chat link: The tool, no longer linked to you.

API:

```bash
curl -X DELETE https://api.kontiga.com/v1/me/chat_links/slack \
  -H "Authorization: Bearer $KONTIGA_API_KEY"
```

CLI:

```bash
kontiga chat-links unlink slack
```

MCP tool `unlink_my_chat_account`:

```json
{
  "name": "unlink_my_chat_account",
  "arguments": {
    "tool": "slack"
  }
}
```

TypeScript:

```typescript
import Kontiga from "@kontiga/sdk";

const kontiga = new Kontiga(); // reads KONTIGA_API_KEY
const result = await kontiga.chatLinks.unlink("slack");
```

Python:

```python
from kontiga import Kontiga

kontiga = Kontiga()  # reads KONTIGA_API_KEY
result = kontiga.chat_links.unlink("slack")
```

Go:

```go
client := kontiga.NewClient() // reads KONTIGA_API_KEY
result, err := client.ChatLinks.Unlink(ctx, "slack")
if err != nil {
	return err
}
```

Java:

```java
Kontiga kontiga = Kontiga.fromEnv(); // reads KONTIGA_API_KEY
var result = kontiga.chatLinks().unlink("slack");
```

.NET:

```csharp
var kontiga = new KontigaClient(); // reads KONTIGA_API_KEY
var result = await kontiga.ChatLinks.UnlinkAsync("slack");
```

PHP:

```php
$kontiga = new \Kontiga\Client(); // reads KONTIGA_API_KEY
$result = $kontiga->chatLinks->unlink('slack');
```

Ruby:

```ruby
require "kontiga"

kontiga = Kontiga::Client.new # reads KONTIGA_API_KEY
result = kontiga.chat_links.unlink("slack")
```

Rust:

```rust
let kontiga = kontiga::Client::from_env()?; // reads KONTIGA_API_KEY
let result = kontiga
    .chat_links()
    .unlink("slack".into())
    .await?;
```

Response, 200 OK:

```json
{
  "tool": "slack",
  "workspace_connected": true,
  "workspace_account": "halden.slack.com",
  "linked": false,
  "account": null,
  "linked_at": null
}
```
