GitHub Secret-Scanning API

Retrieve secret scanning alerts from a repository.

Operations 6

GET /enterprises/{enterprise}/secret-scanning/alerts GitHub List Secret Scanning Alerts for an Enterprise #
GET /orgs/{org}/secret-scanning/alerts GitHub List Secret Scanning Alerts for an Organization #
GET /repos/{owner}/{repo}/secret-scanning/alerts GitHub List Secret Scanning Alerts for a Repository #
GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number} GitHub Get a Secret Scanning Alert #
PATCH /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number} GitHub Update a Secret Scanning Alert #
GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations GitHub List Locations for a Secret Scanning Alert #

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

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/github-secret-scanning-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

github-secret-scanning-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: 1.1.4
  title: GitHub v3 REST Secret Scanning API
  description: GitHub's v3 REST API.
  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?tags=dotcom-rest-api
  x-github-plan: ghes
  x-github-release: 3.9
servers:
- url: '{protocol}://{hostname}/api/v3'
  variables:
    hostname:
      description: Self-hosted Enterprise Server hostname
      default: HOSTNAME
    protocol:
      description: Self-hosted Enterprise Server protocol
      default: http
tags:
- name: Secret-Scanning
  description: Retrieve secret scanning alerts from a repository.
paths:
  /enterprises/{enterprise}/secret-scanning/alerts:
    get:
      summary: GitHub List Secret Scanning Alerts for an Enterprise
      description: 'Lists secret scanning alerts for eligible repositories in an enterprise, from newest to oldest.

        To use this endpoint, you must be a member of the enterprise, and you must use an access token with the `repo` scope or `security_events` scope. Alerts are only returned for organizations in the enterprise for which you are an organization owner or a [security manager](https://docs.github.com/enterprise-server@3.9/organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).'
      tags:
      - Secret-Scanning
      operationId: secret-scanning/list-alerts-for-enterprise
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/secret-scanning/secret-scanning#list-secret-scanning-alerts-for-an-enterprise
      parameters:
      - $ref: '#/components/parameters/enterprise'
      - $ref: '#/components/parameters/secret-scanning-alert-state'
      - $ref: '#/components/parameters/secret-scanning-alert-secret-type'
      - $ref: '#/components/parameters/secret-scanning-alert-resolution'
      - $ref: '#/components/parameters/secret-scanning-alert-sort'
      - $ref: '#/components/parameters/direction'
      - $ref: '#/components/parameters/per-page'
      - $ref: '#/components/parameters/pagination-before'
      - $ref: '#/components/parameters/pagination-after'
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/organization-secret-scanning-alert'
              examples:
                default:
                  $ref: '#/components/examples/organization-secret-scanning-alert-list'
          headers:
            Link:
              $ref: '#/components/headers/link'
        '404':
          $ref: '#/components/responses/not_found'
        '503':
          $ref: '#/components/responses/service_unavailable'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: false
        category: secret-scanning
        subcategory: secret-scanning
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /orgs/{org}/secret-scanning/alerts:
    get:
      summary: GitHub List Secret Scanning Alerts for an Organization
      description: 'Lists secret scanning alerts for eligible repositories in an organization, from newest to oldest.


        The authenticated user must be an administrator or security manager for the organization to use this endpoint.


        OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.'
      tags:
      - Secret-Scanning
      operationId: secret-scanning/list-alerts-for-org
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/secret-scanning/secret-scanning#list-secret-scanning-alerts-for-an-organization
      parameters:
      - $ref: '#/components/parameters/org'
      - $ref: '#/components/parameters/secret-scanning-alert-state'
      - $ref: '#/components/parameters/secret-scanning-alert-secret-type'
      - $ref: '#/components/parameters/secret-scanning-alert-resolution'
      - $ref: '#/components/parameters/secret-scanning-alert-sort'
      - $ref: '#/components/parameters/direction'
      - $ref: '#/components/parameters/page'
      - $ref: '#/components/parameters/per-page'
      - $ref: '#/components/parameters/secret-scanning-pagination-before-org-repo'
      - $ref: '#/components/parameters/secret-scanning-pagination-after-org-repo'
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/organization-secret-scanning-alert'
              examples:
                default:
                  $ref: '#/components/examples/organization-secret-scanning-alert-list'
          headers:
            Link:
              $ref: '#/components/headers/link'
        '404':
          $ref: '#/components/responses/not_found'
        '503':
          $ref: '#/components/responses/service_unavailable'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: true
        category: secret-scanning
        subcategory: secret-scanning
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /repos/{owner}/{repo}/secret-scanning/alerts:
    get:
      summary: GitHub List Secret Scanning Alerts for a Repository
      description: 'Lists secret scanning alerts for an eligible repository, from newest to oldest.


        The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.


        OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.'
      tags:
      - Secret-Scanning
      operationId: secret-scanning/list-alerts-for-repo
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/secret-scanning/secret-scanning#list-secret-scanning-alerts-for-a-repository
      parameters:
      - $ref: '#/components/parameters/owner'
      - $ref: '#/components/parameters/repo'
      - $ref: '#/components/parameters/secret-scanning-alert-state'
      - $ref: '#/components/parameters/secret-scanning-alert-secret-type'
      - $ref: '#/components/parameters/secret-scanning-alert-resolution'
      - $ref: '#/components/parameters/secret-scanning-alert-sort'
      - $ref: '#/components/parameters/direction'
      - $ref: '#/components/parameters/page'
      - $ref: '#/components/parameters/per-page'
      - $ref: '#/components/parameters/secret-scanning-pagination-before-org-repo'
      - $ref: '#/components/parameters/secret-scanning-pagination-after-org-repo'
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/secret-scanning-alert'
              examples:
                default:
                  $ref: '#/components/examples/secret-scanning-alert-list'
        '404':
          description: Repository is public or secret scanning is disabled for the repository
        '503':
          $ref: '#/components/responses/service_unavailable'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: true
        category: secret-scanning
        subcategory: secret-scanning
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}:
    get:
      summary: GitHub Get a Secret Scanning Alert
      description: 'Gets a single secret scanning alert detected in an eligible repository.


        The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.


        OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.'
      tags:
      - Secret-Scanning
      operationId: secret-scanning/get-alert
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/secret-scanning/secret-scanning#get-a-secret-scanning-alert
      parameters:
      - $ref: '#/components/parameters/owner'
      - $ref: '#/components/parameters/repo'
      - $ref: '#/components/parameters/alert-number'
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/secret-scanning-alert'
              examples:
                default:
                  $ref: '#/components/examples/secret-scanning-alert-open'
        '304':
          $ref: '#/components/responses/not_modified'
        '404':
          description: Repository is public, or secret scanning is disabled for the repository, or the resource is not found
        '503':
          $ref: '#/components/responses/service_unavailable'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: true
        category: secret-scanning
        subcategory: secret-scanning
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    patch:
      summary: GitHub Update a Secret Scanning Alert
      description: 'Updates the status of a secret scanning alert in an eligible repository.


        The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.


        OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.'
      operationId: secret-scanning/update-alert
      tags:
      - Secret-Scanning
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/secret-scanning/secret-scanning#update-a-secret-scanning-alert
      parameters:
      - $ref: '#/components/parameters/owner'
      - $ref: '#/components/parameters/repo'
      - $ref: '#/components/parameters/alert-number'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                state:
                  $ref: '#/components/schemas/secret-scanning-alert-state'
                resolution:
                  $ref: '#/components/schemas/secret-scanning-alert-resolution'
                resolution_comment:
                  $ref: '#/components/schemas/secret-scanning-alert-resolution-comment'
              required:
              - state
            examples:
              default:
                value:
                  state: resolved
                  resolution: false_positive
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/secret-scanning-alert'
              examples:
                default:
                  $ref: '#/components/examples/secret-scanning-alert-resolved'
        '400':
          description: Bad request, resolution comment is invalid or the resolution was not changed.
        '404':
          description: Repository is public, or secret scanning is disabled for the repository, or the resource is not found
        '422':
          description: State does not match the resolution or resolution comment
        '503':
          $ref: '#/components/responses/service_unavailable'
      x-github:
        enabledForGitHubApps: true
        githubCloudOnly: false
        category: secret-scanning
        subcategory: secret-scanning
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations:
    get:
      summary: GitHub List Locations for a Secret Scanning Alert
      description: 'Lists all locations for a given secret scanning alert for an eligible repository.


        The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.


        OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.'
      tags:
      - Secret-Scanning
      operationId: secret-scanning/list-locations-for-alert
      externalDocs:
        description: API method documentation
        url: https://docs.github.com/enterprise-server@3.9/rest/secret-scanning/secret-scanning#list-locations-for-a-secret-scanning-alert
      parameters:
      - $ref: '#/components/parameters/owner'
      - $ref: '#/components/parameters/repo'
      - $ref: '#/components/parameters/alert-number'
      - $ref: '#/components/parameters/page'
      - $ref: '#/components/parameters/per-page'
      responses:
        '200':
          description: Response
          content:
            application/json:
              schema:
                type: array
                description: List of locations where the secret was detected
                items:
                  $ref: '#/components/schemas/secret-scanning-location'
              examples:
                default:
                  $ref: '#/components/examples/secret-scanning-location-list'
          headers:
            Link:
              $ref: '#/components/headers/link'
        '404':
          description: Repository is public, or secret scanning is disabled for the repository, or the resource is not found
        '503':
          $ref: '#/components/responses/service_unavailable'
      x-github:
        githubCloudOnly: false
        enabledForGitHubApps: true
        category: secret-scanning
        subcategory: secret-scanning
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    simple-repository:
      title: Simple Repository
      description: A GitHub repository.
      type: object
      properties:
        id:
          type: integer
          example: 1296269
          description: A unique identifier of the repository.
        node_id:
          type: string
          example: MDEwOlJlcG9zaXRvcnkxMjk2MjY5
          description: The GraphQL identifier of the repository.
        name:
          type: string
          example: Hello-World
          description: The name of the repository.
        full_name:
          type: string
          example: octocat/Hello-World
          description: The full, globally unique, name of the repository.
        owner:
          $ref: '#/components/schemas/simple-user'
        private:
          type: boolean
          description: Whether the repository is private.
          example: true
        html_url:
          type: string
          format: uri
          example: https://github.com/octocat/Hello-World
          description: The URL to view the repository on GitHub.com.
        description:
          type:
          - string
          - 'null'
          example: This your first repo!
          description: The repository description.
        fork:
          type: boolean
          description: Whether the repository is a fork.
          example: true
        url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World
          description: The URL to get more information about the repository from the GitHub API.
        archive_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/{archive_format}{/ref}
          description: A template for the API URL to download the repository as an archive.
        assignees_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/assignees{/user}
          description: A template for the API URL to list the available assignees for issues in the repository.
        blobs_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/git/blobs{/sha}
          description: A template for the API URL to create or retrieve a raw Git blob in the repository.
        branches_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/branches{/branch}
          description: A template for the API URL to get information about branches in the repository.
        collaborators_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/collaborators{/collaborator}
          description: A template for the API URL to get information about collaborators of the repository.
        comments_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/comments{/number}
          description: A template for the API URL to get information about comments on the repository.
        commits_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/commits{/sha}
          description: A template for the API URL to get information about commits on the repository.
        compare_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/compare/{base}...{head}
          description: A template for the API URL to compare two commits or refs.
        contents_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/contents/{+path}
          description: A template for the API URL to get the contents of the repository.
        contributors_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/contributors
          description: A template for the API URL to list the contributors to the repository.
        deployments_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/deployments
          description: The API URL to list the deployments of the repository.
        downloads_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/downloads
          description: The API URL to list the downloads on the repository.
        events_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/events
          description: The API URL to list the events of the repository.
        forks_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/forks
          description: The API URL to list the forks of the repository.
        git_commits_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/git/commits{/sha}
          description: A template for the API URL to get information about Git commits of the repository.
        git_refs_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/git/refs{/sha}
          description: A template for the API URL to get information about Git refs of the repository.
        git_tags_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/git/tags{/sha}
          description: A template for the API URL to get information about Git tags of the repository.
        issue_comment_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/issues/comments{/number}
          description: A template for the API URL to get information about issue comments on the repository.
        issue_events_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/issues/events{/number}
          description: A template for the API URL to get information about issue events on the repository.
        issues_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/issues{/number}
          description: A template for the API URL to get information about issues on the repository.
        keys_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/keys{/key_id}
          description: A template for the API URL to get information about deploy keys on the repository.
        labels_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/labels{/name}
          description: A template for the API URL to get information about labels of the repository.
        languages_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/languages
          description: The API URL to get information about the languages of the repository.
        merges_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/merges
          description: The API URL to merge branches in the repository.
        milestones_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/milestones{/number}
          description: A template for the API URL to get information about milestones of the repository.
        notifications_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/notifications{?since,all,participating}
          description: A template for the API URL to get information about notifications on the repository.
        pulls_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/pulls{/number}
          description: A template for the API URL to get information about pull requests on the repository.
        releases_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/releases{/id}
          description: A template for the API URL to get information about releases on the repository.
        stargazers_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/stargazers
          description: The API URL to list the stargazers on the repository.
        statuses_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/statuses/{sha}
          description: A template for the API URL to get information about statuses of a commit.
        subscribers_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/subscribers
          description: The API URL to list the subscribers on the repository.
        subscription_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/subscription
          description: The API URL to subscribe to notifications for this repository.
        tags_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/tags
          description: The API URL to get information about tags on the repository.
        teams_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/teams
          description: The API URL to list the teams on the repository.
        trees_url:
          type: string
          example: https://api.github.com/repos/octocat/Hello-World/git/trees{/sha}
          description: A template for the API URL to create or retrieve a raw Git tree of the repository.
        hooks_url:
          type: string
          format: uri
          example: https://api.github.com/repos/octocat/Hello-World/hooks
          description: The API URL to list the hooks on the repository.
      required:
      - archive_url
      - assignees_url
      - blobs_url
      - branches_url
      - collaborators_url
      - comments_url
      - commits_url
      - compare_url
      - contents_url
      - contributors_url
      - deployments_url
      - description
      - downloads_url
      - events_url
      - fork
      - forks_url
      - full_name
      - git_commits_url
      - git_refs_url
      - git_tags_url
      - hooks_url
      - html_url
      - id
      - node_id
      - issue_comment_url
      - issue_events_url
      - issues_url
      - keys_url
      - labels_url
      - languages_url
      - merges_url
      - milestones_url
      - name
      - notifications_url
      - owner
      - private
      - pulls_url
      - releases_url
      - stargazers_url
      - statuses_url
      - subscribers_url
      - subscription_url
      - tags_url
      - teams_url
      - trees_url
      - url
    nullable-simple-user:
      title: Simple User
      description: A GitHub user.
      type:
      - object
      - 'null'
      properties:
        name:
          type:
          - string
          - 'null'
          example: octocat
        email:
          type:
          - string
          - 'null'
          example: octocat@github.com
        login:
          type: string
          example: octocat
        id:
          type: integer
          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
          - 'null'
          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
    secret-scanning-location-pull-request-body:
      description: Represents a 'pull_request_body' secret scanning location type. This location type shows that a secret was detected in the body of a pull request.
      type: object
      properties:
        pull_request_body_url:
          type: string
          format: uri
          description: The API URL to get the pull request where the secret was detected.
          example: https://api.github.com/repos/octocat/Hello-World/pull/2846
      required:
      - pull_request_body_url
    secret-scanning-location-pull-request-title:
      description: Represents a 'pull_request_title' secret scanning location type. This location type shows that a secret was detected in the title of a pull request.
      type: object
      properties:
        pull_request_title_url:
          type: string
          format: uri
          description: The API URL to get the pull request where the secret was detected.
          example: https://api.github.com/repos/octocat/Hello-World/pull/2846
      required:
      - pull_request_title_url
    alert-url:
      type: string
      description: The REST API URL of the alert resource.
      format: uri
      readOnly: true
    secret-scanning-location-discussion-body:
      description: Represents a 'discussion_body' secret scanning location type. This location type shows that a secret was detected in the body of a discussion.
      type: object
      properties:
        discussion_body_url:
          type: string
          format: uri
          description: The URL to the discussion where the secret was detected.
          example: https://github.com/community/community/discussions/39082#discussion-4566270
      required:
      - discussion_body_url
    alert-html-url:
      type: string
      description: The GitHub URL of the alert resource.
      format: uri
      readOnly: true
    secret-scanning-alert-state:
      description: Sets the state of the secret scanning alert. You must provide `resolution` when you set the state to `resolved`.
      type: string
      enum:
      - open
      - resolved
    alert-number:
      type: integer
      description: The security alert number.
      readOnly: true
    alert-created-at:
      type: string
      description: 'The time that the alert was created in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`.'
      format: date-time
      readOnly: true
    simple-user:
      title: Simple User
      description: A GitHub user.
      type: object
      properties:
        name:
          type:
          - string
          - 'null'
          example: octocat
        email:
          type:
          - string
          - 'null'
          example: octocat@github.com
        login:
          type: string
          example: octocat
        id:
          type: integer
          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
          - 'null'
          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: ht

# --- truncated at 32 KB (73 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/github/refs/heads/main/openapi/github-secret-scanning-api-openapi.yml