Skip to content

Get Copilot cloud agent configuration for a repository

GET
/repos/{owner}/{repo}/copilot/cloud-agent/configuration

[!NOTE] This endpoint is in public preview and is subject to change.

Gets the Copilot cloud agent configuration for a repository, including MCP server configuration, enabled review tools, Actions workflow approval settings, and firewall configuration.

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

API method documentation

owner
required
string

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

repo
required
string

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

Response

Media type application/json
object
mcp_configuration
required

The user-supplied MCP server configuration for the repository, as a free-form JSON object. This will be set to null if no configuration has been set.

The shape of a valid MCP configuration may evolve over time, so this property is intentionally not strictly typed. Clients should not assume a fixed schema.

object
key
additional properties
any
enabled_tools
required

The enabled review tools for Copilot cloud agent.

object
codeql
required

Whether the CodeQL tool is enabled for the Copilot cloud agent.

boolean
copilot_code_review
required

Whether the Copilot code review tool is enabled for the Copilot cloud agent.

boolean
secret_scanning
required

Whether the secret scanning tool is enabled for the Copilot cloud agent.

boolean
dependency_vulnerability_checks
required

Whether the dependency vulnerability checks tool is enabled for the Copilot cloud agent.

boolean
require_actions_workflow_approval
required

Whether Actions workflow approval is required for Copilot cloud agent pull requests.

boolean
is_firewall_enabled
required

Whether the firewall is enabled.

boolean
is_firewall_recommended_allowlist_enabled
required

Whether the firewall recommended allowlist is enabled.

boolean
custom_allowlist
required

A list of custom allowlist entries, as hosts or URLs, that the firewall will allow the Copilot cloud agent to access.

Array<string>
is_automations_enabled
required

Whether automations are enabled in this repository. When true, users can create automations that automatically run agents on a schedule or in response to events like new issues or updated pull requests.

boolean
require_write_access_for_automation_triggers
required

Whether write access is required for automation triggers. When true, automations will only run if the user triggering the event has write access to the repository. When false, users can create automations that listen for events triggered by users without write access.

boolean
Examples

Default configuration

{
"mcp_configuration": null,
"enabled_tools": {
"codeql": true,
"copilot_code_review": true,
"secret_scanning": true,
"dependency_vulnerability_checks": true
},
"require_actions_workflow_approval": true,
"is_firewall_enabled": true,
"is_firewall_recommended_allowlist_enabled": true,
"custom_allowlist": [],
"is_automations_enabled": true,
"require_write_access_for_automation_triggers": true
}

Requires authentication

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}

Forbidden

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}

Resource not found

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}

Internal Error

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}