---
title: "Disconnect the organization from a connected workspace: the connection is left in error (errorCode disconnected) and its destinations stop sending but keep their settings, so connecting the same workspace again brings them back. Other organizations connected to that workspace are not affected, and the app stays installed in Slack. It does not need a plan that allows Slack."
method: POST
path: "/v2/organizations/{organizationId}/slack-connections/{connectionId}/disconnect"
tags: ["Organization Slack Connections Api Service"]
---

# Disconnect the organization from a connected workspace: the connection is left in error (errorCode disconnected) and its destinations stop sending but keep their settings, so connecting the same workspace again brings them back. Other organizations connected to that workspace are not affected, and the app stays installed in Slack. It does not need a plan that allows Slack.

`POST /v2/organizations/{organizationId}/slack-connections/{connectionId}/disconnect`

## Request

- Base URL: `https://app.metricool.com/api`
- URL: `https://app.metricool.com/api/v2/organizations/{organizationId}/slack-connections/{connectionId}/disconnect`
- Auth: none declared

## Path parameters

- `organizationId` integer, required
- `connectionId` integer, required

## Response `200`

Connection disconnected, as in the list.

- JsonOkResponseSlackConnectionDto
  - `metadata` object
  - `page` JsonPaging
    - `next` string
  - `data` SlackConnectionDto: A connection of an organization with a Slack workspace.
    - `id` integer: Id of the connection.
    - `status` 'active' | 'pending' | 'error': State of the connection: active, pending (the user started connecting but never came back from Slack, usually because a workspace admin has to approve the app) or error.
    - `errorCode` 'appUninstalled' | 'tokenRevoked' | 'missingScopes' | 'disconnected' | 'workspacePolicy', nullable: Why the connection is in error. Null unless status is error.
    - `workspace` SlackWorkspaceDto: A Slack workspace.
      - `teamId` string: Id Slack assigns to the workspace (team id).
      - `name` string: Name of the workspace.
    - `createdBy` SlackConnectionCreatorDto, nullable: The user who connected the Slack workspace.
      - `name` string: First name and last name of the user, or their email when they have no first name.
      - `profilePicture` string, nullable: URL of the user's profile picture. Null when they have none, and the front shows their initials instead.
    - `createdAt` DateTimeInfo
      - `dateTime` string, required: Local Date-time represented with a certain timezone
      - `timezone` string: Timezone applied to the datetime
    - `brandsCount` integer: How many of the organization's brands send their notifications through this connection.

## Other responses

- `400`: slackConnectionPending: the connection is still pending, there is nothing connected to stop.
- `403`: Caller is not a regular-user session, or is neither the organization owner nor a team member with manageBrands (a team member also needs the organization to be usable: its permissions feature and the owner's plan).
- `404`: Organization or connection not found.

---

[API](https://skmtc.dev/metricool/apis/metricool-api.md) · [All operations](https://skmtc.dev/metricool/apis/metricool-api/llms.txt) · [OpenAPI document](https://skmtc.dev/metricool/apis/metricool-api/revisions/aea9d9a8415a?raw)
