GitHub Statuses API

The Statuses API from GitHub — 2 operation(s) for statuses.

Documentation

📖
Documentation
https://docs.github.com/en/rest/apps
📖
Documentation
https://docs.github.com/en/rest/codes-of-conduct/codes-of-conduct
📖
Documentation
https://docs.github.com/en/rest/emojis
📖
Documentation
https://docs.github.com/en/rest/gitignore
📖
Documentation
https://docs.github.com/en/rest/apps/installations
📖
Documentation
https://docs.github.com/en/rest/enterprise-admin
📖
Documentation
https://docs.github.com/en/rest/activity/events
📖
Documentation
https://docs.github.com/en/rest/orgs
📖
Documentation
https://docs.github.com/en/rest/rate-limit
📖
Documentation
https://docs.github.com/en/enterprise-cloud@latest/rest/scim
📖
Documentation
https://docs.github.com/en/rest/using-the-rest-api/getting-started-with-the-rest-api
📖
Documentation
https://docs.github.com/en/rest/teams
📖
Documentation
https://docs.github.com/en/rest/meta/meta
📖
Documentation
https://docs.github.com/en/rest/actions
📖
Documentation
https://docs.github.com/en/rest/branches
📖
Documentation
https://docs.github.com/en/rest/code-scanning
📖
Documentation
https://docs.github.com/en/rest/collaborators
📖
Documentation
https://docs.github.com/en/rest/dependabot
📖
Documentation
https://docs.github.com/en/rest/webhooks
📖
Documentation
https://docs.github.com/en/rest/pulls
📖
Documentation
https://docs.github.com/en/rest/git/tags
📖
Documentation
https://docs.github.com/en/rest/repos/autolinks
📖
Documentation
https://docs.github.com/en/rest/collaborators/invitations

Specifications

Other Resources

OpenAPI Specification

github-statuses-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: 1.1.4
  title: github-repos-api Statuses API
  description: 'Use the REST API to create, manage and control the workflow of public and

    private GitHub repositories.'
  license:
    name: MIT
    url: https://spdx.org/licenses/MIT
  termsOfService: https://docs.github.com/articles/github-terms-of-service
  contact:
    name: Support
    url: https://support.github.com/contact
servers:
- url: '{protocol}://{hostname}'
  variables:
    hostname:
      description: Self-hosted Enterprise Server hostname
      default: api.github.com
    protocol:
      description: Self-hosted Enterprise Server protocol
      default: https
tags:
- name: Statuses
paths:
  /repos/{owner}/{repo}/commits/{ref}/statuses:
    get:
      summary: GitHub List Commit Statuses for Reference
      description: 'Users with pull access in a repository can view commit statuses for a given ref. The ref can be a SHA, a branch name, or a tag name. Statuses are returned in reverse chronological order. The first status in the list will be the latest one.


        This resource is also available via a legacy route: `GET /repos/:owner/:repo/statuses/:ref`.'
      tags:
      - Statuses
      operationId: listCommitStatusesForReference
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/commits/statuses#list-commit-statuses-for-a-reference
      parameters:
      - $ref: '#/components/parameters/owner'
      - $ref: '#/components/parameters/repo'
      - $ref: '#/components/parameters/commit-ref'
      - $ref: '#/components/parameters/per-page'
      - $ref: '#/components/parameters/page'
      - in: header
        name: Authorization
        schema:
          type: string
        example: example_value
      - in: header
        name: X-GitHub-Api-Version
        schema:
          type: string
          default: '2022-11-28'
        example: example_value
      - in: header
        name: Accept
        schema:
          type: string
          default: application/vnd.github+json
        example: example_value
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/status'
              examples:
                default:
                  $ref: '#/components/examples/status-items'
          headers:
            Link:
              $ref: '#/components/headers/link'
        '301':
          $ref: '#/components/responses/moved_permanently'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: true
        category: commits
        subcategory: statuses
      security:
      - bearerHttpAuthentication: []
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /repos/{owner}/{repo}/deployments/{deployment_id}/statuses:
    get:
      summary: GitHub List Deployment Statuses
      description: 'Users with pull access can view deployment statuses for a deployment:'
      tags:
      - Statuses
      operationId: listDeploymentStatuses
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/deployments/statuses#list-deployment-statuses
      parameters:
      - $ref: '#/components/parameters/owner'
      - $ref: '#/components/parameters/repo'
      - $ref: '#/components/parameters/deployment-id'
      - $ref: '#/components/parameters/per-page'
      - $ref: '#/components/parameters/page'
      - in: header
        name: Authorization
        schema:
          type: string
        example: example_value
      - in: header
        name: X-GitHub-Api-Version
        schema:
          type: string
          default: '2022-11-28'
        example: example_value
      - in: header
        name: Accept
        schema:
          type: string
          default: application/vnd.github+json
        example: example_value
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/deployment-status'
              examples:
                default:
                  $ref: '#/components/examples/deployment-status-items'
          headers:
            Link:
              $ref: '#/components/headers/link'
        '404':
          $ref: '#/components/responses/not_found'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: true
        category: deployments
        subcategory: statuses
      security:
      - bearerHttpAuthentication: []
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  parameters:
    repo:
      name: repo
      description: The name of the repository without the `.git` extension. The name is not case sensitive.
      in: path
      required: true
      schema:
        type: string
    deployment-id:
      name: deployment_id
      description: deployment_id parameter
      in: path
      required: true
      schema:
        type: integer
    commit-ref:
      name: ref
      description: The commit reference. Can be a commit SHA, branch name (`heads/BRANCH_NAME`), or tag name (`tags/TAG_NAME`). For more information, see "[Git References](https://git-scm.com/book/en/v2/Git-Internals-Git-References)" in the Git documentation.
      in: path
      required: true
      schema:
        type: string
      x-multi-segment: true
    per-page:
      name: per_page
      description: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
      in: query
      schema:
        type: integer
        default: 30
    owner:
      name: owner
      description: The account owner of the repository. The name is not case sensitive.
      in: path
      required: true
      schema:
        type: string
    page:
      name: page
      description: The page number of the results to fetch. For more information, see "[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
      in: query
      schema:
        type: integer
        default: 1
  schemas:
    nullable-integration:
      title: GitHub app
      description: GitHub apps are a new way to extend GitHub. They can be installed directly on organizations and user accounts and granted access to specific repositories. They come with granular permissions and built-in webhooks. GitHub apps are first class actors within GitHub.
      type: object
      properties:
        id:
          description: Unique identifier of the GitHub app
          example: 37
          type: integer
        slug:
          description: The slug name of the GitHub app
          example: probot-owners
          type: string
        node_id:
          type: string
          example: MDExOkludGVncmF0aW9uMQ==
        owner:
          $ref: '#/components/schemas/nullable-simple-user'
        name:
          description: The name of the GitHub app
          example: Probot Owners
          type: string
        description:
          type: string
          example: The description of the app.
        external_url:
          type: string
          format: uri
          example: https://example.com
        html_url:
          type: string
          format: uri
          example: https://github.com/apps/super-ci
        created_at:
          type: string
          format: date-time
          example: '2017-07-08T16:18:44-04:00'
        updated_at:
          type: string
          format: date-time
          example: '2017-07-08T16:18:44-04:00'
        permissions:
          description: The set of permissions for the GitHub app
          type: object
          properties:
            issues:
              type: string
            checks:
              type: string
            metadata:
              type: string
            contents:
              type: string
            deployments:
              type: string
          additionalProperties:
            type: string
          example:
            issues: read
            deployments: write
        events:
          description: The list of events for the GitHub app
          example:
          - label
          - deployment
          type: array
          items:
            type: string
        installations_count:
          description: The number of installations associated with the GitHub app
          example: 5
          type: integer
        client_id:
          type: string
          example: '"Iv1.25b5d1e65ffc4022"'
        client_secret:
          type: string
          example: '"1d4b2097ac622ba702d19de498f005747a8b21d3"'
        webhook_secret:
          type: string
          example: '"6fba8f2fc8a7e8f2cca5577eddd82ca7586b3b6b"'
        pem:
          type: string
          example: '"REDACTED_PRIVATE_KEY_EXAMPLE\n"'
      required:
      - id
      - node_id
      - owner
      - name
      - description
      - external_url
      - html_url
      - created_at
      - updated_at
      - permissions
      - events
    status:
      title: Status
      description: The status of a commit.
      type: object
      properties:
        url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World
        avatar_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World
        id:
          type: integer
          example: 42
        node_id:
          type: string
          example: '12345678'
        state:
          type: string
          example: open
        description:
          type: string
          example: This is an example repository
        target_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World
        context:
          type: string
          example: example_value
        created_at:
          type: string
          example: '2026-04-17T12:00:00Z'
        updated_at:
          type: string
          example: '2026-04-17T12:00:00Z'
        creator:
          $ref: '#/components/schemas/nullable-simple-user'
      required:
      - url
      - avatar_url
      - id
      - node_id
      - state
      - description
      - target_url
      - context
      - created_at
      - updated_at
      - creator
    basic-error:
      title: Basic Error
      description: Basic Error
      type: object
      properties:
        message:
          type: string
          example: Example body text
        documentation_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World
        url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World
        status:
          type: string
          example: open
    deployment-status:
      title: Deployment Status
      description: The status of a deployment.
      type: object
      properties:
        url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/example/deployments/42/statuses/1
        id:
          type: integer
          format: int64
          example: 1
        node_id:
          type: string
          example: MDE2OkRlcGxveW1lbnRTdGF0dXMx
        state:
          description: The state of the status.
          enum:
          - error
          - failure
          - inactive
          - pending
          - success
          - queued
          - in_progress
          example: success
          type: string
        creator:
          $ref: '#/components/schemas/nullable-simple-user'
        description:
          description: short description of the status.
          default: ''
          type: string
          maxLength: 140
          example: Deployment finished successfully.
        environment:
          description: The environment of the deployment that the status is for.
          default: ''
          type: string
          example: production
        target_url:
          description: 'Deprecated: the URL to associate with this status.'
          default: https://example.com/deployment/42/output
          type: string
          format: uri
          example: https://example.com/deployment/42/output
        created_at:
          type: string
          format: date-time
          example: '2012-07-20T01:19:13Z'
        updated_at:
          type: string
          format: date-time
          example: '2012-07-20T01:19:13Z'
        deployment_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/example/deployments/42
        repository_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/example
        environment_url:
          description: The URL for accessing your environment.
          default: https://staging.example.com/
          type: string
          format: uri
          example: https://staging.example.com/
        log_url:
          description: The URL to associate with this status.
          default: https://example.com/deployment/42/output
          type: string
          format: uri
          example: https://example.com/deployment/42/output
        performed_via_github_app:
          $ref: '#/components/schemas/nullable-integration'
      required:
      - id
      - node_id
      - state
      - creator
      - description
      - deployment_url
      - target_url
      - repository_url
      - url
      - created_at
      - updated_at
    nullable-simple-user:
      title: Simple User
      description: GitHub user.
      type: object
      properties:
        name:
          type: string
          example: octocat
        email:
          type: string
          example: octocat@github.com
        login:
          type: string
          example: octocat
        id:
          type: integer
          format: int64
          example: 1
        node_id:
          type: string
          example: MDQ6VXNlcjE=
        avatar_url:
          type: string
          format: uri
          example: https://github.com/images/error/octocat_happy.gif
        gravatar_id:
          type: string
          example: 41d064eb2195891e12d0413f63227ea7
        url:
          type: string
          format: uri
          example: https://api.github.com/users/octocat
        html_url:
          type: string
          format: uri
          example: https://github.com/octocat
        followers_url:
          type: string
          format: uri
          example: https://api.github.com/users/octocat/followers
        following_url:
          type: string
          example: https://api.github.com/users/octocat/following{/other_user}
        gists_url:
          type: string
          example: https://api.github.com/users/octocat/gists{/gist_id}
        starred_url:
          type: string
          example: https://api.github.com/users/octocat/starred{/owner}{/repo}
        subscriptions_url:
          type: string
          format: uri
          example: https://api.github.com/users/octocat/subscriptions
        organizations_url:
          type: string
          format: uri
          example: https://api.github.com/users/octocat/orgs
        repos_url:
          type: string
          format: uri
          example: https://api.github.com/users/octocat/repos
        events_url:
          type: string
          example: https://api.github.com/users/octocat/events{/privacy}
        received_events_url:
          type: string
          format: uri
          example: https://api.github.com/users/octocat/received_events
        type:
          type: string
          example: User
        site_admin:
          type: boolean
          example: true
        starred_at:
          type: string
          example: '"2020-07-09T00:17:55Z"'
      required:
      - avatar_url
      - events_url
      - followers_url
      - following_url
      - gists_url
      - gravatar_id
      - html_url
      - id
      - node_id
      - login
      - organizations_url
      - received_events_url
      - repos_url
      - site_admin
      - starred_url
      - subscriptions_url
      - type
      - url
  responses:
    moved_permanently:
      description: Moved permanently
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/basic-error'
    not_found:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/basic-error'
  examples:
    deployment-status-items:
      value:
      - url: https://api.github.com/repos/octocat/example/deployments/42/statuses/1
        id: 1
        node_id: MDE2OkRlcGxveW1lbnRTdGF0dXMx
        state: success
        creator:
          login: octocat
          id: 1
          node_id: MDQ6VXNlcjE=
          avatar_url: https://github.com/images/error/octocat_happy.gif
          gravatar_id: ''
          url: https://api.github.com/users/octocat
          html_url: https://github.com/octocat
          followers_url: https://api.github.com/users/octocat/followers
          following_url: https://api.github.com/users/octocat/following{/other_user}
          gists_url: https://api.github.com/users/octocat/gists{/gist_id}
          starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo}
          subscriptions_url: https://api.github.com/users/octocat/subscriptions
          organizations_url: https://api.github.com/users/octocat/orgs
          repos_url: https://api.github.com/users/octocat/repos
          events_url: https://api.github.com/users/octocat/events{/privacy}
          received_events_url: https://api.github.com/users/octocat/received_events
          type: User
          site_admin: false
        description: Deployment finished successfully.
        environment: production
        target_url: https://example.com/deployment/42/output
        created_at: '2012-07-20T01:19:13Z'
        updated_at: '2012-07-20T01:19:13Z'
        deployment_url: https://api.github.com/repos/octocat/example/deployments/42
        repository_url: https://api.github.com/repos/octocat/example
        environment_url: https://test-branch.lab.acme.com
        log_url: https://example.com/deployment/42/output
    status-items:
      value:
      - url: https://api.github.com/repos/octocat/Hello-World/statuses/6dcb09b5b57875f334f61aebed695e2e4193db5e
        avatar_url: https://github.com/images/error/hubot_happy.gif
        id: 1
        node_id: MDY6U3RhdHVzMQ==
        state: success
        description: Build has completed successfully
        target_url: https://ci.example.com/1000/output
        context: continuous-integration/jenkins
        created_at: '2012-07-20T01:19:13Z'
        updated_at: '2012-07-20T01:19:13Z'
        creator:
          login: octocat
          id: 1
          node_id: MDQ6VXNlcjE=
          avatar_url: https://github.com/images/error/octocat_happy.gif
          gravatar_id: ''
          url: https://api.github.com/users/octocat
          html_url: https://github.com/octocat
          followers_url: https://api.github.com/users/octocat/followers
          following_url: https://api.github.com/users/octocat/following{/other_user}
          gists_url: https://api.github.com/users/octocat/gists{/gist_id}
          starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo}
          subscriptions_url: https://api.github.com/users/octocat/subscriptions
          organizations_url: https://api.github.com/users/octocat/orgs
          repos_url: https://api.github.com/users/octocat/repos
          events_url: https://api.github.com/users/octocat/events{/privacy}
          received_events_url: https://api.github.com/users/octocat/received_events
          type: User
          site_admin: false
  headers:
    link:
      example: <https://api.github.com/resource?page=2>; rel="next", <https://api.github.com/resource?page=5>; rel="last"
      schema:
        type: string
  securitySchemes:
    bearerHttpAuthentication:
      description: Bearer Token
      type: http
      scheme: Bearer
externalDocs:
  description: GitHub Enterprise Developer Docs
  url: https://docs.github.com/enterprise-server@3.9/rest/