Skip to content

List custom deployment rule integrations available for an environment

GET
/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/apps

Gets all custom deployment protection rule integrations that are available for an environment.

The authenticated user must have admin or owner permissions to the repository to use this endpoint.

For more information about environments, see “Using environments for deployment.”

For more information about the app that is providing this custom deployment rule, see “GET an app”.

OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint with a private repository.

API method documentation

environment_name
required
string

The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with %2F.

repo
required
string

The name of the repository without the .git extension. The name is not case sensitive.

owner
required
string

The account owner of the repository. The name is not case sensitive.

page
integer
default: 1

The page number of the results to fetch. For more information, see “Using pagination in the REST API.”

per_page
integer
default: 30

The number of results per page (max 100). For more information, see “Using pagination in the REST API.”

A list of custom deployment rule integrations available for this environment.

Media type application/json
object
total_count

The total number of custom deployment protection rule integrations available for this environment.

integer
available_custom_deployment_protection_rule_integrations
Array<object>
Custom deployment protection rule app

A GitHub App that is providing a custom deployment protection rule.

object
id
required

The unique identifier of the deployment protection rule integration.

integer
slug
required

The slugified name of the deployment protection rule integration.

string
integration_url
required

The URL for the endpoint to get details about the app.

string
node_id
required

The node ID for the deployment protection rule integration.

string
Examples
Example default
[
{
"total_count": 2
},
{
"available_custom_deployment_protection_rule_integrations": [
{
"id": 1,
"node_id": "GHT58kRlcGxveW1lbnRTdTY!bbcy",
"slug": "a-custom-app",
"integration_url": "https://api.github.com/apps/a-custom-app"
},
{
"id": 2,
"node_id": "UHVE67RlcGxveW1lbnRTdTY!jfeuy",
"slug": "another-custom-app",
"integration_url": "https://api.github.com/apps/another-custom-app"
}
]
}
]