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

# Deactivate a channel

> The channel must be activated, with no recording still running or winding down. Requires the `capture:access` permission.



## OpenAPI

````yaml https://api.up.telestream.com/capture/v1/openapi.json put /{space_id}/channels/{channel_id}/deactivate
openapi: 3.1.0
info:
  contact:
    email: cloudsupport@telestream.net
    name: API Support
    url: https://www.telestream.com
  description: >-
    Programmatic access to recording: the channels that record your live sources
    to storage, and the recording settings they record with.

    Compatibility. Within a version we only add: new endpoints, new optional
    request fields and new optional response fields, and new problem types.
    Clients must ignore response fields and problem types they do not recognise,
    and fall back to the HTTP status class for an unrecognised problem type.
    Anything else - removing or renaming a field, narrowing a type, requiring a
    previously optional field, a new enum value in a response, or changing the
    status for an existing condition - arrives as a new major version under a
    new path.

    A version stays available until it is retired. A retired operation answers
    410 Gone with the operation-retired problem type; a retirement is announced
    when it is decided rather than on a fixed schedule.
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
  termsOfService: https://www.telestream.net/telestream-cloud/terms.htm
  title: Telestream Capture API
  version: 1.0.0
servers:
  - url: https://api.up.telestream.com/capture/v1
security:
  - apiKey: []
tags:
  - description: What the presented API key may do.
    name: Access
  - description: Channels and their recording lifecycle.
    name: Channels
  - description: How a channel records.
    name: Recording settings
  - description: Reusable named recording settings, managed independently of any channel.
    name: Recording settings templates
paths:
  /{space_id}/channels/{channel_id}/deactivate:
    parameters:
      - $ref: '#/components/parameters/SpaceId'
      - $ref: '#/components/parameters/ChannelId'
    put:
      tags:
        - Channels
      summary: Deactivate a channel
      description: >-
        The channel must be activated, with no recording still running or
        winding down. Requires the `capture:access` permission.
      operationId: DeactivateChannel
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Channel'
          description: The deactivated channel.
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '409':
          $ref: '#/components/responses/Conflict'
        '500':
          $ref: '#/components/responses/InternalError'
        '503':
          $ref: '#/components/responses/ServiceUnavailable'
components:
  parameters:
    SpaceId:
      description: The space to act in.
      in: path
      name: space_id
      required: true
      schema:
        format: uuid
        type: string
    ChannelId:
      description: The channel's id.
      in: path
      name: channel_id
      required: true
      schema:
        format: uuid
        type: string
  schemas:
    Channel:
      description: >-
        A channel's configuration and lifecycle state. Its recording settings
        and its recordings are separate sub-resources, so listing channels stays
        a single query.
      properties:
        activated_at:
          format: date-time
          type: string
        auto_shutdown:
          $ref: '#/components/schemas/AutoShutdown'
        description:
          type: string
        id:
          format: uuid
          type: string
        name:
          type: string
        pinned:
          description: >-
            Whether the channel is pinned to the top of the list. Read-only; no
            operation sets it.
          readOnly: true
          type: boolean
        recording_trigger:
          $ref: '#/components/schemas/RecordingTrigger'
        region:
          description: Where the recording worker is placed.
          type: string
        settings:
          additionalProperties: true
          description: >-
            How the channel behaves beyond recording. Its shape is the channel
            settings schema of the engine version the channel records with.
          type: object
        source_id:
          description: The live source the channel records.
          format: uuid
          type: string
        status:
          $ref: '#/components/schemas/ChannelStatus'
        tags:
          items:
            type: string
          type: array
      required:
        - id
        - source_id
        - name
        - description
        - status
        - pinned
      type: object
    AutoShutdown:
      description: When the channel deactivates itself.
      properties:
        enabled:
          type: boolean
        no_recording_timeout:
          description: >-
            Minutes after the last recording before the channel deactivates; at
            least one.
          type: integer
        no_stream_timeout:
          description: >-
            Minutes without an incoming stream before the channel deactivates;
            at least one.
          type: integer
      required:
        - enabled
      type: object
    RecordingTrigger:
      description: The SCTE-35 cues that start and stop recording.
      properties:
        enabled:
          type: boolean
        start_type:
          $ref: '#/components/schemas/RecordingStartTrigger'
        stop_type:
          $ref: '#/components/schemas/RecordingStopTrigger'
      required:
        - enabled
      type: object
    ChannelStatus:
      description: >-
        `draft` is not fully configured and cannot be activated; `inactive` is
        configured but not activated; `pending` is being provisioned; `active`
        can record its source.
      enum:
        - draft
        - inactive
        - pending
        - active
      type: string
    Problem:
      description: An RFC 9457 problem document.
      properties:
        detail:
          description: >-
            What went wrong this time, in words meant for a person. Branch on
            `type` rather than parsing it.
          type: string
        instance:
          description: The request path the problem occurred on.
          type: string
        status:
          description: >-
            The HTTP status code, repeated so a logged payload is
            self-describing.
          type: integer
        title:
          description: A short, stable summary of the problem type.
          type: string
        trace_id:
          description: Correlates this response with the server-side logs.
          type: string
        type:
          description: >-
            Identifies the kind of problem. Branch on this rather than on the
            message.
          type: string
      required:
        - type
        - title
        - status
      type: object
    RecordingStartTrigger:
      description: The SCTE-35 cue that starts a recording.
      enum:
        - program_start
        - break_start
      type: string
    RecordingStopTrigger:
      description: The SCTE-35 cue that stops a recording.
      enum:
        - break_end
        - program_end
      type: string
  responses:
    BadRequest:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: The request could not be understood.
    Unauthorized:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: The request carries no usable API key.
      headers:
        WWW-Authenticate:
          description: The scheme to present a key with.
          schema:
            type: string
    Forbidden:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: The caller may not perform this action in this space.
    NotFound:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: The resource does not exist.
    Conflict:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: >-
        The action is refused by the current state of the resource, or of
        something it depends on. The problem type names the condition to fix.
    InternalError:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: The request could not be completed.
    ServiceUnavailable:
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
      description: A transient condition prevented the request; it is worth retrying.
      headers:
        Retry-After:
          description: Seconds to wait before retrying.
          schema:
            type: integer
  securitySchemes:
    apiKey:
      description: >-
        A platform API key, presented as `Authorization: Bearer <API_KEY>`. Each
        operation says which permission the key needs.
      scheme: bearer
      type: http

````

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