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

# Create Linear ticket



## OpenAPI

````yaml https://api.uselemma.ai/openapi.json post /issues/{issue_id}/linear-ticket
openapi: 3.1.0
info:
  title: Lemma Platform API
  description: Lemma Platform HTTP API for AI observability and workspace operations.
  version: 0.1.0
servers:
  - url: https://api.uselemma.ai
    description: Lemma production API
security:
  - bearerAuth: []
paths:
  /issues/{issue_id}/linear-ticket:
    post:
      tags:
        - Linear Tickets
      summary: Create Linear ticket
      operationId: create_linear_ticket
      parameters:
        - name: issue_id
          in: path
          required: true
          description: Lemma issue ID.
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - idempotency_key
              properties:
                idempotency_key:
                  type: string
                team_id:
                  type: string
                linear_project_id:
                  type:
                    - string
                    - 'null'
                combined_assignee_lemma_user_id:
                  type: string
                title:
                  type: string
                description:
                  type: string
              additionalProperties: false
      responses:
        '201':
          description: Created Linear ticket link
          content:
            application/json:
              schema:
                oneOf:
                  - type: object
                    properties:
                      project_id:
                        type: string
                        format: uuid
                      issue_id:
                        type: string
                        format: uuid
                      operation_id:
                        type: string
                        format: uuid
                      idempotent_replay:
                        type: boolean
                      issue_assignee_user_id:
                        type:
                          - string
                          - 'null'
                      status:
                        type: string
                        const: succeeded
                      link:
                        type: object
                        properties:
                          id:
                            type: string
                            format: uuid
                          origin:
                            type: string
                            enum:
                              - created
                              - existing
                          linked_at:
                            type: string
                          sync_status:
                            type: string
                            enum:
                              - healthy
                              - stale
                              - ticket_unavailable
                              - sync_error
                          last_successful_sync_at:
                            type:
                              - string
                              - 'null'
                          last_error_code:
                            type:
                              - string
                              - 'null'
                          last_error_message:
                            type:
                              - string
                              - 'null'
                          last_error_at:
                            type:
                              - string
                              - 'null'
                          ticket:
                            type: object
                            properties:
                              id:
                                type: string
                              identifier:
                                type: string
                              url:
                                type: string
                                format: uri
                              title:
                                type: string
                              team_id:
                                type: string
                              team_name:
                                type: string
                              team_key:
                                type: string
                              linear_project_id:
                                type:
                                  - string
                                  - 'null'
                              linear_project_name:
                                type:
                                  - string
                                  - 'null'
                              state_id:
                                type: string
                              state_name:
                                type: string
                              state_type:
                                type: string
                              linear_assignee:
                                type:
                                  - object
                                  - 'null'
                                properties:
                                  id:
                                    type: string
                                  name:
                                    type: string
                                  avatar_url:
                                    type:
                                      - string
                                      - 'null'
                                required:
                                  - id
                                  - name
                                  - avatar_url
                                additionalProperties: false
                            required:
                              - id
                              - identifier
                              - url
                              - title
                              - team_id
                              - team_name
                              - team_key
                              - linear_project_id
                              - linear_project_name
                              - state_id
                              - state_name
                              - state_type
                              - linear_assignee
                            additionalProperties: false
                        required:
                          - id
                          - origin
                          - linked_at
                          - sync_status
                          - last_successful_sync_at
                          - last_error_code
                          - last_error_message
                          - last_error_at
                          - ticket
                        additionalProperties: false
                    required:
                      - project_id
                      - issue_id
                      - operation_id
                      - idempotent_replay
                      - issue_assignee_user_id
                      - status
                      - link
                    additionalProperties: false
                  - type: object
                    properties:
                      project_id:
                        type: string
                        format: uuid
                      issue_id:
                        type: string
                        format: uuid
                      operation_id:
                        type: string
                        format: uuid
                      idempotent_replay:
                        type: boolean
                      issue_assignee_user_id:
                        type:
                          - string
                          - 'null'
                      status:
                        type: string
                        const: pending
                      link:
                        type: 'null'
                    required:
                      - project_id
                      - issue_id
                      - operation_id
                      - idempotent_replay
                      - issue_assignee_user_id
                      - status
                      - link
                    additionalProperties: false
        '202':
          description: Accepted Linear ticket creation
          content:
            application/json:
              schema:
                oneOf:
                  - type: object
                    properties:
                      project_id:
                        type: string
                        format: uuid
                      issue_id:
                        type: string
                        format: uuid
                      operation_id:
                        type: string
                        format: uuid
                      idempotent_replay:
                        type: boolean
                      issue_assignee_user_id:
                        type:
                          - string
                          - 'null'
                      status:
                        type: string
                        const: succeeded
                      link:
                        type: object
                        properties:
                          id:
                            type: string
                            format: uuid
                          origin:
                            type: string
                            enum:
                              - created
                              - existing
                          linked_at:
                            type: string
                          sync_status:
                            type: string
                            enum:
                              - healthy
                              - stale
                              - ticket_unavailable
                              - sync_error
                          last_successful_sync_at:
                            type:
                              - string
                              - 'null'
                          last_error_code:
                            type:
                              - string
                              - 'null'
                          last_error_message:
                            type:
                              - string
                              - 'null'
                          last_error_at:
                            type:
                              - string
                              - 'null'
                          ticket:
                            type: object
                            properties:
                              id:
                                type: string
                              identifier:
                                type: string
                              url:
                                type: string
                                format: uri
                              title:
                                type: string
                              team_id:
                                type: string
                              team_name:
                                type: string
                              team_key:
                                type: string
                              linear_project_id:
                                type:
                                  - string
                                  - 'null'
                              linear_project_name:
                                type:
                                  - string
                                  - 'null'
                              state_id:
                                type: string
                              state_name:
                                type: string
                              state_type:
                                type: string
                              linear_assignee:
                                type:
                                  - object
                                  - 'null'
                                properties:
                                  id:
                                    type: string
                                  name:
                                    type: string
                                  avatar_url:
                                    type:
                                      - string
                                      - 'null'
                                required:
                                  - id
                                  - name
                                  - avatar_url
                                additionalProperties: false
                            required:
                              - id
                              - identifier
                              - url
                              - title
                              - team_id
                              - team_name
                              - team_key
                              - linear_project_id
                              - linear_project_name
                              - state_id
                              - state_name
                              - state_type
                              - linear_assignee
                            additionalProperties: false
                        required:
                          - id
                          - origin
                          - linked_at
                          - sync_status
                          - last_successful_sync_at
                          - last_error_code
                          - last_error_message
                          - last_error_at
                          - ticket
                        additionalProperties: false
                    required:
                      - project_id
                      - issue_id
                      - operation_id
                      - idempotent_replay
                      - issue_assignee_user_id
                      - status
                      - link
                    additionalProperties: false
                  - type: object
                    properties:
                      project_id:
                        type: string
                        format: uuid
                      issue_id:
                        type: string
                        format: uuid
                      operation_id:
                        type: string
                        format: uuid
                      idempotent_replay:
                        type: boolean
                      issue_assignee_user_id:
                        type:
                          - string
                          - 'null'
                      status:
                        type: string
                        const: pending
                      link:
                        type: 'null'
                    required:
                      - project_id
                      - issue_id
                      - operation_id
                      - idempotent_replay
                      - issue_assignee_user_id
                      - status
                      - link
                    additionalProperties: false
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                required:
                  - detail
                additionalProperties: false
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                required:
                  - detail
                additionalProperties: false
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                required:
                  - detail
                additionalProperties: false
        '503':
          description: Service unavailable
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                required:
                  - detail
                additionalProperties: false
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````