OIDC Authentication

Exchange the ID token of a GitHub Actions job for a Mergify OIDC CI token, write the trust policies that allow it, and read the exchanges.


List the organization's trust policies #

GET /ci/{owner}/oidc/trust-policies

Every trust policy of the organization. A CI job gets a Mergify OIDC CI token from its ID token when one of them matches it.

Application key permission: oidc_trust_policies: read.

Application Key Admin Application Key Mergify User Token
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

200 Successful Response
trust_policiesobject (1 types)[]required
Discriminated by provider — 1 types
github_actionsGitHubActionsTrustPolicy
namestringrequired
min length: 1 · max length: 255
providerstringrequired
repositoriesobject (4 types)
Discriminated by mode — 4 types
allAllRepositories
modestringrequired

Every repository Mergify's GitHub App can access, new ones included as they are added.

all_exceptPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

onlyPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

visibilityRepositoriesByVisibility
modestringrequired

Every repository Mergify's GitHub App can access whose visibility is one of visibilities, new ones included as they are added.

visibilities("public" | "internal" | "private")[]required

The visibilities, matched against the visibility of the job's repository when the job exchanges its ID token: for a GitHub Actions job, the one its ID token gives. A job whose repository's visibility is not known then is not matched.

conditionsGitHubActionsConditions-Output

The job's events, workflows and environments.

eventsstring | string[]

The job's event_name, or any.

workflowsstring | (OwnRepositoryWorkflow | ReusableWorkflow-Output)[]

The workflow the job runs, or any.

environmentsstring | string[]

The job's environment, or any, which includes a job that runs in none.

permissionsobject

What the token of a job it matches may do on the job's own repository, resource by resource, as an application key's permissions: read, or write, which includes read. * gives its level on every resource but ci_reporting. A job several policies match gets what each of them grants. Only an organization admin, signed in as themselves, writes a policy granting more than ci_reporting.

idstring <uuid>required
created_byActorrequired

Who wrote the policy.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
created_atstring <date-time>required
updated_byActor | nullrequired

Who last edited the policy, if anyone did.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
updated_atstring <date-time> | nullrequired
last_used_atstring <date-time> | nullrequired

When the policy last allowed a job, to the minute.

Example Response
                        {
  "trust_policies": [
    {
      "name": "string",
      "provider": "github_actions",
      "repositories": {},
      "conditions": {},
      "permissions": {},
      "id": "string",
      "created_by": {},
      "created_at": "2024-01-15T09:00:00Z",
      "updated_by": {},
      "updated_at": "2024-01-15T09:00:00Z",
      "last_used_at": "2024-01-15T09:00:00Z"
    }
  ]
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 Not found
409 Conflict
422 Unprocessable entity
Example Request
curl -X GET "https://api.mergify.com/v1/ci/:owner/oidc/trust-policies" \
  -H "Authorization: Bearer <token>"

Create a trust policy #

POST /ci/{owner}/oidc/trust-policies

Add a trust policy to the organization.

Application key permission: oidc_trust_policies: write.

Application Key Admin Application Key Mergify User Token
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

Discriminated by provider — 1 types
github_actionsGitHubActionsTrustPolicyRules
namestringrequired
min length: 1 · max length: 255
providerstringrequired
repositoriesobject (4 types)
Discriminated by mode — 4 types
allAllRepositories
modestringrequired

Every repository Mergify's GitHub App can access, new ones included as they are added.

all_exceptPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

onlyPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

visibilityRepositoriesByVisibility
modestringrequired

Every repository Mergify's GitHub App can access whose visibility is one of visibilities, new ones included as they are added.

visibilities("public" | "internal" | "private")[]required

The visibilities, matched against the visibility of the job's repository when the job exchanges its ID token: for a GitHub Actions job, the one its ID token gives. A job whose repository's visibility is not known then is not matched.

conditionsGitHubActionsConditions-Input

The job's events, workflows and environments.

eventsstring | string[]

The job's event_name, or any.

workflowsstring | (OwnRepositoryWorkflow | ReusableWorkflow-Input)[]

The workflow the job runs, or any.

environmentsstring | string[]

The job's environment, or any, which includes a job that runs in none.

permissionsobject

What the token of a job it matches may do on the job's own repository, resource by resource, as an application key's permissions: read, or write, which includes read. * gives its level on every resource but ci_reporting. A job several policies match gets what each of them grants. Only an organization admin, signed in as themselves, writes a policy granting more than ci_reporting.

201 Successful Response
Discriminated by provider — 1 types
github_actionsGitHubActionsTrustPolicy
namestringrequired
min length: 1 · max length: 255
providerstringrequired
repositoriesobject (4 types)
Discriminated by mode — 4 types
allAllRepositories
modestringrequired

Every repository Mergify's GitHub App can access, new ones included as they are added.

all_exceptPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

onlyPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

visibilityRepositoriesByVisibility
modestringrequired

Every repository Mergify's GitHub App can access whose visibility is one of visibilities, new ones included as they are added.

visibilities("public" | "internal" | "private")[]required

The visibilities, matched against the visibility of the job's repository when the job exchanges its ID token: for a GitHub Actions job, the one its ID token gives. A job whose repository's visibility is not known then is not matched.

conditionsGitHubActionsConditions-Output

The job's events, workflows and environments.

eventsstring | string[]

The job's event_name, or any.

workflowsstring | (OwnRepositoryWorkflow | ReusableWorkflow-Output)[]

The workflow the job runs, or any.

environmentsstring | string[]

The job's environment, or any, which includes a job that runs in none.

permissionsobject

What the token of a job it matches may do on the job's own repository, resource by resource, as an application key's permissions: read, or write, which includes read. * gives its level on every resource but ci_reporting. A job several policies match gets what each of them grants. Only an organization admin, signed in as themselves, writes a policy granting more than ci_reporting.

idstring <uuid>required
created_byActorrequired

Who wrote the policy.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
created_atstring <date-time>required
updated_byActor | nullrequired

Who last edited the policy, if anyone did.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
updated_atstring <date-time> | nullrequired
last_used_atstring <date-time> | nullrequired

When the policy last allowed a job, to the minute.

Example Response
                        {
  "name": "string",
  "provider": "github_actions",
  "repositories": {
    "mode": "all"
  },
  "conditions": {
    "events": "any",
    "workflows": "any",
    "environments": "any"
  },
  "permissions": {},
  "id": "string",
  "created_by": {
    "type": "application",
    "id": 0,
    "name": "string"
  },
  "created_at": "2024-01-15T09:00:00Z",
  "updated_by": {
    "type": "application",
    "id": 0,
    "name": "string"
  },
  "updated_at": "2024-01-15T09:00:00Z",
  "last_used_at": "2024-01-15T09:00:00Z"
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_TRUST_POLICY_GRANT_REFUSED: Only an organization admin, signed in as themselves, writes a trust policy that grants more than CI Reporting. A CI Admin or an application key writes the ones granting CI Reporting alone. CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 Not found
409 CI_TRUST_POLICY_NAME_TAKEN: Another trust policy of the organization has this name.

Body: APIErrorBody

422 CI_TRUST_POLICY_LIMIT_REACHED: The organization has as many trust policies as an organization can have. Widen an existing policy, or delete one, instead. CI_TRUST_POLICY_REPOSITORY_UNKNOWN: The policy names a repository Mergify's GitHub App cannot access in the organization. Name repositories the app is installed on, by their GitHub id.

Body: APIErrorBody

Example Request
curl -X POST "https://api.mergify.com/v1/ci/:owner/oidc/trust-policies" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "string",
  "provider": "github_actions",
  "repositories": {
    "mode": "all"
  },
  "conditions": {
    "events": "any",
    "workflows": "any",
    "environments": "any"
  },
  "permissions": {}
}'

Get a trust policy #

GET /ci/{owner}/oidc/trust-policies/{trust_policy_id}

One trust policy of the organization.

Application key permission: oidc_trust_policies: read.

Application Key Admin Application Key Mergify User Token
trust_policy_id string <uuid> required
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

200 Successful Response
Discriminated by provider — 1 types
github_actionsGitHubActionsTrustPolicy
namestringrequired
min length: 1 · max length: 255
providerstringrequired
repositoriesobject (4 types)
Discriminated by mode — 4 types
allAllRepositories
modestringrequired

Every repository Mergify's GitHub App can access, new ones included as they are added.

all_exceptPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

onlyPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

visibilityRepositoriesByVisibility
modestringrequired

Every repository Mergify's GitHub App can access whose visibility is one of visibilities, new ones included as they are added.

visibilities("public" | "internal" | "private")[]required

The visibilities, matched against the visibility of the job's repository when the job exchanges its ID token: for a GitHub Actions job, the one its ID token gives. A job whose repository's visibility is not known then is not matched.

conditionsGitHubActionsConditions-Output

The job's events, workflows and environments.

eventsstring | string[]

The job's event_name, or any.

workflowsstring | (OwnRepositoryWorkflow | ReusableWorkflow-Output)[]

The workflow the job runs, or any.

environmentsstring | string[]

The job's environment, or any, which includes a job that runs in none.

permissionsobject

What the token of a job it matches may do on the job's own repository, resource by resource, as an application key's permissions: read, or write, which includes read. * gives its level on every resource but ci_reporting. A job several policies match gets what each of them grants. Only an organization admin, signed in as themselves, writes a policy granting more than ci_reporting.

idstring <uuid>required
created_byActorrequired

Who wrote the policy.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
created_atstring <date-time>required
updated_byActor | nullrequired

Who last edited the policy, if anyone did.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
updated_atstring <date-time> | nullrequired
last_used_atstring <date-time> | nullrequired

When the policy last allowed a job, to the minute.

Example Response
                        {
  "name": "string",
  "provider": "github_actions",
  "repositories": {
    "mode": "all"
  },
  "conditions": {
    "events": "any",
    "workflows": "any",
    "environments": "any"
  },
  "permissions": {},
  "id": "string",
  "created_by": {
    "type": "application",
    "id": 0,
    "name": "string"
  },
  "created_at": "2024-01-15T09:00:00Z",
  "updated_by": {
    "type": "application",
    "id": 0,
    "name": "string"
  },
  "updated_at": "2024-01-15T09:00:00Z",
  "last_used_at": "2024-01-15T09:00:00Z"
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 CI_TRUST_POLICY_NOT_FOUND: The organization has no trust policy with this id.

Body: APIErrorBody

409 Conflict
422 Unprocessable entity
Example Request
curl -X GET "https://api.mergify.com/v1/ci/:owner/oidc/trust-policies/:trust_policy_id" \
  -H "Authorization: Bearer <token>"

Update a trust policy #

PATCH /ci/{owner}/oidc/trust-policies/{trust_policy_id}

Change what a trust policy matches or grants. A field left out keeps its value, and so does a line of conditions left out, save on a change of provider, which needs conditions. The tokens already issued keep what the policy granted until they expire, within the hour.

Application key permission: oidc_trust_policies: write.

Application Key Admin Application Key Mergify User Token
trust_policy_id string <uuid> required
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

namestring
min length: 1 · max length: 255
provider"github_actions"
Enum: github_actions
repositoriesobject (4 types) | null

The repositories whose jobs it matches. null: every one.

Discriminated by mode — 4 types
allAllRepositories
modestringrequired

Every repository Mergify's GitHub App can access, new ones included as they are added.

all_exceptPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

onlyPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

visibilityRepositoriesByVisibility
modestringrequired

Every repository Mergify's GitHub App can access whose visibility is one of visibilities, new ones included as they are added.

visibilities("public" | "internal" | "private")[]required

The visibilities, matched against the visibility of the job's repository when the job exchanges its ID token: for a GitHub Actions job, the one its ID token gives. A job whose repository's visibility is not known then is not matched.

conditionsGitHubActionsConditionsPatch | null

The lines of its provider: a GitHub Actions job's events, workflows and environments. null puts back the default of each. A change of provider needs it, since the lines of one provider mean nothing to another: the policy then takes the new provider's lines from it alone, a line it leaves out at its default.

eventsstring | string[] | null

The job's event_name, or any. null: the CI events.

workflowsstring | (OwnRepositoryWorkflow | ReusableWorkflow-Input)[] | null

The workflow the job runs, or any. null: any.

environmentsstring | string[] | null

The job's environment, or any, which includes a job that runs in none. null: any.

permissionsobject | null

What the token of a job it matches may do on the job's own repository, resource by resource, as an application key's permissions: read, or write, which includes read. * gives its level on every resource but ci_reporting. A job several policies match gets what each of them grants. Only an organization admin, signed in as themselves, writes a policy granting more than ci_reporting. null: ci_reporting alone.

200 Successful Response
Discriminated by provider — 1 types
github_actionsGitHubActionsTrustPolicy
namestringrequired
min length: 1 · max length: 255
providerstringrequired
repositoriesobject (4 types)
Discriminated by mode — 4 types
allAllRepositories
modestringrequired

Every repository Mergify's GitHub App can access, new ones included as they are added.

all_exceptPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

onlyPickedRepositories
mode"all_except" | "only"required

only the repositories listed, or all_except them, new ones included.

Enum: all_except only
idsinteger[]required

The ids of the repositories.

visibilityRepositoriesByVisibility
modestringrequired

Every repository Mergify's GitHub App can access whose visibility is one of visibilities, new ones included as they are added.

visibilities("public" | "internal" | "private")[]required

The visibilities, matched against the visibility of the job's repository when the job exchanges its ID token: for a GitHub Actions job, the one its ID token gives. A job whose repository's visibility is not known then is not matched.

conditionsGitHubActionsConditions-Output

The job's events, workflows and environments.

eventsstring | string[]

The job's event_name, or any.

workflowsstring | (OwnRepositoryWorkflow | ReusableWorkflow-Output)[]

The workflow the job runs, or any.

environmentsstring | string[]

The job's environment, or any, which includes a job that runs in none.

permissionsobject

What the token of a job it matches may do on the job's own repository, resource by resource, as an application key's permissions: read, or write, which includes read. * gives its level on every resource but ci_reporting. A job several policies match gets what each of them grants. Only an organization admin, signed in as themselves, writes a policy granting more than ci_reporting.

idstring <uuid>required
created_byActorrequired

Who wrote the policy.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
created_atstring <date-time>required
updated_byActor | nullrequired

Who last edited the policy, if anyone did.

type"application" | "user"required
Enum: application user
idinteger | string <uuid>required
namestringrequired
updated_atstring <date-time> | nullrequired
last_used_atstring <date-time> | nullrequired

When the policy last allowed a job, to the minute.

Example Response
                        {
  "name": "string",
  "provider": "github_actions",
  "repositories": {
    "mode": "all"
  },
  "conditions": {
    "events": "any",
    "workflows": "any",
    "environments": "any"
  },
  "permissions": {},
  "id": "string",
  "created_by": {
    "type": "application",
    "id": 0,
    "name": "string"
  },
  "created_at": "2024-01-15T09:00:00Z",
  "updated_by": {
    "type": "application",
    "id": 0,
    "name": "string"
  },
  "updated_at": "2024-01-15T09:00:00Z",
  "last_used_at": "2024-01-15T09:00:00Z"
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_TRUST_POLICY_GRANT_REFUSED: Only an organization admin, signed in as themselves, writes a trust policy that grants more than CI Reporting. A CI Admin or an application key writes the ones granting CI Reporting alone. CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 CI_TRUST_POLICY_NOT_FOUND: The organization has no trust policy with this id.

Body: APIErrorBody

409 CI_TRUST_POLICY_NAME_TAKEN: Another trust policy of the organization has this name.

Body: APIErrorBody

422 CI_TRUST_POLICY_REPOSITORY_UNKNOWN: The policy names a repository Mergify's GitHub App cannot access in the organization. Name repositories the app is installed on, by their GitHub id.

Body: APIErrorBody

Example Request
curl -X PATCH "https://api.mergify.com/v1/ci/:owner/oidc/trust-policies/:trust_policy_id" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "string",
  "provider": "github_actions",
  "repositories": {
    "mode": "all"
  },
  "conditions": {
    "events": "any",
    "workflows": "any",
    "environments": "any"
  },
  "permissions": {}
}'

Delete a trust policy #

DELETE /ci/{owner}/oidc/trust-policies/{trust_policy_id}

Delete a trust policy. The jobs only it allowed get no token from then on, and the tokens already issued expire within the hour.

Application key permission: oidc_trust_policies: write.

Application Key Admin Application Key Mergify User Token
trust_policy_id string <uuid> required
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

204 No content
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_TRUST_POLICY_GRANT_REFUSED: Only an organization admin, signed in as themselves, writes a trust policy that grants more than CI Reporting. A CI Admin or an application key writes the ones granting CI Reporting alone. CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 CI_TRUST_POLICY_NOT_FOUND: The organization has no trust policy with this id.

Body: APIErrorBody

409 Conflict
422 Unprocessable entity
Example Request
curl -X DELETE "https://api.mergify.com/v1/ci/:owner/oidc/trust-policies/:trust_policy_id" \
  -H "Authorization: Bearer <token>"

List the exchanges of the organization's CI jobs #

GET /ci/{owner}/oidc/exchanges

Each time a CI job of the organization traded its ID token for a Mergify OIDC CI token, or tried to, latest first: the policies that allowed it, or the reason it was refused. A token whose signature does not verify, or that expired, is not listed: nothing in it can be trusted to name the organization.

Application key permission: oidc_trust_policies: read.

Application Key Admin Application Key Mergify User Token
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

cursor string

The opaque cursor of the current page. Must be extracted from RFC 5988 pagination links to get the previous/next pages

per_page integer

The number of items per page

min: 1 · max: 100

outcome "allowed" | "refused"

Only the allowed, or the refused, exchanges.

repository_id integer

Only the exchanges of this repository.

min: -9223372036854776000 · max: 9223372036854776000

allowed_by_policy_id string <uuid>

Only the exchanges this policy allowed.

start string <date-time>

Start of the time range: an ISO 8601 datetime with a UTC offset (e.g. 2024-01-01T00:00:00Z); a Unix timestamp or a datetime without an offset is refused. Defaults to end - 1 day when omitted; a paginated response carries the resolved value in its Link header.

end string <date-time>

End of the time range: an ISO 8601 datetime with a UTC offset (e.g. 2024-01-01T00:00:00Z); a Unix timestamp or a datetime without an offset is refused. Defaults to start + 1 day when only start is provided, or now otherwise; a paginated response carries the resolved value in its Link header.

200 Successful Response
sizeintegerrequired

The number of items in this page

per_pageintegerrequired

The number of items per page

exchangesobject (1 types)[]required
Discriminated by provider — 1 types
github_actionsExchange
idstring <uuid>required
first_exchanged_atstring <date-time>required

When the first of the exchanges this row counts happened: the report is ordered and filtered by it.

last_exchanged_atstring <date-time>required

When the last of them happened.

countintegerrequired

The exchanges this row counts: those of the jobs of one run attempt that ran the same workflow, in the same environment, and got the same answer.

outcome"allowed" | "refused"required
Enum: allowed refused
repositoryExchangeRepositoryrequired
idintegerrequired
full_namestringrequired

As the job's ID token named it.

providerstringrequired

The CI provider that issued the job's ID token.

jobExchangeJobrequired

A GitHub Actions job's claims: its run, event, ref, workflows and environment.

eventstringrequired
refstringrequired
workflow_refstring | nullrequired
job_workflow_refstring | nullrequired
environmentstring | nullrequired
run_idintegerrequired
run_attemptintegerrequired
allowed_by_policiesExchangePolicy[]required

The policies that allowed the job, of those that still exist: an exchange only policies deleted since allowed lists none.

idstring <uuid>required

The policy's id.

namestringrequired

The policy's current name.

permissionsobject | nullrequired

What the token the job got may do on its repository, as the policies that allowed it granted when it exchanged: null for a refused exchange.

refusalExchangeRefusal | nullrequired
reason"no_policy" | "no_matching_policy" | "repository_not_installed" | "audience_mismatch"required
Enum: no_policy no_matching_policy repository_not_installed audience_mismatch
policiesExchangeRefusedBy[]required

For no_matching_policy, why each policy did not match, of those that still exist.

idstring <uuid>required

The policy's id.

namestringrequired

The policy's current name.

line"repositories" | "events" | "workflows" | "environments"required

The policy's first line the job did not match, as the policy read when the job exchanged its token.

Enum: repositories events workflows environments
detailstringrequired
Example Response
                        {
  "size": 0,
  "per_page": 0,
  "exchanges": [
    {
      "id": "string",
      "first_exchanged_at": "2024-01-15T09:00:00Z",
      "last_exchanged_at": "2024-01-15T09:00:00Z",
      "count": 0,
      "outcome": "allowed",
      "repository": {},
      "provider": "github_actions",
      "job": {},
      "allowed_by_policies": null,
      "permissions": {},
      "refusal": {}
    }
  ]
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 Not found
409 Conflict
422 INVALID_CURSOR: The cursor cannot be used for this request. Request the first page again without cursor, then follow the links of the response.

Body: InvalidCursorBody

Example Request
curl -X GET "https://api.mergify.com/v1/ci/:owner/oidc/exchanges" \
  -H "Authorization: Bearer <token>"

Count the exchanges of the organization's CI jobs #

GET /ci/{owner}/oidc/exchanges/summary

How many exchanges the report lists for the same query were allowed and refused, from how many workflows the refused ones came, and how many each policy allowed. Each counts the jobs' exchanges, not the report's rows.

Application key permission: oidc_trust_policies: read.

Application Key Admin Application Key Mergify User Token
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

outcome "allowed" | "refused"

Only the allowed, or the refused, exchanges.

repository_id integer

Only the exchanges of this repository.

min: -9223372036854776000 · max: 9223372036854776000

allowed_by_policy_id string <uuid>

Only the exchanges this policy allowed.

start string <date-time>

Start of the time range: an ISO 8601 datetime with a UTC offset (e.g. 2024-01-01T00:00:00Z); a Unix timestamp or a datetime without an offset is refused. Defaults to end - 1 day when omitted; a paginated response carries the resolved value in its Link header.

end string <date-time>

End of the time range: an ISO 8601 datetime with a UTC offset (e.g. 2024-01-01T00:00:00Z); a Unix timestamp or a datetime without an offset is refused. Defaults to start + 1 day when only start is provided, or now otherwise; a paginated response carries the resolved value in its Link header.

200 Successful Response
allowedintegerrequired

The exchanges allowed.

refusedintegerrequired

The exchanges refused.

refused_workflowsintegerrequired

The workflows the refused exchanges came from: the workflow file each job's run ran, whatever its branch, a reusable workflow counting as the workflow that called it.

policiesPolicyExchanges[]required

The exchanges each policy of the organization allowed, for those that allowed any. An exchange several policies allowed counts for each; a policy deleted since is left out.

idstring <uuid>required

The policy's id.

namestringrequired

The policy's current name.

allowedintegerrequired

The exchanges it allowed.

Example Response
                        {
  "allowed": 0,
  "refused": 0,
  "refused_workflows": 0,
  "policies": [
    {
      "id": "string",
      "name": "string",
      "allowed": 0
    }
  ]
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 Not found
409 Conflict
422 Unprocessable entity
Example Request
curl -X GET "https://api.mergify.com/v1/ci/:owner/oidc/exchanges/summary" \
  -H "Authorization: Bearer <token>"

Get one exchange of the organization's CI jobs #

GET /ci/{owner}/oidc/exchanges/{exchange_id}

One exchange of the report, by the id a refused job's log names.

Application key permission: oidc_trust_policies: read.

Application Key Admin Application Key Mergify User Token
exchange_id string <uuid> required
owner string required

The owner of the repository

min length: 1 · max length: 40 · pattern: ^[a-zA-Z0-9\-]+$

200 Successful Response
Discriminated by provider — 1 types
github_actionsExchange
idstring <uuid>required
first_exchanged_atstring <date-time>required

When the first of the exchanges this row counts happened: the report is ordered and filtered by it.

last_exchanged_atstring <date-time>required

When the last of them happened.

countintegerrequired

The exchanges this row counts: those of the jobs of one run attempt that ran the same workflow, in the same environment, and got the same answer.

outcome"allowed" | "refused"required
Enum: allowed refused
repositoryExchangeRepositoryrequired
idintegerrequired
full_namestringrequired

As the job's ID token named it.

providerstringrequired

The CI provider that issued the job's ID token.

jobExchangeJobrequired

A GitHub Actions job's claims: its run, event, ref, workflows and environment.

eventstringrequired
refstringrequired
workflow_refstring | nullrequired
job_workflow_refstring | nullrequired
environmentstring | nullrequired
run_idintegerrequired
run_attemptintegerrequired
allowed_by_policiesExchangePolicy[]required

The policies that allowed the job, of those that still exist: an exchange only policies deleted since allowed lists none.

idstring <uuid>required

The policy's id.

namestringrequired

The policy's current name.

permissionsobject | nullrequired

What the token the job got may do on its repository, as the policies that allowed it granted when it exchanged: null for a refused exchange.

refusalExchangeRefusal | nullrequired
reason"no_policy" | "no_matching_policy" | "repository_not_installed" | "audience_mismatch"required
Enum: no_policy no_matching_policy repository_not_installed audience_mismatch
policiesExchangeRefusedBy[]required

For no_matching_policy, why each policy did not match, of those that still exist.

idstring <uuid>required

The policy's id.

namestringrequired

The policy's current name.

line"repositories" | "events" | "workflows" | "environments"required

The policy's first line the job did not match, as the policy read when the job exchanged its token.

Enum: repositories events workflows environments
detailstringrequired
Example Response
                        {
  "id": "string",
  "first_exchanged_at": "2024-01-15T09:00:00Z",
  "last_exchanged_at": "2024-01-15T09:00:00Z",
  "count": 0,
  "outcome": "allowed",
  "repository": {
    "id": 0,
    "full_name": "string"
  },
  "provider": "github_actions",
  "job": {
    "event": "string",
    "ref": "string",
    "workflow_ref": "string",
    "job_workflow_ref": "string",
    "environment": "string",
    "run_id": 0,
    "run_attempt": 0
  },
  "allowed_by_policies": [
    {
      "id": "string",
      "name": "string"
    }
  ],
  "permissions": {},
  "refusal": {
    "reason": "no_policy",
    "policies": [
      {}
    ]
  }
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_ADMIN_ROLE_REQUIRED: Only organization admins and users with the CI Admin role can access this. APPLICATION_KEY_REFUSED: The application key lacks the permission the request needs, or the request names an account or repository of another organization. CI_TOKEN_REFUSED: The Mergify OIDC CI token has expired, lacks the permission the request needs, or the request does not name the repository it was issued for.

Body: CredentialRefusedBody

404 CI_ID_TOKEN_EXCHANGE_NOT_FOUND: The report holds no such exchange for the caller: an id of no exchange of the organization, one past its retention, or one of a repository the caller cannot see.

Body: APIErrorBody

409 Conflict
422 Unprocessable entity
Example Request
curl -X GET "https://api.mergify.com/v1/ci/:owner/oidc/exchanges/:exchange_id" \
  -H "Authorization: Bearer <token>"

Exchange a CI job's ID token for a Mergify OIDC CI token #

POST /ci/oidc/exchange

Verify the ID token a CI job got from its CI and answer a Mergify OIDC CI token valid for an hour, on the job's repository only, with the permissions of the trust policies that match the job.

id_tokenstringrequired

The ID token the job's CI gave it.

min length: 1 · max length: 16384
200 Successful Response
tokenstringrequired
expires_inintegerrequired
Example Response
                        {
  "token": "string",
  "expires_in": 0
}
                      
400 API_VERSION_UNKNOWN: The Mergify-Version header names an API version this server does not serve. served_versions lists the versions it serves, each at the newest point this server serves (YYYY-MM-DD.N).

Body: APIVersionUnknownBody

403 CI_ID_TOKEN_INVALID: The ID token is malformed or its signature does not verify. CI_ID_TOKEN_ISSUER_REFUSED: The ID token comes from an issuer this Mergify does not trust. CI_ID_TOKEN_AUDIENCE_REFUSED: The ID token was issued for another audience than this Mergify API. CI_ID_TOKEN_EXPIRED: The ID token has expired. CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED: Mergify's installation on the organization does not cover the ID token's repository. CI_ID_TOKEN_NO_TRUST_POLICY: The organization has no trust policy for the CI of the job, so it trusts none of its jobs. An organization admin can add one, or the job can use an application key instead. CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY: No trust policy of the organization matches the CI job.

Body: APIErrorBody

404 Not found
409 Conflict
422 Unprocessable entity
503 CI_ID_TOKEN_ISSUER_UNAVAILABLE: The ID token issuer's keys cannot be fetched; retrying later succeeds.

Body: APIErrorBody

Example Request
curl -X POST "https://api.mergify.com/v1/ci/oidc/exchange" \
  -H "Content-Type: application/json" \
  -d '{
  "id_token": "string"
}'

Error response bodies #

An endpoint lists each error status it returns and links to the body that comes with it.

APIVersionUnknownBody

detailstringrequired
error_code"ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED" | "API_VERSION_NOT_NEWER" | "API_VERSION_ROLLBACK_UNAVAILABLE" | "API_VERSION_UNKNOWN" | "APPLICATION_KEY_EXPIRED" | "APPLICATION_KEY_REFUSED" | "AUTO_QUARANTINE_CONFIG_NOT_FOUND" | "CI_ADMIN_ROLE_REQUIRED" | "CI_ID_TOKEN_AUDIENCE_REFUSED" | "CI_ID_TOKEN_EXCHANGE_NOT_FOUND" | "CI_ID_TOKEN_EXPIRED" | "CI_ID_TOKEN_INVALID" | "CI_ID_TOKEN_ISSUER_REFUSED" | "CI_ID_TOKEN_ISSUER_UNAVAILABLE" | "CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY" | "CI_ID_TOKEN_NO_TRUST_POLICY" | "CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED" | "CI_TOKEN_REFUSED" | "CI_TOKEN_SCOPES_TARGET_REFUSED" | "CI_TRACES_UPLOAD_UNUSABLE" | "CI_TRUST_POLICY_GRANT_REFUSED" | "CI_TRUST_POLICY_LIMIT_REACHED" | "CI_TRUST_POLICY_NAME_TAKEN" | "CI_TRUST_POLICY_NOT_FOUND" | "CI_TRUST_POLICY_REPOSITORY_UNKNOWN" | "COMMAND_RESTRICTED" | "CONFIGURATION_BRANCH_REFUSED" | "CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED" | "CONFIGURATION_INVALID" | "CONFIGURATION_REFUSED_BY_REPOSITORY_RULES" | "CONFIGURATION_SIGNED_COMMITS_REQUIRED" | "DEFAULT_BRANCH_NOT_FOUND" | "FLAKY_DETECTION_NOT_CONFIGURED" | "GITHUB_ACCOUNT_SUSPENDED" | "GITHUB_APP_ACCESS_LOST" | "GITHUB_RATE_LIMITED" | "GITHUB_TOKEN_NOT_ACCEPTED" | "GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT" | "GITHUB_UPSTREAM_REQUEST_FORBIDDEN" | "GITHUB_UPSTREAM_REQUEST_REJECTED" | "GITHUB_UPSTREAM_UNAVAILABLE" | "INTEGRATION_NOT_CONFIGURED" | "INVALID_CURSOR" | "IP_ALLOW_LIST_NOT_CONFIGURED" | "KNOWN_TESTS_BEING_COMPUTED" | "KNOWN_TESTS_NOT_SERVED" | "MERGE_QUEUE_DISABLED" | "MERGE_QUEUE_POLICY_INVALID_PATTERN" | "MERGE_QUEUE_POLICY_LIMIT_REACHED" | "MERGE_QUEUE_POLICY_NAME_TAKEN" | "MERGE_QUEUE_POLICY_NOT_FOUND" | "MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN" | "MERGE_QUEUE_SETTING_NOT_AVAILABLE" | "MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS" | "NOT_GENERALLY_AVAILABLE" | "NO_LOGIN_IN_PROGRESS" | "ORGANIZATION_MEMBERS_ONLY" | "PULL_REQUEST_ALREADY_QUEUED" | "PULL_REQUEST_LEAVING_QUEUE" | "PULL_REQUEST_NOT_FOUND" | "PULL_REQUEST_NOT_QUEUEABLE" | "PULL_REQUEST_NOT_QUEUED" | "PULL_REQUEST_QUEUE_REQUESTED" | "PULL_REQUEST_UNREADABLE" | "REPOSITORY_ADMIN_ROLE_REQUIRED" | "REPOSITORY_READ_ROLE_REQUIRED" | "REPOSITORY_WRITE_ROLE_REQUIRED" | "RETRY_RULE_NOT_FOUND" | "ROLE_ALREADY_GRANTED" | "ROLE_CHANGE_REFUSED" | "ROLE_GRANTEE_REFUSED" | "ROLE_GRANT_NOT_FOUND" | "SAML_ENFORCEMENT_NOT_AUTHORIZED" | "SCHEDULED_FREEZE_NOT_FOUND" | "SCOPES_COVERAGE_GLOB_TOO_COSTLY" | "SCOPES_COVERAGE_MANUAL_SOURCE" | "SCOPES_COVERAGE_PATH_NOT_FOUND" | "SCOPES_COVERAGE_UNAVAILABLE" | "SETTING_MANAGED_BY_ENV" | "SETUP_ALREADY_DONE" | "SETUP_TOKEN_MISMATCH" | "STAFF_SESSION_REFUSED" | "STATISTICS_SCOPE_PERIOD_TOO_LARGE" | "SUBSCRIPTION_API_UNAVAILABLE" | "SUBSCRIPTION_FEATURE_REQUIRED" | "SUBSCRIPTION_INACTIVE" | "SUBSCRIPTION_TOKEN_INVALID" | "TEST_ALREADY_QUARANTINED" | "TEST_BRANCH_NOT_TRACKED" | "TEST_FAILURE_NOT_FOUND" | "TEST_NOT_FOUND" | "TEST_RESULTS_INGESTION_NOT_ENABLED" | "TEST_RETRY_NOT_CONFIGURED" | "TEST_STATE_NOT_FOUND" | "TEST_STATE_OVERLAP"
Enum: ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED API_VERSION_NOT_NEWER API_VERSION_ROLLBACK_UNAVAILABLE API_VERSION_UNKNOWN APPLICATION_KEY_EXPIRED APPLICATION_KEY_REFUSED AUTO_QUARANTINE_CONFIG_NOT_FOUND CI_ADMIN_ROLE_REQUIRED CI_ID_TOKEN_AUDIENCE_REFUSED CI_ID_TOKEN_EXCHANGE_NOT_FOUND CI_ID_TOKEN_EXPIRED CI_ID_TOKEN_INVALID CI_ID_TOKEN_ISSUER_REFUSED CI_ID_TOKEN_ISSUER_UNAVAILABLE CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY CI_ID_TOKEN_NO_TRUST_POLICY CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED CI_TOKEN_REFUSED CI_TOKEN_SCOPES_TARGET_REFUSED CI_TRACES_UPLOAD_UNUSABLE CI_TRUST_POLICY_GRANT_REFUSED CI_TRUST_POLICY_LIMIT_REACHED CI_TRUST_POLICY_NAME_TAKEN CI_TRUST_POLICY_NOT_FOUND CI_TRUST_POLICY_REPOSITORY_UNKNOWN COMMAND_RESTRICTED CONFIGURATION_BRANCH_REFUSED CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED CONFIGURATION_INVALID CONFIGURATION_REFUSED_BY_REPOSITORY_RULES CONFIGURATION_SIGNED_COMMITS_REQUIRED DEFAULT_BRANCH_NOT_FOUND FLAKY_DETECTION_NOT_CONFIGURED GITHUB_ACCOUNT_SUSPENDED GITHUB_APP_ACCESS_LOST GITHUB_RATE_LIMITED GITHUB_TOKEN_NOT_ACCEPTED GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT GITHUB_UPSTREAM_REQUEST_FORBIDDEN GITHUB_UPSTREAM_REQUEST_REJECTED GITHUB_UPSTREAM_UNAVAILABLE INTEGRATION_NOT_CONFIGURED INVALID_CURSOR IP_ALLOW_LIST_NOT_CONFIGURED KNOWN_TESTS_BEING_COMPUTED KNOWN_TESTS_NOT_SERVED MERGE_QUEUE_DISABLED MERGE_QUEUE_POLICY_INVALID_PATTERN MERGE_QUEUE_POLICY_LIMIT_REACHED MERGE_QUEUE_POLICY_NAME_TAKEN MERGE_QUEUE_POLICY_NOT_FOUND MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN MERGE_QUEUE_SETTING_NOT_AVAILABLE MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS NOT_GENERALLY_AVAILABLE NO_LOGIN_IN_PROGRESS ORGANIZATION_MEMBERS_ONLY PULL_REQUEST_ALREADY_QUEUED PULL_REQUEST_LEAVING_QUEUE PULL_REQUEST_NOT_FOUND PULL_REQUEST_NOT_QUEUEABLE PULL_REQUEST_NOT_QUEUED PULL_REQUEST_QUEUE_REQUESTED PULL_REQUEST_UNREADABLE REPOSITORY_ADMIN_ROLE_REQUIRED REPOSITORY_READ_ROLE_REQUIRED REPOSITORY_WRITE_ROLE_REQUIRED RETRY_RULE_NOT_FOUND ROLE_ALREADY_GRANTED ROLE_CHANGE_REFUSED ROLE_GRANTEE_REFUSED ROLE_GRANT_NOT_FOUND SAML_ENFORCEMENT_NOT_AUTHORIZED SCHEDULED_FREEZE_NOT_FOUND SCOPES_COVERAGE_GLOB_TOO_COSTLY SCOPES_COVERAGE_MANUAL_SOURCE SCOPES_COVERAGE_PATH_NOT_FOUND SCOPES_COVERAGE_UNAVAILABLE SETTING_MANAGED_BY_ENV SETUP_ALREADY_DONE SETUP_TOKEN_MISMATCH STAFF_SESSION_REFUSED STATISTICS_SCOPE_PERIOD_TOO_LARGE SUBSCRIPTION_API_UNAVAILABLE SUBSCRIPTION_FEATURE_REQUIRED SUBSCRIPTION_INACTIVE SUBSCRIPTION_TOKEN_INVALID TEST_ALREADY_QUARANTINED TEST_BRANCH_NOT_TRACKED TEST_FAILURE_NOT_FOUND TEST_NOT_FOUND TEST_RESULTS_INGESTION_NOT_ENABLED TEST_RETRY_NOT_CONFIGURED TEST_STATE_NOT_FOUND TEST_STATE_OVERLAP
documentation_urlstring
served_versionsstring[]required
Example Response
                {
  "detail": "string",
  "error_code": "API_VERSION_UNKNOWN",
  "documentation_url": "string",
  "served_versions": [
    "string"
  ]
}
              

CredentialRefusedBody

detailstringrequired
error_code"ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED" | "API_VERSION_NOT_NEWER" | "API_VERSION_ROLLBACK_UNAVAILABLE" | "API_VERSION_UNKNOWN" | "APPLICATION_KEY_EXPIRED" | "APPLICATION_KEY_REFUSED" | "AUTO_QUARANTINE_CONFIG_NOT_FOUND" | "CI_ADMIN_ROLE_REQUIRED" | "CI_ID_TOKEN_AUDIENCE_REFUSED" | "CI_ID_TOKEN_EXCHANGE_NOT_FOUND" | "CI_ID_TOKEN_EXPIRED" | "CI_ID_TOKEN_INVALID" | "CI_ID_TOKEN_ISSUER_REFUSED" | "CI_ID_TOKEN_ISSUER_UNAVAILABLE" | "CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY" | "CI_ID_TOKEN_NO_TRUST_POLICY" | "CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED" | "CI_TOKEN_REFUSED" | "CI_TOKEN_SCOPES_TARGET_REFUSED" | "CI_TRACES_UPLOAD_UNUSABLE" | "CI_TRUST_POLICY_GRANT_REFUSED" | "CI_TRUST_POLICY_LIMIT_REACHED" | "CI_TRUST_POLICY_NAME_TAKEN" | "CI_TRUST_POLICY_NOT_FOUND" | "CI_TRUST_POLICY_REPOSITORY_UNKNOWN" | "COMMAND_RESTRICTED" | "CONFIGURATION_BRANCH_REFUSED" | "CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED" | "CONFIGURATION_INVALID" | "CONFIGURATION_REFUSED_BY_REPOSITORY_RULES" | "CONFIGURATION_SIGNED_COMMITS_REQUIRED" | "DEFAULT_BRANCH_NOT_FOUND" | "FLAKY_DETECTION_NOT_CONFIGURED" | "GITHUB_ACCOUNT_SUSPENDED" | "GITHUB_APP_ACCESS_LOST" | "GITHUB_RATE_LIMITED" | "GITHUB_TOKEN_NOT_ACCEPTED" | "GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT" | "GITHUB_UPSTREAM_REQUEST_FORBIDDEN" | "GITHUB_UPSTREAM_REQUEST_REJECTED" | "GITHUB_UPSTREAM_UNAVAILABLE" | "INTEGRATION_NOT_CONFIGURED" | "INVALID_CURSOR" | "IP_ALLOW_LIST_NOT_CONFIGURED" | "KNOWN_TESTS_BEING_COMPUTED" | "KNOWN_TESTS_NOT_SERVED" | "MERGE_QUEUE_DISABLED" | "MERGE_QUEUE_POLICY_INVALID_PATTERN" | "MERGE_QUEUE_POLICY_LIMIT_REACHED" | "MERGE_QUEUE_POLICY_NAME_TAKEN" | "MERGE_QUEUE_POLICY_NOT_FOUND" | "MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN" | "MERGE_QUEUE_SETTING_NOT_AVAILABLE" | "MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS" | "NOT_GENERALLY_AVAILABLE" | "NO_LOGIN_IN_PROGRESS" | "ORGANIZATION_MEMBERS_ONLY" | "PULL_REQUEST_ALREADY_QUEUED" | "PULL_REQUEST_LEAVING_QUEUE" | "PULL_REQUEST_NOT_FOUND" | "PULL_REQUEST_NOT_QUEUEABLE" | "PULL_REQUEST_NOT_QUEUED" | "PULL_REQUEST_QUEUE_REQUESTED" | "PULL_REQUEST_UNREADABLE" | "REPOSITORY_ADMIN_ROLE_REQUIRED" | "REPOSITORY_READ_ROLE_REQUIRED" | "REPOSITORY_WRITE_ROLE_REQUIRED" | "RETRY_RULE_NOT_FOUND" | "ROLE_ALREADY_GRANTED" | "ROLE_CHANGE_REFUSED" | "ROLE_GRANTEE_REFUSED" | "ROLE_GRANT_NOT_FOUND" | "SAML_ENFORCEMENT_NOT_AUTHORIZED" | "SCHEDULED_FREEZE_NOT_FOUND" | "SCOPES_COVERAGE_GLOB_TOO_COSTLY" | "SCOPES_COVERAGE_MANUAL_SOURCE" | "SCOPES_COVERAGE_PATH_NOT_FOUND" | "SCOPES_COVERAGE_UNAVAILABLE" | "SETTING_MANAGED_BY_ENV" | "SETUP_ALREADY_DONE" | "SETUP_TOKEN_MISMATCH" | "STAFF_SESSION_REFUSED" | "STATISTICS_SCOPE_PERIOD_TOO_LARGE" | "SUBSCRIPTION_API_UNAVAILABLE" | "SUBSCRIPTION_FEATURE_REQUIRED" | "SUBSCRIPTION_INACTIVE" | "SUBSCRIPTION_TOKEN_INVALID" | "TEST_ALREADY_QUARANTINED" | "TEST_BRANCH_NOT_TRACKED" | "TEST_FAILURE_NOT_FOUND" | "TEST_NOT_FOUND" | "TEST_RESULTS_INGESTION_NOT_ENABLED" | "TEST_RETRY_NOT_CONFIGURED" | "TEST_STATE_NOT_FOUND" | "TEST_STATE_OVERLAP"
Enum: ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED API_VERSION_NOT_NEWER API_VERSION_ROLLBACK_UNAVAILABLE API_VERSION_UNKNOWN APPLICATION_KEY_EXPIRED APPLICATION_KEY_REFUSED AUTO_QUARANTINE_CONFIG_NOT_FOUND CI_ADMIN_ROLE_REQUIRED CI_ID_TOKEN_AUDIENCE_REFUSED CI_ID_TOKEN_EXCHANGE_NOT_FOUND CI_ID_TOKEN_EXPIRED CI_ID_TOKEN_INVALID CI_ID_TOKEN_ISSUER_REFUSED CI_ID_TOKEN_ISSUER_UNAVAILABLE CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY CI_ID_TOKEN_NO_TRUST_POLICY CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED CI_TOKEN_REFUSED CI_TOKEN_SCOPES_TARGET_REFUSED CI_TRACES_UPLOAD_UNUSABLE CI_TRUST_POLICY_GRANT_REFUSED CI_TRUST_POLICY_LIMIT_REACHED CI_TRUST_POLICY_NAME_TAKEN CI_TRUST_POLICY_NOT_FOUND CI_TRUST_POLICY_REPOSITORY_UNKNOWN COMMAND_RESTRICTED CONFIGURATION_BRANCH_REFUSED CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED CONFIGURATION_INVALID CONFIGURATION_REFUSED_BY_REPOSITORY_RULES CONFIGURATION_SIGNED_COMMITS_REQUIRED DEFAULT_BRANCH_NOT_FOUND FLAKY_DETECTION_NOT_CONFIGURED GITHUB_ACCOUNT_SUSPENDED GITHUB_APP_ACCESS_LOST GITHUB_RATE_LIMITED GITHUB_TOKEN_NOT_ACCEPTED GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT GITHUB_UPSTREAM_REQUEST_FORBIDDEN GITHUB_UPSTREAM_REQUEST_REJECTED GITHUB_UPSTREAM_UNAVAILABLE INTEGRATION_NOT_CONFIGURED INVALID_CURSOR IP_ALLOW_LIST_NOT_CONFIGURED KNOWN_TESTS_BEING_COMPUTED KNOWN_TESTS_NOT_SERVED MERGE_QUEUE_DISABLED MERGE_QUEUE_POLICY_INVALID_PATTERN MERGE_QUEUE_POLICY_LIMIT_REACHED MERGE_QUEUE_POLICY_NAME_TAKEN MERGE_QUEUE_POLICY_NOT_FOUND MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN MERGE_QUEUE_SETTING_NOT_AVAILABLE MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS NOT_GENERALLY_AVAILABLE NO_LOGIN_IN_PROGRESS ORGANIZATION_MEMBERS_ONLY PULL_REQUEST_ALREADY_QUEUED PULL_REQUEST_LEAVING_QUEUE PULL_REQUEST_NOT_FOUND PULL_REQUEST_NOT_QUEUEABLE PULL_REQUEST_NOT_QUEUED PULL_REQUEST_QUEUE_REQUESTED PULL_REQUEST_UNREADABLE REPOSITORY_ADMIN_ROLE_REQUIRED REPOSITORY_READ_ROLE_REQUIRED REPOSITORY_WRITE_ROLE_REQUIRED RETRY_RULE_NOT_FOUND ROLE_ALREADY_GRANTED ROLE_CHANGE_REFUSED ROLE_GRANTEE_REFUSED ROLE_GRANT_NOT_FOUND SAML_ENFORCEMENT_NOT_AUTHORIZED SCHEDULED_FREEZE_NOT_FOUND SCOPES_COVERAGE_GLOB_TOO_COSTLY SCOPES_COVERAGE_MANUAL_SOURCE SCOPES_COVERAGE_PATH_NOT_FOUND SCOPES_COVERAGE_UNAVAILABLE SETTING_MANAGED_BY_ENV SETUP_ALREADY_DONE SETUP_TOKEN_MISMATCH STAFF_SESSION_REFUSED STATISTICS_SCOPE_PERIOD_TOO_LARGE SUBSCRIPTION_API_UNAVAILABLE SUBSCRIPTION_FEATURE_REQUIRED SUBSCRIPTION_INACTIVE SUBSCRIPTION_TOKEN_INVALID TEST_ALREADY_QUARANTINED TEST_BRANCH_NOT_TRACKED TEST_FAILURE_NOT_FOUND TEST_NOT_FOUND TEST_RESULTS_INGESTION_NOT_ENABLED TEST_RETRY_NOT_CONFIGURED TEST_STATE_NOT_FOUND TEST_STATE_OVERLAP
documentation_urlstring
accepted_permissionsAcceptedPermission[] | null

The permissions the operation accepts, any one of which a credential needs to call it, as its x-mergify-permission extension lists them, whatever refused the credential. Null when the operation takes no credential of this kind.

resource"merge_queue" | "merge_queue_statistics" | "merge_queue_pause" | "scheduled_freezes" | "merge_queue_settings" | "merge_protections" | "ci_jobs" | "job_retry_rules" | "runners" | "runner_fleet_settings" | "tests" | "quarantines" | "test_retry_settings" | "flaky_detection_settings" | "test_tracked_branches" | "test_selection" | "repositories" | "configuration" | "pull_requests" | "simulators" | "activity_log" | "slack" | "datadog" | "users" | "products" | "roles" | "api_version" | "oidc_trust_policies" | "ci_reporting"required
Enum: merge_queue merge_queue_statistics merge_queue_pause scheduled_freezes merge_queue_settings merge_protections ci_jobs job_retry_rules runners runner_fleet_settings tests quarantines test_retry_settings flaky_detection_settings test_tracked_branches test_selection repositories configuration pull_requests simulators activity_log slack datadog users products roles api_version oidc_trust_policies ci_reporting
access"read" | "write"required
Enum: read write
Example Response
                {
  "detail": "string",
  "error_code": "CI_ADMIN_ROLE_REQUIRED",
  "documentation_url": "string",
  "accepted_permissions": [
    {
      "resource": "merge_queue",
      "access": "read"
    }
  ]
}
              

APIErrorBody

detailstringrequired
error_code"ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED" | "API_VERSION_NOT_NEWER" | "API_VERSION_ROLLBACK_UNAVAILABLE" | "API_VERSION_UNKNOWN" | "APPLICATION_KEY_EXPIRED" | "APPLICATION_KEY_REFUSED" | "AUTO_QUARANTINE_CONFIG_NOT_FOUND" | "CI_ADMIN_ROLE_REQUIRED" | "CI_ID_TOKEN_AUDIENCE_REFUSED" | "CI_ID_TOKEN_EXCHANGE_NOT_FOUND" | "CI_ID_TOKEN_EXPIRED" | "CI_ID_TOKEN_INVALID" | "CI_ID_TOKEN_ISSUER_REFUSED" | "CI_ID_TOKEN_ISSUER_UNAVAILABLE" | "CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY" | "CI_ID_TOKEN_NO_TRUST_POLICY" | "CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED" | "CI_TOKEN_REFUSED" | "CI_TOKEN_SCOPES_TARGET_REFUSED" | "CI_TRACES_UPLOAD_UNUSABLE" | "CI_TRUST_POLICY_GRANT_REFUSED" | "CI_TRUST_POLICY_LIMIT_REACHED" | "CI_TRUST_POLICY_NAME_TAKEN" | "CI_TRUST_POLICY_NOT_FOUND" | "CI_TRUST_POLICY_REPOSITORY_UNKNOWN" | "COMMAND_RESTRICTED" | "CONFIGURATION_BRANCH_REFUSED" | "CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED" | "CONFIGURATION_INVALID" | "CONFIGURATION_REFUSED_BY_REPOSITORY_RULES" | "CONFIGURATION_SIGNED_COMMITS_REQUIRED" | "DEFAULT_BRANCH_NOT_FOUND" | "FLAKY_DETECTION_NOT_CONFIGURED" | "GITHUB_ACCOUNT_SUSPENDED" | "GITHUB_APP_ACCESS_LOST" | "GITHUB_RATE_LIMITED" | "GITHUB_TOKEN_NOT_ACCEPTED" | "GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT" | "GITHUB_UPSTREAM_REQUEST_FORBIDDEN" | "GITHUB_UPSTREAM_REQUEST_REJECTED" | "GITHUB_UPSTREAM_UNAVAILABLE" | "INTEGRATION_NOT_CONFIGURED" | "INVALID_CURSOR" | "IP_ALLOW_LIST_NOT_CONFIGURED" | "KNOWN_TESTS_BEING_COMPUTED" | "KNOWN_TESTS_NOT_SERVED" | "MERGE_QUEUE_DISABLED" | "MERGE_QUEUE_POLICY_INVALID_PATTERN" | "MERGE_QUEUE_POLICY_LIMIT_REACHED" | "MERGE_QUEUE_POLICY_NAME_TAKEN" | "MERGE_QUEUE_POLICY_NOT_FOUND" | "MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN" | "MERGE_QUEUE_SETTING_NOT_AVAILABLE" | "MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS" | "NOT_GENERALLY_AVAILABLE" | "NO_LOGIN_IN_PROGRESS" | "ORGANIZATION_MEMBERS_ONLY" | "PULL_REQUEST_ALREADY_QUEUED" | "PULL_REQUEST_LEAVING_QUEUE" | "PULL_REQUEST_NOT_FOUND" | "PULL_REQUEST_NOT_QUEUEABLE" | "PULL_REQUEST_NOT_QUEUED" | "PULL_REQUEST_QUEUE_REQUESTED" | "PULL_REQUEST_UNREADABLE" | "REPOSITORY_ADMIN_ROLE_REQUIRED" | "REPOSITORY_READ_ROLE_REQUIRED" | "REPOSITORY_WRITE_ROLE_REQUIRED" | "RETRY_RULE_NOT_FOUND" | "ROLE_ALREADY_GRANTED" | "ROLE_CHANGE_REFUSED" | "ROLE_GRANTEE_REFUSED" | "ROLE_GRANT_NOT_FOUND" | "SAML_ENFORCEMENT_NOT_AUTHORIZED" | "SCHEDULED_FREEZE_NOT_FOUND" | "SCOPES_COVERAGE_GLOB_TOO_COSTLY" | "SCOPES_COVERAGE_MANUAL_SOURCE" | "SCOPES_COVERAGE_PATH_NOT_FOUND" | "SCOPES_COVERAGE_UNAVAILABLE" | "SETTING_MANAGED_BY_ENV" | "SETUP_ALREADY_DONE" | "SETUP_TOKEN_MISMATCH" | "STAFF_SESSION_REFUSED" | "STATISTICS_SCOPE_PERIOD_TOO_LARGE" | "SUBSCRIPTION_API_UNAVAILABLE" | "SUBSCRIPTION_FEATURE_REQUIRED" | "SUBSCRIPTION_INACTIVE" | "SUBSCRIPTION_TOKEN_INVALID" | "TEST_ALREADY_QUARANTINED" | "TEST_BRANCH_NOT_TRACKED" | "TEST_FAILURE_NOT_FOUND" | "TEST_NOT_FOUND" | "TEST_RESULTS_INGESTION_NOT_ENABLED" | "TEST_RETRY_NOT_CONFIGURED" | "TEST_STATE_NOT_FOUND" | "TEST_STATE_OVERLAP"
Enum: ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED API_VERSION_NOT_NEWER API_VERSION_ROLLBACK_UNAVAILABLE API_VERSION_UNKNOWN APPLICATION_KEY_EXPIRED APPLICATION_KEY_REFUSED AUTO_QUARANTINE_CONFIG_NOT_FOUND CI_ADMIN_ROLE_REQUIRED CI_ID_TOKEN_AUDIENCE_REFUSED CI_ID_TOKEN_EXCHANGE_NOT_FOUND CI_ID_TOKEN_EXPIRED CI_ID_TOKEN_INVALID CI_ID_TOKEN_ISSUER_REFUSED CI_ID_TOKEN_ISSUER_UNAVAILABLE CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY CI_ID_TOKEN_NO_TRUST_POLICY CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED CI_TOKEN_REFUSED CI_TOKEN_SCOPES_TARGET_REFUSED CI_TRACES_UPLOAD_UNUSABLE CI_TRUST_POLICY_GRANT_REFUSED CI_TRUST_POLICY_LIMIT_REACHED CI_TRUST_POLICY_NAME_TAKEN CI_TRUST_POLICY_NOT_FOUND CI_TRUST_POLICY_REPOSITORY_UNKNOWN COMMAND_RESTRICTED CONFIGURATION_BRANCH_REFUSED CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED CONFIGURATION_INVALID CONFIGURATION_REFUSED_BY_REPOSITORY_RULES CONFIGURATION_SIGNED_COMMITS_REQUIRED DEFAULT_BRANCH_NOT_FOUND FLAKY_DETECTION_NOT_CONFIGURED GITHUB_ACCOUNT_SUSPENDED GITHUB_APP_ACCESS_LOST GITHUB_RATE_LIMITED GITHUB_TOKEN_NOT_ACCEPTED GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT GITHUB_UPSTREAM_REQUEST_FORBIDDEN GITHUB_UPSTREAM_REQUEST_REJECTED GITHUB_UPSTREAM_UNAVAILABLE INTEGRATION_NOT_CONFIGURED INVALID_CURSOR IP_ALLOW_LIST_NOT_CONFIGURED KNOWN_TESTS_BEING_COMPUTED KNOWN_TESTS_NOT_SERVED MERGE_QUEUE_DISABLED MERGE_QUEUE_POLICY_INVALID_PATTERN MERGE_QUEUE_POLICY_LIMIT_REACHED MERGE_QUEUE_POLICY_NAME_TAKEN MERGE_QUEUE_POLICY_NOT_FOUND MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN MERGE_QUEUE_SETTING_NOT_AVAILABLE MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS NOT_GENERALLY_AVAILABLE NO_LOGIN_IN_PROGRESS ORGANIZATION_MEMBERS_ONLY PULL_REQUEST_ALREADY_QUEUED PULL_REQUEST_LEAVING_QUEUE PULL_REQUEST_NOT_FOUND PULL_REQUEST_NOT_QUEUEABLE PULL_REQUEST_NOT_QUEUED PULL_REQUEST_QUEUE_REQUESTED PULL_REQUEST_UNREADABLE REPOSITORY_ADMIN_ROLE_REQUIRED REPOSITORY_READ_ROLE_REQUIRED REPOSITORY_WRITE_ROLE_REQUIRED RETRY_RULE_NOT_FOUND ROLE_ALREADY_GRANTED ROLE_CHANGE_REFUSED ROLE_GRANTEE_REFUSED ROLE_GRANT_NOT_FOUND SAML_ENFORCEMENT_NOT_AUTHORIZED SCHEDULED_FREEZE_NOT_FOUND SCOPES_COVERAGE_GLOB_TOO_COSTLY SCOPES_COVERAGE_MANUAL_SOURCE SCOPES_COVERAGE_PATH_NOT_FOUND SCOPES_COVERAGE_UNAVAILABLE SETTING_MANAGED_BY_ENV SETUP_ALREADY_DONE SETUP_TOKEN_MISMATCH STAFF_SESSION_REFUSED STATISTICS_SCOPE_PERIOD_TOO_LARGE SUBSCRIPTION_API_UNAVAILABLE SUBSCRIPTION_FEATURE_REQUIRED SUBSCRIPTION_INACTIVE SUBSCRIPTION_TOKEN_INVALID TEST_ALREADY_QUARANTINED TEST_BRANCH_NOT_TRACKED TEST_FAILURE_NOT_FOUND TEST_NOT_FOUND TEST_RESULTS_INGESTION_NOT_ENABLED TEST_RETRY_NOT_CONFIGURED TEST_STATE_NOT_FOUND TEST_STATE_OVERLAP
documentation_urlstring
Example Response
                {
  "detail": "string",
  "error_code": "CI_TRUST_POLICY_NOT_FOUND",
  "documentation_url": "string"
}
              

InvalidCursorBody

detailInvalidCursorDetailrequired
messagestringrequired
cursorstring | nullrequired
error_code"ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED" | "API_VERSION_NOT_NEWER" | "API_VERSION_ROLLBACK_UNAVAILABLE" | "API_VERSION_UNKNOWN" | "APPLICATION_KEY_EXPIRED" | "APPLICATION_KEY_REFUSED" | "AUTO_QUARANTINE_CONFIG_NOT_FOUND" | "CI_ADMIN_ROLE_REQUIRED" | "CI_ID_TOKEN_AUDIENCE_REFUSED" | "CI_ID_TOKEN_EXCHANGE_NOT_FOUND" | "CI_ID_TOKEN_EXPIRED" | "CI_ID_TOKEN_INVALID" | "CI_ID_TOKEN_ISSUER_REFUSED" | "CI_ID_TOKEN_ISSUER_UNAVAILABLE" | "CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY" | "CI_ID_TOKEN_NO_TRUST_POLICY" | "CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED" | "CI_TOKEN_REFUSED" | "CI_TOKEN_SCOPES_TARGET_REFUSED" | "CI_TRACES_UPLOAD_UNUSABLE" | "CI_TRUST_POLICY_GRANT_REFUSED" | "CI_TRUST_POLICY_LIMIT_REACHED" | "CI_TRUST_POLICY_NAME_TAKEN" | "CI_TRUST_POLICY_NOT_FOUND" | "CI_TRUST_POLICY_REPOSITORY_UNKNOWN" | "COMMAND_RESTRICTED" | "CONFIGURATION_BRANCH_REFUSED" | "CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED" | "CONFIGURATION_INVALID" | "CONFIGURATION_REFUSED_BY_REPOSITORY_RULES" | "CONFIGURATION_SIGNED_COMMITS_REQUIRED" | "DEFAULT_BRANCH_NOT_FOUND" | "FLAKY_DETECTION_NOT_CONFIGURED" | "GITHUB_ACCOUNT_SUSPENDED" | "GITHUB_APP_ACCESS_LOST" | "GITHUB_RATE_LIMITED" | "GITHUB_TOKEN_NOT_ACCEPTED" | "GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT" | "GITHUB_UPSTREAM_REQUEST_FORBIDDEN" | "GITHUB_UPSTREAM_REQUEST_REJECTED" | "GITHUB_UPSTREAM_UNAVAILABLE" | "INTEGRATION_NOT_CONFIGURED" | "INVALID_CURSOR" | "IP_ALLOW_LIST_NOT_CONFIGURED" | "KNOWN_TESTS_BEING_COMPUTED" | "KNOWN_TESTS_NOT_SERVED" | "MERGE_QUEUE_DISABLED" | "MERGE_QUEUE_POLICY_INVALID_PATTERN" | "MERGE_QUEUE_POLICY_LIMIT_REACHED" | "MERGE_QUEUE_POLICY_NAME_TAKEN" | "MERGE_QUEUE_POLICY_NOT_FOUND" | "MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN" | "MERGE_QUEUE_SETTING_NOT_AVAILABLE" | "MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS" | "NOT_GENERALLY_AVAILABLE" | "NO_LOGIN_IN_PROGRESS" | "ORGANIZATION_MEMBERS_ONLY" | "PULL_REQUEST_ALREADY_QUEUED" | "PULL_REQUEST_LEAVING_QUEUE" | "PULL_REQUEST_NOT_FOUND" | "PULL_REQUEST_NOT_QUEUEABLE" | "PULL_REQUEST_NOT_QUEUED" | "PULL_REQUEST_QUEUE_REQUESTED" | "PULL_REQUEST_UNREADABLE" | "REPOSITORY_ADMIN_ROLE_REQUIRED" | "REPOSITORY_READ_ROLE_REQUIRED" | "REPOSITORY_WRITE_ROLE_REQUIRED" | "RETRY_RULE_NOT_FOUND" | "ROLE_ALREADY_GRANTED" | "ROLE_CHANGE_REFUSED" | "ROLE_GRANTEE_REFUSED" | "ROLE_GRANT_NOT_FOUND" | "SAML_ENFORCEMENT_NOT_AUTHORIZED" | "SCHEDULED_FREEZE_NOT_FOUND" | "SCOPES_COVERAGE_GLOB_TOO_COSTLY" | "SCOPES_COVERAGE_MANUAL_SOURCE" | "SCOPES_COVERAGE_PATH_NOT_FOUND" | "SCOPES_COVERAGE_UNAVAILABLE" | "SETTING_MANAGED_BY_ENV" | "SETUP_ALREADY_DONE" | "SETUP_TOKEN_MISMATCH" | "STAFF_SESSION_REFUSED" | "STATISTICS_SCOPE_PERIOD_TOO_LARGE" | "SUBSCRIPTION_API_UNAVAILABLE" | "SUBSCRIPTION_FEATURE_REQUIRED" | "SUBSCRIPTION_INACTIVE" | "SUBSCRIPTION_TOKEN_INVALID" | "TEST_ALREADY_QUARANTINED" | "TEST_BRANCH_NOT_TRACKED" | "TEST_FAILURE_NOT_FOUND" | "TEST_NOT_FOUND" | "TEST_RESULTS_INGESTION_NOT_ENABLED" | "TEST_RETRY_NOT_CONFIGURED" | "TEST_STATE_NOT_FOUND" | "TEST_STATE_OVERLAP"
Enum: ACTIVITY_LOG_METADATA_FILTER_NOT_INDEXED API_VERSION_NOT_NEWER API_VERSION_ROLLBACK_UNAVAILABLE API_VERSION_UNKNOWN APPLICATION_KEY_EXPIRED APPLICATION_KEY_REFUSED AUTO_QUARANTINE_CONFIG_NOT_FOUND CI_ADMIN_ROLE_REQUIRED CI_ID_TOKEN_AUDIENCE_REFUSED CI_ID_TOKEN_EXCHANGE_NOT_FOUND CI_ID_TOKEN_EXPIRED CI_ID_TOKEN_INVALID CI_ID_TOKEN_ISSUER_REFUSED CI_ID_TOKEN_ISSUER_UNAVAILABLE CI_ID_TOKEN_NO_MATCHING_TRUST_POLICY CI_ID_TOKEN_NO_TRUST_POLICY CI_ID_TOKEN_REPOSITORY_NOT_INSTALLED CI_TOKEN_REFUSED CI_TOKEN_SCOPES_TARGET_REFUSED CI_TRACES_UPLOAD_UNUSABLE CI_TRUST_POLICY_GRANT_REFUSED CI_TRUST_POLICY_LIMIT_REACHED CI_TRUST_POLICY_NAME_TAKEN CI_TRUST_POLICY_NOT_FOUND CI_TRUST_POLICY_REPOSITORY_UNKNOWN COMMAND_RESTRICTED CONFIGURATION_BRANCH_REFUSED CONFIGURATION_GITHUB_APP_ACCESS_REQUIRED CONFIGURATION_INVALID CONFIGURATION_REFUSED_BY_REPOSITORY_RULES CONFIGURATION_SIGNED_COMMITS_REQUIRED DEFAULT_BRANCH_NOT_FOUND FLAKY_DETECTION_NOT_CONFIGURED GITHUB_ACCOUNT_SUSPENDED GITHUB_APP_ACCESS_LOST GITHUB_RATE_LIMITED GITHUB_TOKEN_NOT_ACCEPTED GITHUB_TWO_FACTOR_AUTHENTICATION_NONCOMPLIANT GITHUB_UPSTREAM_REQUEST_FORBIDDEN GITHUB_UPSTREAM_REQUEST_REJECTED GITHUB_UPSTREAM_UNAVAILABLE INTEGRATION_NOT_CONFIGURED INVALID_CURSOR IP_ALLOW_LIST_NOT_CONFIGURED KNOWN_TESTS_BEING_COMPUTED KNOWN_TESTS_NOT_SERVED MERGE_QUEUE_DISABLED MERGE_QUEUE_POLICY_INVALID_PATTERN MERGE_QUEUE_POLICY_LIMIT_REACHED MERGE_QUEUE_POLICY_NAME_TAKEN MERGE_QUEUE_POLICY_NOT_FOUND MERGE_QUEUE_SETTING_INVALID_BRANCH_PATTERN MERGE_QUEUE_SETTING_NOT_AVAILABLE MERGE_QUEUE_SETTING_TOO_MANY_BRANCH_PATTERNS NOT_GENERALLY_AVAILABLE NO_LOGIN_IN_PROGRESS ORGANIZATION_MEMBERS_ONLY PULL_REQUEST_ALREADY_QUEUED PULL_REQUEST_LEAVING_QUEUE PULL_REQUEST_NOT_FOUND PULL_REQUEST_NOT_QUEUEABLE PULL_REQUEST_NOT_QUEUED PULL_REQUEST_QUEUE_REQUESTED PULL_REQUEST_UNREADABLE REPOSITORY_ADMIN_ROLE_REQUIRED REPOSITORY_READ_ROLE_REQUIRED REPOSITORY_WRITE_ROLE_REQUIRED RETRY_RULE_NOT_FOUND ROLE_ALREADY_GRANTED ROLE_CHANGE_REFUSED ROLE_GRANTEE_REFUSED ROLE_GRANT_NOT_FOUND SAML_ENFORCEMENT_NOT_AUTHORIZED SCHEDULED_FREEZE_NOT_FOUND SCOPES_COVERAGE_GLOB_TOO_COSTLY SCOPES_COVERAGE_MANUAL_SOURCE SCOPES_COVERAGE_PATH_NOT_FOUND SCOPES_COVERAGE_UNAVAILABLE SETTING_MANAGED_BY_ENV SETUP_ALREADY_DONE SETUP_TOKEN_MISMATCH STAFF_SESSION_REFUSED STATISTICS_SCOPE_PERIOD_TOO_LARGE SUBSCRIPTION_API_UNAVAILABLE SUBSCRIPTION_FEATURE_REQUIRED SUBSCRIPTION_INACTIVE SUBSCRIPTION_TOKEN_INVALID TEST_ALREADY_QUARANTINED TEST_BRANCH_NOT_TRACKED TEST_FAILURE_NOT_FOUND TEST_NOT_FOUND TEST_RESULTS_INGESTION_NOT_ENABLED TEST_RETRY_NOT_CONFIGURED TEST_STATE_NOT_FOUND TEST_STATE_OVERLAP
Example Response
                {
  "detail": {
    "message": "string",
    "cursor": "string"
  },
  "error_code": "INVALID_CURSOR"
}
              

Was this page helpful?