capability_id: repo.labels.list
version: "1.0.0"
description: List repository labels.
input_schema:
  type: object
  required: [owner, name]
  properties:
    owner: { type: string, minLength: 1 }
    name: { type: string, minLength: 1 }
    first: { type: integer, minimum: 1, maximum: 100, default: 30 }
    after: { type: [string, "null"] }
  additionalProperties: false
output_schema:
  type: object
  required: [items, pageInfo]
  properties:
    items:
      type: array
      items:
        type: object
        required: [id, name, description, color, isDefault]
        properties:
          id: { type: [string, "null"] }
          name: { type: [string, "null"] }
          description: { type: [string, "null"] }
          color: { type: [string, "null"] }
          isDefault: { type: [boolean, "null"] }
        additionalProperties: false
    pageInfo:
      type: object
      required: [hasNextPage, endCursor]
      properties:
        hasNextPage: { type: boolean }
        endCursor: { type: [string, "null"] }
      additionalProperties: false
  additionalProperties: false
routing:
  preferred: graphql
  fallbacks: [cli]
graphql:
  operationName: RepoLabelsList
  operationType: query
  documentPath: src/gql/operations/repo-labels-list.graphql
cli:
  command: label list
  jsonFields: [id,name,description,color,isDefault]
