GitHub · Capability

GitHub Repos API — Milestones

GitHub Repos API — Milestones. 6 operations. Lead operation: List Milestones. Self-contained Naftiko capability covering one Github business surface.

Run with Naftiko GithubMilestones

What You Can Do

GET
Listmilestones — List Milestones
/v1/repos/{owner}/{repo}/milestones
POST
Createmilestone — Create Milestone
/v1/repos/{owner}/{repo}/milestones
GET
Getmilestone — Get Milestone
/v1/repos/{owner}/{repo}/milestones/{milestone-number}
PATCH
Updatemilestone — Update Milestone
/v1/repos/{owner}/{repo}/milestones/{milestone-number}
DELETE
Deletemilestone — Delete Milestone
/v1/repos/{owner}/{repo}/milestones/{milestone-number}
GET
Listlabelsforissuesinmilestone — List Labels For Issues In Milestone
/v1/repos/{owner}/{repo}/milestones/{milestone-number}/labels

MCP Tools

list-milestones

List Milestones

read-only idempotent
create-milestone

Create Milestone

get-milestone

Get Milestone

read-only idempotent
update-milestone

Update Milestone

idempotent
delete-milestone

Delete Milestone

idempotent
list-labels-issues-milestone

List Labels For Issues In Milestone

read-only idempotent

Capability Spec

temp-milestones.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: GitHub Repos API — Milestones
  description: 'GitHub Repos API — Milestones. 6 operations. Lead operation: List Milestones. Self-contained Naftiko capability
    covering one Github business surface.'
  tags:
  - Github
  - Milestones
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    GITHUB_API_KEY: GITHUB_API_KEY
capability:
  consumes:
  - type: http
    namespace: temp-milestones
    baseUri: ''
    description: GitHub Repos API — Milestones business capability. Self-contained, no shared references.
    resources:
    - name: repos-owner-repo-milestones
      path: /repos/{owner}/{repo}/milestones
      operations:
      - name: listmilestones
        method: GET
        description: List Milestones
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: state
          in: query
          type: string
          description: The state of the milestone. Either `open`, `closed`, or `all`.
        - name: sort
          in: query
          type: string
          description: What to sort results by. Either `due_on` or `completeness`.
        - name: direction
          in: query
          type: string
          description: The direction of the sort. Either `asc` or `desc`.
        - name: Authorization
          in: header
          type: string
        - name: X-GitHub-Api-Version
          in: header
          type: string
        - name: Accept
          in: header
          type: string
      - name: createmilestone
        method: POST
        description: Create Milestone
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: Authorization
          in: header
          type: string
        - name: X-GitHub-Api-Version
          in: header
          type: string
        - name: Accept
          in: header
          type: string
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: repos-owner-repo-milestones-milestone_number
      path: /repos/{owner}/{repo}/milestones/{milestone_number}
      operations:
      - name: getmilestone
        method: GET
        description: Get Milestone
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: Authorization
          in: header
          type: string
        - name: X-GitHub-Api-Version
          in: header
          type: string
        - name: Accept
          in: header
          type: string
      - name: updatemilestone
        method: PATCH
        description: Update Milestone
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: Authorization
          in: header
          type: string
        - name: X-GitHub-Api-Version
          in: header
          type: string
        - name: Accept
          in: header
          type: string
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
      - name: deletemilestone
        method: DELETE
        description: Delete Milestone
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: Authorization
          in: header
          type: string
        - name: X-GitHub-Api-Version
          in: header
          type: string
        - name: Accept
          in: header
          type: string
    - name: repos-owner-repo-milestones-milestone_number-labels
      path: /repos/{owner}/{repo}/milestones/{milestone_number}/labels
      operations:
      - name: listlabelsforissuesinmilestone
        method: GET
        description: List Labels For Issues In Milestone
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: Authorization
          in: header
          type: string
        - name: X-GitHub-Api-Version
          in: header
          type: string
        - name: Accept
          in: header
          type: string
    authentication:
      type: bearer
      token: '{{env.GITHUB_API_KEY}}'
  exposes:
  - type: rest
    namespace: temp-milestones-rest
    port: 8080
    description: REST adapter for GitHub Repos API — Milestones. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/repos/{owner}/{repo}/milestones
      name: repos-owner-repo-milestones
      description: REST surface for repos-owner-repo-milestones.
      operations:
      - method: GET
        name: listmilestones
        description: List Milestones
        call: temp-milestones.listmilestones
        with:
          state: rest.state
          sort: rest.sort
          direction: rest.direction
          Authorization: rest.Authorization
          X-GitHub-Api-Version: rest.X-GitHub-Api-Version
          Accept: rest.Accept
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createmilestone
        description: Create Milestone
        call: temp-milestones.createmilestone
        with:
          Authorization: rest.Authorization
          X-GitHub-Api-Version: rest.X-GitHub-Api-Version
          Accept: rest.Accept
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/repos/{owner}/{repo}/milestones/{milestone-number}
      name: repos-owner-repo-milestones-milestone-number
      description: REST surface for repos-owner-repo-milestones-milestone_number.
      operations:
      - method: GET
        name: getmilestone
        description: Get Milestone
        call: temp-milestones.getmilestone
        with:
          Authorization: rest.Authorization
          X-GitHub-Api-Version: rest.X-GitHub-Api-Version
          Accept: rest.Accept
        outputParameters:
        - type: object
          mapping: $.
      - method: PATCH
        name: updatemilestone
        description: Update Milestone
        call: temp-milestones.updatemilestone
        with:
          Authorization: rest.Authorization
          X-GitHub-Api-Version: rest.X-GitHub-Api-Version
          Accept: rest.Accept
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deletemilestone
        description: Delete Milestone
        call: temp-milestones.deletemilestone
        with:
          Authorization: rest.Authorization
          X-GitHub-Api-Version: rest.X-GitHub-Api-Version
          Accept: rest.Accept
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/repos/{owner}/{repo}/milestones/{milestone-number}/labels
      name: repos-owner-repo-milestones-milestone-number-labels
      description: REST surface for repos-owner-repo-milestones-milestone_number-labels.
      operations:
      - method: GET
        name: listlabelsforissuesinmilestone
        description: List Labels For Issues In Milestone
        call: temp-milestones.listlabelsforissuesinmilestone
        with:
          Authorization: rest.Authorization
          X-GitHub-Api-Version: rest.X-GitHub-Api-Version
          Accept: rest.Accept
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: temp-milestones-mcp
    port: 9090
    transport: http
    description: MCP adapter for GitHub Repos API — Milestones. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: list-milestones
      description: List Milestones
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: temp-milestones.listmilestones
      with:
        state: tools.state
        sort: tools.sort
        direction: tools.direction
        Authorization: tools.Authorization
        X-GitHub-Api-Version: tools.X-GitHub-Api-Version
        Accept: tools.Accept
      outputParameters:
      - type: object
        mapping: $.
    - name: create-milestone
      description: Create Milestone
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: temp-milestones.createmilestone
      with:
        Authorization: tools.Authorization
        X-GitHub-Api-Version: tools.X-GitHub-Api-Version
        Accept: tools.Accept
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: get-milestone
      description: Get Milestone
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: temp-milestones.getmilestone
      with:
        Authorization: tools.Authorization
        X-GitHub-Api-Version: tools.X-GitHub-Api-Version
        Accept: tools.Accept
      outputParameters:
      - type: object
        mapping: $.
    - name: update-milestone
      description: Update Milestone
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: temp-milestones.updatemilestone
      with:
        Authorization: tools.Authorization
        X-GitHub-Api-Version: tools.X-GitHub-Api-Version
        Accept: tools.Accept
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-milestone
      description: Delete Milestone
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: temp-milestones.deletemilestone
      with:
        Authorization: tools.Authorization
        X-GitHub-Api-Version: tools.X-GitHub-Api-Version
        Accept: tools.Accept
      outputParameters:
      - type: object
        mapping: $.
    - name: list-labels-issues-milestone
      description: List Labels For Issues In Milestone
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: temp-milestones.listlabelsforissuesinmilestone
      with:
        Authorization: tools.Authorization
        X-GitHub-Api-Version: tools.X-GitHub-Api-Version
        Accept: tools.Accept
      outputParameters:
      - type: object
        mapping: $.