# Retire Pipeline Template

`POST /v1/pipelines/templates/{pipeline_template_id}:retire`

No new run starts from the template and no template pins it anew.
Runs that started keep their snapshot; its history stays readable.

- Base URL: `https://junction-api.qualiastudios.dev`
- Authentication: an API key in the `X-API-Key` header, or `Authorization: Bearer …`

## Parameters

- `pipeline_template_id` (path, string (uuid), required)

## Responses

- `200` Successful Response: `application/json` `RetiredTemplate`
- `401` Invalid or missing API key: `application/json` `ErrorResponse`
- `403` Missing capability on the workspace: `application/json` `ErrorResponse`
- `404` Template not found: `application/json` `ErrorResponse`
- `422` Validation Error: `application/json` `HTTPValidationError`

## Schemas

```yaml
RetiredTemplate:
  properties:
    pipeline_template_id:
      type: string
      format: uuid
    retired:
      type: boolean
      const: true
      default: true
  type: object
  required:
    - pipeline_template_id
  title: RetiredTemplate
ErrorResponse:
  properties:
    detail:
      type: string
      description: Error message describing what went wrong
  type: object
  required:
    - detail
  title: ErrorResponse
  description: Standard error response.
HTTPValidationError:
  properties:
    detail:
      items:
        $ref: "#/components/schemas/ValidationError"
      type: array
  type: object
  title: HTTPValidationError
ValidationError:
  properties:
    loc:
      items:
        type:
          - string
          - integer
      type: array
      title: Location
    msg:
      type: string
      title: Message
    type:
      type: string
      title: Error Type
    input: {}
    ctx:
      type: object
      title: Context
  type: object
  required:
    - loc
    - msg
    - type
  title: ValidationError
```
