Get a code security configuration
Gets a code security configuration available in an organization.
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 write:org scope to use this endpoint.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”The organization name. The name is not case sensitive.
The unique identifier of the code security configuration.
Responses
Section titled “ Responses ”Response
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
{ "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": "enabled", "dependency_graph_autosubmit_action_options": { "labeled_runners": false }, "dependabot_alerts": "enabled", "dependabot_security_updates": "not_set", "code_scanning_default_setup": "disabled", "code_scanning_default_setup_options": { "runner_type": "not_set", "runner_label": null }, "code_scanning_options": { "allow_advanced": false }, "code_scanning_delegated_alert_dismissal": "disabled", "secret_scanning": "enabled", "secret_scanning_push_protection": "enabled", "secret_scanning_delegated_bypass": "enabled", "secret_scanning_delegated_bypass_options": { "reviewers": [ { "security_configuration_id": 1325, "reviewer_id": 5678, "reviewer_type": "TEAM" } ] }, "secret_scanning_validity_checks": "disabled", "secret_scanning_non_provider_patterns": "disabled", "secret_scanning_generic_secrets": "disabled", "secret_scanning_delegated_alert_dismissal": "disabled", "private_vulnerability_reporting": "disabled", "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"}Not modified
Forbidden
Basic Error
object
Example generated
{ "message": "example", "documentation_url": "example", "url": "example", "status": "example"}Resource not found
Basic Error
object
Example generated
{ "message": "example", "documentation_url": "example", "url": "example", "status": "example"}