Get default code security configurations for an enterprise
Lists the default code security configurations for an enterprise.
The authenticated user must be an administrator of the enterprise in order to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the read:enterprise scope to use this endpoint.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”The slug version of the enterprise name.
Responses
Section titled “ Responses ”Response
A list of default code security configurations
object
The visibility of newly created repositories for which the code security configuration will be applied to by default
A code security configuration
object
The ID of the code security configuration
The name of the code security configuration. Must be unique within the organization.
The type of the code security configuration.
A description of the code security configuration
The enablement status of GitHub Advanced Security
The enablement status of Dependency Graph
The enablement status of Automatic dependency submission
Feature options for Automatic dependency submission
object
Whether to use runners labeled with ‘dependency-submission’ or standard GitHub runners.
The enablement status of Dependabot alerts
The enablement status of Dependabot security updates
The enablement status of Dependabot delegated alert dismissal
Feature options for code scanning
object
Whether to allow repos which use advanced setup
The enablement status of code scanning default setup
Feature options for code scanning default setup
object
Whether to use labeled runners or standard GitHub runners.
The label of the runner to use for code scanning when runner_type is ‘labeled’.
The enablement status of code scanning delegated alert dismissal
The enablement status of secret scanning
The enablement status of secret scanning push protection
The enablement status of secret scanning delegated bypass
Feature options for secret scanning delegated bypass
object
The bypass reviewers for secret scanning delegated bypass
object
The ID of the team or role selected as a bypass reviewer
The type of the bypass reviewer
The bypass mode for the reviewer
The ID of the security configuration associated with this bypass reviewer
The enablement status of secret scanning validity checks
The enablement status of secret scanning non-provider patterns
The enablement status of Copilot secret scanning
The enablement status of secret scanning delegated alert dismissal
The enablement status of secret scanning extended metadata
The enablement status of private vulnerability reporting
The enforcement status for a security configuration
The URL of the configuration
The URL of the configuration
Examples
[ { "default_for_new_repos": "public", "configuration": { "id": 1325, "target_type": "organization", "name": "octo-org recommended settings", "description": "This is a code security configuration for octo-org", "advanced_security": "enabled", "dependency_graph": "enabled", "dependency_graph_autosubmit_action": "not_set", "dependency_graph_autosubmit_action_options": { "labeled_runners": false }, "dependabot_alerts": "enabled", "dependabot_security_updates": "not_set", "code_scanning_default_setup": "enabled", "code_scanning_default_setup_options": { "runner_type": "not_set", "runner_label": null }, "code_scanning_options": { "allow_advanced": false }, "secret_scanning": "enabled", "secret_scanning_push_protection": "enabled", "secret_scanning_delegated_bypass": "disabled", "secret_scanning_validity_checks": "enabled", "secret_scanning_non_provider_patterns": "enabled", "private_vulnerability_reporting": "enabled", "enforcement": "enforced", "url": "https://api.github.com/orgs/octo-org/code-security/configurations/1325", "html_url": "https://github.com/organizations/octo-org/settings/security_products/configurations/edit/1325", "created_at": "2024-05-01T00:00:00Z", "updated_at": "2024-05-01T00:00:00Z" } }, { "default_for_new_repos": "private_and_internal", "configuration": { "id": 17, "target_type": "global", "name": "GitHub recommended", "description": "Suggested settings for Dependabot, secret scanning, and code scanning.", "advanced_security": "enabled", "dependency_graph": "enabled", "dependency_graph_autosubmit_action": "not_set", "dependency_graph_autosubmit_action_options": { "labeled_runners": false }, "dependabot_alerts": "enabled", "dependabot_security_updates": "not_set", "code_scanning_default_setup": "enabled", "code_scanning_default_setup_options": { "runner_type": "not_set", "runner_label": null }, "code_scanning_options": { "allow_advanced": false }, "secret_scanning": "enabled", "secret_scanning_push_protection": "enabled", "secret_scanning_delegated_bypass": "disabled", "secret_scanning_validity_checks": "disabled", "private_vulnerability_reporting": "enabled", "enforcement": "enforced", "url": "https://api.github.com/orgs/octo-org/code-security/configurations/17", "html_url": "https://github.com/organizations/octo-org/settings/security_products/configurations/view", "created_at": "2023-12-04T15:58:07Z", "updated_at": "2023-12-04T15:58:07Z" } }]