> ## Documentation Index
> Fetch the complete documentation index at: https://docs.runaether.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Slack connection

> Sets the organization's Slack default actor, the member tasks started from Slack are created as when the sender has no linked Aether identity, and returns the organization's Slack status.

Use this tool when you need to:
- Choose whom tasks from unlinked Slack senders are created as
- Move the default actor off a member before their role changes or they leave the organization

Examples:
- PATCH /orgs/{orgID}/slack/connection {"default_actor_user_id": "6f1c2a9e-3b7d-4c55-9a2e-0d8b1f4e7c21"}

Hints:
- orgID is the org's uuid; default_actor_user_id is required and the only field, a user's uuid (the schema answers 422 for a missing or non-uuid value or any other field).
- The default actor starts as the installer and must be a current member with a product role: 422 default_actor_not_member for a user who is not a current member of the organization, or who is its viewer or billing member. A linked sender whose role is viewer or billing also gets the default actor.
- Returns the organization's Slack status as getSlackStatus reads it, connected with the new default_actor_user_id.
- Use listOrgMembers instead to find a member's user id, and linkSlackIdentity for a sender to have their own Slack tasks created as them.
- Owners and admins only, with a session or a platform API key: a member, viewer or billing member is refused with 403 org_role_insufficient before the body is validated, a non-member with 403 org_membership_required, an orgID that is not a uuid with 400, and an agent host's grant with 403 agent_host_route_not_allowed.
- Refused with 404 not_connected when Slack is not installed.



## OpenAPI

````yaml api-reference/openapi.json PATCH /orgs/{orgID}/slack/connection
openapi: 3.1.0
info:
  title: Aether API
  version: 0.1.0
servers:
  - url: https://api.runaether.dev
security:
  - bearerAuth: []
paths:
  /orgs/{orgID}/slack/connection:
    patch:
      tags:
        - slack
      summary: Update Slack connection
      description: >-
        Sets the organization's Slack default actor, the member tasks started
        from Slack are created as when the sender has no linked Aether identity,
        and returns the organization's Slack status.


        Use this tool when you need to:

        - Choose whom tasks from unlinked Slack senders are created as

        - Move the default actor off a member before their role changes or they
        leave the organization


        Examples:

        - PATCH /orgs/{orgID}/slack/connection {"default_actor_user_id":
        "6f1c2a9e-3b7d-4c55-9a2e-0d8b1f4e7c21"}


        Hints:

        - orgID is the org's uuid; default_actor_user_id is required and the
        only field, a user's uuid (the schema answers 422 for a missing or
        non-uuid value or any other field).

        - The default actor starts as the installer and must be a current member
        with a product role: 422 default_actor_not_member for a user who is not
        a current member of the organization, or who is its viewer or billing
        member. A linked sender whose role is viewer or billing also gets the
        default actor.

        - Returns the organization's Slack status as getSlackStatus reads it,
        connected with the new default_actor_user_id.

        - Use listOrgMembers instead to find a member's user id, and
        linkSlackIdentity for a sender to have their own Slack tasks created as
        them.

        - Owners and admins only, with a session or a platform API key: a
        member, viewer or billing member is refused with 403
        org_role_insufficient before the body is validated, a non-member with
        403 org_membership_required, an orgID that is not a uuid with 400, and
        an agent host's grant with 403 agent_host_route_not_allowed.

        - Refused with 404 not_connected when Slack is not installed.
      operationId: updateSlackConnection
      parameters:
        - in: path
          name: orgID
          required: true
          schema:
            format: uuid
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateSlackConnectionInputBody'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IntegrationStatus'
          description: OK
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SlackErrorResponse'
          description: Bad Request
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SlackErrorResponse'
          description: Unauthorized
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrgAuthorizationErrorResponse'
          description: Forbidden
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SlackErrorResponse'
          description: Not Found
        '410':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SlackErrorResponse'
          description: Gone
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SlackErrorResponse'
          description: Unprocessable Entity
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SlackErrorResponse'
          description: Internal Server Error
components:
  schemas:
    UpdateSlackConnectionInputBody:
      additionalProperties: false
      properties:
        default_actor_user_id:
          format: uuid
          type: string
      required:
        - default_actor_user_id
      type: object
    IntegrationStatus:
      discriminator:
        mapping:
          connected: '#/components/schemas/ConnectedIntegrationStatus'
          disconnected: '#/components/schemas/DisconnectedIntegrationStatus'
          reauthorization_required: '#/components/schemas/ReauthorizationRequiredIntegrationStatus'
          unavailable: '#/components/schemas/UnavailableIntegrationStatus'
        propertyName: kind
      oneOf:
        - $ref: '#/components/schemas/UnavailableIntegrationStatus'
        - $ref: '#/components/schemas/DisconnectedIntegrationStatus'
        - $ref: '#/components/schemas/ConnectedIntegrationStatus'
        - $ref: '#/components/schemas/ReauthorizationRequiredIntegrationStatus'
    SlackErrorResponse:
      additionalProperties: false
      properties:
        code:
          enum:
            - agent_profile_not_found
            - bad_gateway
            - bad_request
            - cli_upgrade_required
            - client_outdated
            - conflict
            - default_actor_not_member
            - forbidden
            - gateway_timeout
            - gone
            - internal_error
            - method_not_allowed
            - not_acceptable
            - not_connected
            - not_found
            - not_implemented
            - org_membership_required
            - payment_required
            - precondition_failed
            - project_not_found
            - project_repo_disconnected
            - rate_limited
            - request_canceled
            - request_timeout
            - request_too_large
            - route_exists
            - route_not_found
            - service_unavailable
            - slack_channel_not_found
            - slack_identity_link_invalid
            - unauthenticated
            - unsupported_media_type
            - validation_failed
          minLength: 1
          type: string
        error:
          minLength: 1
          type: string
        errors:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
      required:
        - error
        - code
      type: object
    OrgAuthorizationErrorResponse:
      additionalProperties: false
      properties:
        code:
          enum:
            - org_membership_required
            - org_role_insufficient
            - org_suspended
            - account_deleting
            - agent_host_route_not_allowed
            - credential_kind_not_admitted
            - grant_scope_insufficient
          type: string
        error:
          minLength: 1
          type: string
      required:
        - error
        - code
      type: object
    ConnectedIntegrationStatus:
      additionalProperties: false
      properties:
        details:
          $ref: '#/components/schemas/IntegrationDetails'
        kind:
          enum:
            - connected
          type: string
      required:
        - kind
        - details
      type: object
    DisconnectedIntegrationStatus:
      additionalProperties: false
      properties:
        kind:
          enum:
            - disconnected
          type: string
      required:
        - kind
      type: object
    ReauthorizationRequiredIntegrationStatus:
      additionalProperties: false
      properties:
        details:
          $ref: '#/components/schemas/IntegrationDetails'
        kind:
          enum:
            - reauthorization_required
          type: string
      required:
        - kind
        - details
      type: object
    UnavailableIntegrationStatus:
      additionalProperties: false
      properties:
        kind:
          enum:
            - unavailable
          type: string
      required:
        - kind
      type: object
    ErrorDetail:
      additionalProperties: false
      properties:
        location:
          description: >-
            Where the error occurred, e.g. 'body.items[3].tags' or
            'path.thing-id'
          type: string
        message:
          description: Error message text
          type: string
        value:
          description: The value at the given location
      type: object
    IntegrationDetails:
      discriminator:
        mapping:
          github: '#/components/schemas/GitHubIntegrationDetails'
          linear: '#/components/schemas/LinearIntegrationDetails'
          sentry: '#/components/schemas/SentryIntegrationDetails'
          slack: '#/components/schemas/SlackIntegrationDetails'
        propertyName: vendor
      oneOf:
        - $ref: '#/components/schemas/GitHubIntegrationDetails'
        - $ref: '#/components/schemas/LinearIntegrationDetails'
        - $ref: '#/components/schemas/SlackIntegrationDetails'
        - $ref: '#/components/schemas/SentryIntegrationDetails'
    GitHubIntegrationDetails:
      additionalProperties: false
      properties:
        identity:
          $ref: '#/components/schemas/GitHubUserIdentity'
        installations:
          items:
            $ref: '#/components/schemas/GitHubInstallation'
          type: array
        vendor:
          enum:
            - github
          type: string
      required:
        - identity
        - installations
        - vendor
      type: object
    LinearIntegrationDetails:
      additionalProperties: false
      properties:
        default_actor_user_id:
          format: uuid
          type: string
        installed_by:
          format: uuid
          type: string
        organization_id:
          minLength: 1
          type: string
        organization_name:
          minLength: 1
          type: string
        vendor:
          enum:
            - linear
          type: string
      required:
        - default_actor_user_id
        - installed_by
        - organization_id
        - organization_name
        - vendor
      type: object
    SentryIntegrationDetails:
      additionalProperties: false
      properties:
        default_actor_user_id:
          format: uuid
          type: string
        installed_by:
          format: uuid
          type: string
        organization_id:
          minLength: 1
          type: string
        organization_slug:
          minLength: 1
          type: string
        vendor:
          enum:
            - sentry
          type: string
      required:
        - default_actor_user_id
        - installed_by
        - organization_id
        - organization_slug
        - vendor
      type: object
    SlackIntegrationDetails:
      additionalProperties: false
      properties:
        default_actor_user_id:
          format: uuid
          type: string
        dm_ready:
          type: boolean
        installed_by:
          format: uuid
          type: string
        needs_reconnect:
          type: boolean
        team_id:
          minLength: 1
          type: string
        team_name:
          minLength: 1
          type: string
        vendor:
          enum:
            - slack
          type: string
      required:
        - default_actor_user_id
        - dm_ready
        - installed_by
        - needs_reconnect
        - team_id
        - team_name
        - vendor
      type: object
    GitHubUserIdentity:
      additionalProperties: false
      properties:
        github_user_id:
          format: int64
          minimum: 1
          type: integer
        login:
          minLength: 1
          pattern: ^\S(?:.*\S)?$
          type: string
      required:
        - github_user_id
        - login
      type: object
    GitHubInstallation:
      additionalProperties: false
      properties:
        account_login:
          minLength: 1
          type: string
        account_type:
          minLength: 1
          type: string
        connected_at:
          format: date-time
          type: string
        installation_id:
          format: int64
          minimum: 1
          type: integer
        permissions_url:
          format: uri
          minLength: 1
          type: string
        repository_administration:
          type: boolean
      required:
        - installation_id
        - account_login
        - account_type
        - connected_at
        - repository_administration
        - permissions_url
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.