GitHub: Repos schemas (part 2)
82 GitHub schemas with complete fields and constraints.
← Repos operations · All schemas
Get a repository rule suite — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Response |
actor_id | JSON | Optional | |
actor_id (anyOf 1) | JSON | Alternative | |
actor_id (anyOf 1) (anyOf 1) | integer | Alternative | The number that identifies the user. |
actor_id (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
actor_id (anyOf 2) | null | Alternative | |
actor_name | JSON | Optional | |
actor_name (anyOf 1) | string | Alternative | The handle for the GitHub user account. |
actor_name (anyOf 2) | null | Alternative | |
after_sha | string | Optional | The new commit SHA of the ref. |
before_sha | string | Optional | The previous commit SHA of the ref. |
evaluation_result | JSON | Optional | |
evaluation_result (anyOf 1) | string | Alternative | The result of the rule evaluations for rules with the `active` and `evaluate` enforcement statuses, demonstrating whether rules would pass or fail if all rules in the rule suite were `active`. Null if no rules with `evaluate` enforcement status were run. Known values: pass, fail, bypass |
evaluation_result (anyOf 2) | null | Alternative | |
id | JSON | Optional | |
id (anyOf 1) | integer | Alternative | The unique identifier of the rule insight. |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pushed_at | string | Optional | Format: date-time |
ref | string | Optional | The ref name that the evaluation ran on. |
repository_id | JSON | Optional | |
repository_id (anyOf 1) | integer | Alternative | The ID of the repository associated with the rule evaluation. |
repository_id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
repository_name | string | Optional | The name of the repository without the `.git` extension. |
result | string | Optional | The result of the rule evaluations for rules with the `active` enforcement status. Known values: pass, fail, bypass |
rule_evaluations | array | Optional | Details on the evaluated rules. |
rule_evaluations[] | object | Each item | |
rule_evaluations[].details | JSON | Optional | |
rule_evaluations[].details (anyOf 1) | string | Alternative | The detailed failure message for the rule. Null if the rule passed. |
rule_evaluations[].details (anyOf 2) | null | Alternative | |
rule_evaluations[].enforcement | string | Optional | The enforcement level of this rule source. Known values: active, evaluate, deleted ruleset |
rule_evaluations[].metadata | JSON | Optional | |
rule_evaluations[].metadata (anyOf 1) | object | Alternative | Additional metadata about the rule evaluation. discriminator: {"mapping": {"pull_request": "#/components/schemas/rule-suite-pull-request", "required_status_checks": "#/components/schemas/rule-suite-required-status-checks"}, "propertyName": "rule_type"} |
rule_evaluations[].metadata (anyOf 1) (anyOf 1) | Model | Alternative | Expand Get a repository rule suite — response body — rule evaluations item metadata Additional metadata about the rule evaluation Pull request rule suite metadata |
rule_evaluations[].metadata (anyOf 1) (anyOf 2) | Model | Alternative | Expand Get a repository rule suite — response body — rule evaluations item metadata Additional metadata about the rule evaluation Required status checks rule suite metadata |
rule_evaluations[].metadata (anyOf 2) | null | Alternative | |
rule_evaluations[].result | string | Optional | The result of the evaluation of the individual rule. Known values: pass, fail |
rule_evaluations[].rule_source | object | Optional | |
rule_evaluations[].rule_source.id | JSON | Optional | |
rule_evaluations[].rule_source.id (anyOf 1) | JSON | Alternative | |
rule_evaluations[].rule_source.id (anyOf 1) (anyOf 1) | integer | Alternative | The ID of the rule source. |
rule_evaluations[].rule_source.id (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
rule_evaluations[].rule_source.id (anyOf 2) | null | Alternative | |
rule_evaluations[].rule_source.name | JSON | Optional | |
rule_evaluations[].rule_source.name (anyOf 1) | string | Alternative | The name of the rule source. |
rule_evaluations[].rule_source.name (anyOf 2) | null | Alternative | |
rule_evaluations[].rule_source.type | string | Optional | The type of rule source. |
rule_evaluations[].rule_type | string | Optional | The type of rule. |
Referenced models: Get a repository rule suite — response body — rule evaluations item metadata Additional metadata about the rule evaluation Pull request rule suite metadata, Get a repository rule suite — response body — rule evaluations item metadata Additional metadata about the rule evaluation Required status checks rule suite metadata
Get a repository rule suite — response body — rule evaluations item metadata Additional metadata about the rule evaluation Pull request rule suite metadata
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Metadata for a pull request rule evaluation result. |
pull_request | object | Optional | The pull request associated with the rule evaluation. |
pull_request.id | JSON | Optional | |
pull_request.id (anyOf 1) | integer | Alternative | The unique identifier of the pull request. |
pull_request.id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pull_request.number | JSON | Optional | |
pull_request.number (anyOf 1) | integer | Alternative | The number of the pull request. |
pull_request.number (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pull_request.proof_of_presence | JSON | Optional | |
pull_request.proof_of_presence (anyOf 1) | object | Alternative | The proof of presence evaluation for the pull request. Null if proof of presence was not evaluated. |
pull_request.proof_of_presence (anyOf 1).base_sha | string | Optional | The base commit SHA the proof of presence evaluation applies to. Empty if unavailable. |
pull_request.proof_of_presence (anyOf 1).code | string | Optional | A code describing the reason for the proof of presence state. |
pull_request.proof_of_presence (anyOf 1).head_sha | string | Optional | The head commit SHA the proof of presence evaluation applies to. Empty if unavailable. |
pull_request.proof_of_presence (anyOf 1).required_level | string | Optional | The authentication level required by the rule. Empty if unavailable. |
pull_request.proof_of_presence (anyOf 1).state | string | Optional | The state of the proof of presence evaluation. |
pull_request.proof_of_presence (anyOf 1).verified_at | string | Optional | The time proof of presence was verified, in ISO 8601 format. Empty if proof of presence has not been completed. |
pull_request.proof_of_presence (anyOf 1).verified_level | string | Optional | The authentication level that was verified. Empty if proof of presence has not been completed. |
pull_request.proof_of_presence (anyOf 1).verifier | JSON | Optional | |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 1) | object | Alternative | The user who provided proof of presence. Null if no proof of presence was recorded. |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 1).id | JSON | Optional | |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 1).id (anyOf 1) | integer | Alternative | The unique identifier of the user. |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 1).id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 1).login | string | Optional | The handle for the GitHub user account. |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 1).type | string | Optional | The type of the user. |
pull_request.proof_of_presence (anyOf 1).verifier (anyOf 2) | null | Alternative | |
pull_request.proof_of_presence (anyOf 2) | null | Alternative | |
pull_request.reviews | array | Optional | The reviews associated with the pull request. |
pull_request.reviews[] | object | Each item | |
pull_request.reviews[].id | JSON | Optional | |
pull_request.reviews[].id (anyOf 1) | integer | Alternative | The unique identifier of the review. |
pull_request.reviews[].id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pull_request.reviews[].state | string | Optional | The state of the review. |
pull_request.reviews[].user | object | Optional | The user who submitted the review. |
pull_request.reviews[].user.id | JSON | Optional | |
pull_request.reviews[].user.id (anyOf 1) | integer | Alternative | The unique identifier of the user. |
pull_request.reviews[].user.id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pull_request.reviews[].user.login | string | Optional | The handle for the GitHub user account. |
pull_request.reviews[].user.type | string | Optional | The type of the user. |
pull_request.user | object | Optional | The user who created the pull request. |
pull_request.user.id | JSON | Optional | |
pull_request.user.id (anyOf 1) | integer | Alternative | The unique identifier of the user. |
pull_request.user.id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
pull_request.user.login | string | Optional | The handle for the GitHub user account. |
pull_request.user.type | string | Optional | The type of the user. |
Get a repository rule suite — response body — rule evaluations item metadata Additional metadata about the rule evaluation Required status checks rule suite metadata
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Metadata for a required status checks rule evaluation result. |
checks | array | Optional | The status checks associated with the rule evaluation. |
checks[] | object | Each item | |
checks[].app | JSON | Optional | |
checks[].app (anyOf 1) | object | Alternative | The GitHub App associated with the status check. |
checks[].app (anyOf 1).id | JSON | Optional | |
checks[].app (anyOf 1).id (anyOf 1) | integer | Alternative | The unique identifier of the GitHub App. |
checks[].app (anyOf 1).id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
checks[].app (anyOf 1).name | string | Optional | The name of the GitHub App. |
checks[].app (anyOf 1).slug | string | Optional | The slug of the GitHub App. |
checks[].app (anyOf 2) | null | Alternative | |
checks[].context | string | Optional | The context name of the status check. |
checks[].id | JSON | Optional | |
checks[].id (anyOf 1) | integer | Alternative | The unique identifier of the status check. |
checks[].id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
checks[].state | string | Optional | The state of the status check. |
checks[].type | string | Optional | The type of the status check. |
Get a repository ruleset — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A set of rules to apply when specified conditions are met. |
_links | object | Optional | |
_links.html | JSON | Optional | |
_links.html (anyOf 1) | object | Alternative | |
_links.html (anyOf 1).href | string | Optional | The html URL of the ruleset |
_links.html (anyOf 2) | null | Alternative | |
_links.self | object | Optional | |
_links.self.href | string | Optional | The URL of the ruleset |
bypass_actors | array | Optional | The actors that can bypass the rules in this ruleset |
bypass_actors[] | Model | Each item | Expand Get a repository ruleset — response body — bypass actors item |
conditions | JSON | Optional | |
conditions (anyOf 1) | JSON | Alternative | |
conditions (anyOf 1) (anyOf 1) | Model | Alternative | Expand Create a repository ruleset — request body — body conditions |
conditions (anyOf 1) (anyOf 2) | Model | Alternative | Expand Get a repository ruleset — response body — conditions value Organization ruleset conditions |
conditions (anyOf 2) | null | Alternative | |
created_at | string | Optional | Format: date-time |
current_user_can_bypass | string | Optional | The bypass type of the user making the API request for this ruleset. This field is only returned when querying the repository-level endpoint. Known values: always, pull_requests_only, never, exempt |
enforcement | string | Required within parent | The enforcement level of the ruleset. `evaluate` allows admins to test rules before enforcing them. Admins can view insights on the Rule Insights page (`evaluate` is only available with GitHub Enterprise). Known values: disabled, active, evaluate |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | The ID of the ruleset |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
name | string | Required within parent | The name of the ruleset |
node_id | string | Optional | |
rules | array | Optional | |
rules[] | Model | Each item | Expand Get a repository ruleset — response body — rules item |
source | string | Required within parent | The name of the source |
source_type | string | Optional | The type of the source of the ruleset Known values: Repository, Organization, Enterprise |
target | string | Optional | The target of the ruleset Known values: branch, tag, push, repository |
updated_at | string | Optional | Format: date-time |
Referenced models: Get a repository ruleset — response body — conditions value Organization ruleset conditions, Get a repository ruleset — response body — rules item, Get a repository ruleset — response body — bypass actors item, Create a repository ruleset — request body — body conditions
Get a repository ruleset — response body — bypass actors item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | An actor that can bypass rules in a ruleset |
actor_id | JSON | Optional | |
actor_id (anyOf 1) | JSON | Alternative | |
actor_id (anyOf 1) (anyOf 1) | integer | Alternative | The ID of the actor that can bypass a ruleset. Required for `Integration`, `RepositoryRole`, `Team`, and `User` actor types. If `actor_type` is `OrganizationAdmin`, `actor_id` is ignored. If `actor_type` is `DeployKey`, this should be null. `OrganizationAdmin` is not applicable for personal repositories. |
actor_id (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
actor_id (anyOf 2) | null | Alternative | |
actor_type | string | Required within parent | The type of actor that can bypass a ruleset. Known values: Integration, OrganizationAdmin, RepositoryRole, Team, DeployKey, User |
bypass_mode | string | Optional | When the specified actor can bypass the ruleset. `pull_request` means that an actor can only bypass rules on pull requests. `pull_request` is not applicable for the `DeployKey` actor type. Also, `pull_request` is only applicable to branch rulesets. When `bypass_mode` is `exempt`, rules will not be run for that actor and a bypass audit entry will not be created. Known values: always, pull_request, exempt Default: always |
Get a repository ruleset — response body — conditions value Organization ruleset conditions
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Conditions for an organization ruleset. The branch and tag rulesets conditions object should contain both `repository_name` and `ref_name` properties, or both `repository_id` and `ref_name` properties, or both `repository_property` and `ref_name` properties. The push rulesets conditions object does not require the `ref_name` property. For repository policy rulesets, the conditions object should only contain the `repository_name`, the `repository_id`, or the `repository_property`. |
$ (anyOf 1) | object | Alternative | Conditions to target repositories by name and refs by name |
$ (anyOf 1) (allOf 1) | Model | All variants apply | Expand Create a repository ruleset — request body — body conditions |
$ (anyOf 1) (allOf 2) | Model | All variants apply | Expand Create an organization Actions policy — request body — body conditions repository name, workflow path Repository ruleset conditions for repository names |
$ (anyOf 2) | object | Alternative | Conditions to target repositories by id and refs by name |
$ (anyOf 2) (allOf 1) | Model | All variants apply | Expand Create a repository ruleset — request body — body conditions |
$ (anyOf 2) (allOf 2) | Model | All variants apply | Expand Get a repository Actions policy — response body — conditions value Organization Actions policy conditions repository id, workflow path Repository ruleset conditions for repository I Ds |
$ (anyOf 3) | object | Alternative | Conditions to target repositories by property and refs by name |
$ (anyOf 3) (allOf 1) | Model | All variants apply | Expand Create a repository ruleset — request body — body conditions |
$ (anyOf 3) (allOf 2) | Model | All variants apply | Expand Get a repository Actions policy — response body — conditions value Organization Actions policy conditions repository property, workflow path Repository ruleset conditions for repository properties |
Referenced models: Create a repository ruleset — request body — body conditions, Get a repository Actions policy — response body — conditions value Organization Actions policy conditions repository id, workflow path Repository ruleset conditions for repository I Ds, Create an organization Actions policy — request body — body conditions repository name, workflow path Repository ruleset conditions for repository names, Get a repository Actions policy — response body — conditions value Organization Actions policy conditions repository property, workflow path Repository ruleset conditions for repository properties
Get a repository ruleset — response body — rules item
Referenced models: Get a repository ruleset — response body — rules item branch name pattern, Get a repository ruleset — response body — rules item code coverage, Get a repository ruleset — response body — rules item code quality, Get a repository ruleset — response body — rules item code scanning, Get a repository ruleset — response body — rules item commit author email pattern, Get a repository ruleset — response body — rules item commit message pattern, Get a repository ruleset — response body — rules item committer email pattern, Get a repository ruleset — response body — rules item copilot code review, Get a repository ruleset — response body — rules item creation, Get a repository ruleset — response body — rules item deletion, Get a repository ruleset — response body — rules item file extension restriction, Get a repository ruleset — response body — rules item file path restriction, Get a repository ruleset — response body — rules item license compliance scanning, Get a repository ruleset — response body — rules item max file path length, Get a repository ruleset — response body — rules item max file size, Get a repository ruleset — response body — rules item merge queue, Get a repository ruleset — response body — rules item non fast forward, Get a repository ruleset — response body — rules item pull request, Get a repository ruleset — response body — rules item required deployments, Get a repository ruleset — response body — rules item required linear history, Get a repository ruleset — response body — rules item required signatures, Get a repository ruleset — response body — rules item required status checks, Get a repository ruleset — response body — rules item tag name pattern, Get a repository ruleset — response body — rules item update, Get a repository ruleset — response body — rules item workflows
Get a repository ruleset — response body — rules item branch name pattern
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Parameters to be used for the branch_name_pattern rule |
parameters | object | Optional | |
parameters.name | string | Optional | How this rule appears when configuring it. |
parameters.negate | boolean | Optional | If true, the rule will fail if the pattern matches. |
parameters.operator | string | Required within parent | The operator to use for matching. Known values: starts_with, ends_with, contains, regex |
parameters.pattern | string | Required within parent | The pattern to match with. |
type | string | Required within parent | Known values: branch_name_pattern |
Get a repository ruleset — response body — rules item code coverage
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Enforce minimum line coverage thresholds on pull requests. This rule evaluates uploaded coverage data but does not wait for coverage uploads. To ensure coverage is evaluated before merging, make each status check associated with a coverage upload a required status check. |
parameters | object | Optional | |
parameters.max_coverage_drop | JSON | Optional | |
parameters.max_coverage_drop (anyOf 1) | number | Alternative | The maximum percentage points that line coverage may drop relative to the default branch. Pull requests that reduce line coverage by more than this amount will be blocked. Format: float Maximum: 100.0 Minimum: 0.0 |
parameters.max_coverage_drop (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
parameters.minimum_coverage | JSON | Optional | |
parameters.minimum_coverage (anyOf 1) | number | Alternative | The absolute minimum line coverage percentage required. Pull requests with line coverage below this threshold will be blocked. Format: float Maximum: 100.0 Minimum: 0.0 |
parameters.minimum_coverage (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | Known values: code_coverage |
Get a repository ruleset — response body — rules item code quality
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Choose which severity levels of code quality results should block pull request merges. When configured, a code quality analysis must be done on the pull request before the changes can be merged. |
parameters | object | Optional | |
parameters.severity | string | Required within parent | The lowest severity level at which code quality reviews need to be resolved before commits can be merged. Known values: errors, warnings, notes, all |
type | string | Required within parent | Known values: code_quality |
Get a repository ruleset — response body — rules item code scanning
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Choose which tools must provide code scanning results before the reference is updated. When configured, code scanning must be enabled and have results for both the commit and the reference being updated. |
parameters | object | Optional | |
parameters.code_scanning_tools | array | Required within parent | Tools that must provide code scanning results for this rule to pass. |
parameters.code_scanning_tools[] | Model | Each item | Expand Get a repository ruleset — response body — rules item code scanning parameters code scanning tools item |
type | string | Required within parent | Known values: code_scanning |
Referenced models: Get a repository ruleset — response body — rules item code scanning parameters code scanning tools item
Get a repository ruleset — response body — rules item code scanning parameters code scanning tools item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A tool that must provide code scanning results for this rule to pass. |
alerts_threshold | string | Required within parent | The severity level at which code scanning results that raise alerts block a reference update. For more information on alert severity levels, see "[About code scanning alerts](https://docs.github.com/code-security/code-scanning/managing-code-scanning-alerts/about-code-scanning-alerts#about-alert-severity-and-security-severity-levels)." Known values: none, errors, errors_and_warnings, all |
security_alerts_threshold | string | Required within parent | The severity level at which code scanning results that raise security alerts block a reference update. For more information on security severity levels, see "[About code scanning alerts](https://docs.github.com/code-security/code-scanning/managing-code-scanning-alerts/about-code-scanning-alerts#about-alert-severity-and-security-severity-levels)." Known values: none, critical, high_or_higher, medium_or_higher, all |
tool | string | Required within parent | The name of a code scanning tool |
Get a repository ruleset — response body — rules item commit author email pattern
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Parameters to be used for the commit_author_email_pattern rule |
parameters | object | Optional | |
parameters.name | string | Optional | How this rule appears when configuring it. |
parameters.negate | boolean | Optional | If true, the rule will fail if the pattern matches. |
parameters.operator | string | Required within parent | The operator to use for matching. Known values: starts_with, ends_with, contains, regex |
parameters.pattern | string | Required within parent | The pattern to match with. |
type | string | Required within parent | Known values: commit_author_email_pattern |
Get a repository ruleset — response body — rules item commit message pattern
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Parameters to be used for the commit_message_pattern rule |
parameters | object | Optional | |
parameters.name | string | Optional | How this rule appears when configuring it. |
parameters.negate | boolean | Optional | If true, the rule will fail if the pattern matches. |
parameters.operator | string | Required within parent | The operator to use for matching. Known values: starts_with, ends_with, contains, regex |
parameters.pattern | string | Required within parent | The pattern to match with. |
type | string | Required within parent | Known values: commit_message_pattern |
Get a repository ruleset — response body — rules item committer email pattern
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Parameters to be used for the committer_email_pattern rule |
parameters | object | Optional | |
parameters.name | string | Optional | How this rule appears when configuring it. |
parameters.negate | boolean | Optional | If true, the rule will fail if the pattern matches. |
parameters.operator | string | Required within parent | The operator to use for matching. Known values: starts_with, ends_with, contains, regex |
parameters.pattern | string | Required within parent | The pattern to match with. |
type | string | Required within parent | Known values: committer_email_pattern |
Get a repository ruleset — response body — rules item copilot code review
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Request Copilot code review for new pull requests automatically if the author has access to Copilot code review and AI credits. |
parameters | object | Optional | |
parameters.review_draft_pull_requests | boolean | Optional | Copilot automatically reviews draft pull requests before they are marked as ready for review. |
parameters.review_on_push | boolean | Optional | Copilot automatically reviews each new push to the pull request. |
type | string | Required within parent | Known values: copilot_code_review |
Get a repository ruleset — response body — rules item creation
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Only allow users with bypass permission to create matching refs. |
type | string | Required within parent | Known values: creation |
Get a repository ruleset — response body — rules item deletion
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Only allow users with bypass permissions to delete matching refs. |
type | string | Required within parent | Known values: deletion |
Get a repository ruleset — response body — rules item file extension restriction
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Prevent commits that include files with specified file extensions from being pushed to the commit graph. |
parameters | object | Optional | |
parameters.restricted_file_extensions | array | Required within parent | The file extensions that are restricted from being pushed to the commit graph. |
parameters.restricted_file_extensions[] | string | Each item | |
type | string | Required within parent | Known values: file_extension_restriction |
Get a repository ruleset — response body — rules item file path restriction
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Prevent commits that include changes in specified file and folder paths from being pushed to the commit graph. This includes absolute paths that contain file names. |
parameters | object | Optional | |
parameters.ignored_file_paths | array | Optional | Files matching these patterns are allowed even when they also match a restricted path. |
parameters.ignored_file_paths[] | string | Each item | |
parameters.restricted_file_paths | array | Required within parent | The file paths that are restricted from being pushed to the commit graph. |
parameters.restricted_file_paths[] | string | Each item | |
type | string | Required within parent | Known values: file_path_restriction |
Get a repository ruleset — response body — rules item license compliance scanning
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Enforce any added or changed dependencies to comply with the organization's license policy. |
type | string | Required within parent | Known values: license_compliance_scanning |
Get a repository ruleset — response body — rules item max file path length
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Prevent commits that include file paths that exceed the specified character limit from being pushed to the commit graph. |
parameters | object | Optional | |
parameters.max_file_path_length | JSON | Required within parent | |
parameters.max_file_path_length (anyOf 1) | integer | Alternative | The maximum amount of characters allowed in file paths. Maximum: 32767 Minimum: 1 |
parameters.max_file_path_length (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | Known values: max_file_path_length |
Get a repository ruleset — response body — rules item max file size
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Prevent commits with individual files that exceed the specified limit from being pushed to the commit graph. |
parameters | object | Optional | |
parameters.ignored_file_paths | array | Optional | Files matching these patterns may exceed the maximum size. |
parameters.ignored_file_paths[] | string | Each item | |
parameters.max_file_size | JSON | Required within parent | |
parameters.max_file_size (anyOf 1) | integer | Alternative | The maximum file size allowed in megabytes. This limit does not apply to Git Large File Storage (Git LFS). Maximum: 100 Minimum: 1 |
parameters.max_file_size (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | Known values: max_file_size |
Get a repository ruleset — response body — rules item merge queue
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Merges must be performed via a merge queue. |
parameters | object | Optional | |
parameters.check_response_timeout_minutes | JSON | Required within parent | |
parameters.check_response_timeout_minutes (anyOf 1) | integer | Alternative | Maximum time for a required status check to report a conclusion. After this much time has elapsed, checks that have not reported a conclusion will be assumed to have failed Maximum: 360 Minimum: 1 |
parameters.check_response_timeout_minutes (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
parameters.grouping_strategy | string | Required within parent | When set to ALLGREEN, the merge commit created by merge queue for each PR in the group must pass all required checks to merge. When set to HEADGREEN, only the commit at the head of the merge group, i.e. the commit containing changes from all of the PRs in the group, must pass its required checks to merge. Known values: ALLGREEN, HEADGREEN |
parameters.max_entries_to_build | JSON | Required within parent | |
parameters.max_entries_to_build (anyOf 1) | integer | Alternative | Limit the number of queued pull requests requesting checks and workflow runs at the same time. Maximum: 100 Minimum: 0 |
parameters.max_entries_to_build (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
parameters.max_entries_to_merge | JSON | Required within parent | |
parameters.max_entries_to_merge (anyOf 1) | integer | Alternative | The maximum number of PRs that will be merged together in a group. Maximum: 100 Minimum: 0 |
parameters.max_entries_to_merge (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
parameters.merge_method | string | Required within parent | Method to use when merging changes from queued pull requests. Known values: MERGE, SQUASH, REBASE |
parameters.min_entries_to_merge | JSON | Required within parent | |
parameters.min_entries_to_merge (anyOf 1) | integer | Alternative | The minimum number of PRs that will be merged together in a group. Maximum: 100 Minimum: 0 |
parameters.min_entries_to_merge (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
parameters.min_entries_to_merge_wait_minutes | JSON | Required within parent | |
parameters.min_entries_to_merge_wait_minutes (anyOf 1) | integer | Alternative | The time merge queue should wait after the first PR is added to the queue for the minimum group size to be met. After this time has elapsed, the minimum group size will be ignored and a smaller group will be merged. Maximum: 360 Minimum: 0 |
parameters.min_entries_to_merge_wait_minutes (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | Known values: merge_queue |
Get a repository ruleset — response body — rules item non fast forward
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Prevent users with push access from force pushing to refs. |
type | string | Required within parent | Known values: non_fast_forward |
Get a repository ruleset — response body — rules item pull request
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Require all commits be made to a non-target branch and submitted via a pull request before they can be merged. |
parameters | object | Optional | |
parameters.allowed_merge_methods | array | Optional | Array of allowed merge methods. Allowed values include `merge`, `squash`, and `rebase`. At least one option must be enabled. |
parameters.allowed_merge_methods[] | string | Each item | Known values: merge, squash, rebase |
parameters.dismiss_stale_reviews_on_push | boolean | Required within parent | New, reviewable commits pushed will dismiss previous pull request review approvals. |
parameters.dismissal_restriction | Model | Optional | Expand Get a repository ruleset — response body — rules item pull request parameters dismissal restriction |
parameters.require_code_owner_review | boolean | Required within parent | Require an approving review in pull requests that modify files that have a designated code owner. |
parameters.require_extra_approval_for_unattributed_changes | boolean | Optional | When Copilot opens a pull request without a human collaborator, require one more approving review if a non-zero approval count is required. |
parameters.require_last_push_approval | boolean | Required within parent | Whether the most recent reviewable push must be approved by someone other than the person who pushed it. |
parameters.required_approving_review_count | JSON | Required within parent | |
parameters.required_approving_review_count (anyOf 1) | integer | Alternative | The number of approving reviews that are required before a pull request can be merged. Maximum: 10 Minimum: 0 |
parameters.required_approving_review_count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
parameters.required_review_thread_resolution | boolean | Required within parent | All conversations on code must be resolved before a pull request can be merged. |
parameters.required_reviewers | array | Optional | A collection of reviewers and associated file patterns. Each reviewer has a list of file patterns which determine the files that reviewer is required to review. |
parameters.required_reviewers[] | Model | Each item | Expand Get a repository ruleset — response body — rules item pull request parameters required reviewers item |
type | string | Required within parent | Known values: pull_request |
Referenced models: Get a repository ruleset — response body — rules item pull request parameters dismissal restriction, Get a repository ruleset — response body — rules item pull request parameters required reviewers item
Get a repository ruleset — response body — rules item pull request parameters dismissal restriction
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Specify people, teams, or apps allowed to dismiss pull request reviews. |
allowed_actors | array | Optional | Specify people, teams, or apps allowed to dismiss pull request reviews. |
allowed_actors[] | Model | Each item | Expand Get a repository ruleset — response body — rules item pull request parameters dismissal restriction allowed actors item |
enabled | boolean | Required within parent | Whether to restrict review dismissal to specific actors. |
Referenced models: Get a repository ruleset — response body — rules item pull request parameters dismissal restriction allowed actors item
Get a repository ruleset — response body — rules item pull request parameters dismissal restriction allowed actors item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | An actor allowed to dismiss pull request reviews |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | ID of the actor that can dismiss reviews. |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | The type of the actor Known values: User, Team, IntegrationInstallation, RepositoryRole |
Get a repository ruleset — response body — rules item pull request parameters required reviewers item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A reviewing team, and file patterns describing which files they must approve changes to. |
file_patterns | array | Required within parent | Array of file patterns. Pull requests which change matching files must be approved by the specified team. File patterns use fnmatch syntax. |
file_patterns[] | string | Each item | |
minimum_approvals | JSON | Required within parent | |
minimum_approvals (anyOf 1) | integer | Alternative | Minimum number of approvals required from the specified team. If set to zero, the team will be added to the pull request but approval is optional. |
minimum_approvals (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
reviewer | Model | Required within parent | Expand Get a repository ruleset — response body — rules item pull request parameters required reviewers item reviewer |
Referenced models: Get a repository ruleset — response body — rules item pull request parameters required reviewers item reviewer
Get a repository ruleset — response body — rules item pull request parameters required reviewers item reviewer
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A required reviewing team |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | ID of the reviewer which must review changes to matching files. |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | The type of the reviewer Known values: Team |
Get a repository ruleset — response body — rules item required deployments
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Choose which environments must be successfully deployed to before refs can be pushed into a ref that matches this rule. |
parameters | object | Optional | |
parameters.required_deployment_environments | array | Required within parent | The environments that must be successfully deployed to before branches can be merged. |
parameters.required_deployment_environments[] | string | Each item | |
type | string | Required within parent | Known values: required_deployments |
Get a repository ruleset — response body — rules item required linear history
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Prevent merge commits from being pushed to matching refs. |
type | string | Required within parent | Known values: required_linear_history |
Get a repository ruleset — response body — rules item required signatures
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Commits pushed to matching refs must have verified signatures. |
type | string | Required within parent | Known values: required_signatures |
Get a repository ruleset — response body — rules item required status checks
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Choose which status checks must pass before the ref is updated. When enabled, commits must first be pushed to another ref where the checks pass. |
parameters | object | Optional | |
parameters.do_not_enforce_on_create | boolean | Optional | Allow repositories and branches to be created if a check would otherwise prohibit it. |
parameters.required_status_checks | array | Required within parent | Status checks that are required. |
parameters.required_status_checks[] | Model | Each item | Expand Get a repository ruleset — response body — rules item required status checks parameters required status checks item |
parameters.strict_required_status_checks_policy | boolean | Required within parent | Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled. |
type | string | Required within parent | Known values: required_status_checks |
Referenced models: Get a repository ruleset — response body — rules item required status checks parameters required status checks item
Get a repository ruleset — response body — rules item required status checks parameters required status checks item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Required status check |
context | string | Required within parent | The status check context name that must be present on the commit. |
integration_id | JSON | Optional | |
integration_id (anyOf 1) | integer | Alternative | The optional integration ID that this status check must originate from. |
integration_id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get a repository ruleset — response body — rules item tag name pattern
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Parameters to be used for the tag_name_pattern rule |
parameters | object | Optional | |
parameters.name | string | Optional | How this rule appears when configuring it. |
parameters.negate | boolean | Optional | If true, the rule will fail if the pattern matches. |
parameters.operator | string | Required within parent | The operator to use for matching. Known values: starts_with, ends_with, contains, regex |
parameters.pattern | string | Required within parent | The pattern to match with. |
type | string | Required within parent | Known values: tag_name_pattern |
Get a repository ruleset — response body — rules item update
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Only allow users with bypass permission to update matching refs. |
parameters | object | Optional | |
parameters.update_allows_fetch_and_merge | boolean | Required within parent | Branch can pull changes from its upstream repository |
type | string | Required within parent | Known values: update |
Get a repository ruleset — response body — rules item workflows
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Require all changes made to a targeted branch to pass the specified workflows before they can be merged. |
parameters | object | Optional | |
parameters.do_not_enforce_on_create | boolean | Optional | Allow repositories and branches to be created if a check would otherwise prohibit it. |
parameters.workflows | array | Required within parent | Workflows that must pass for this rule to pass. |
parameters.workflows[] | Model | Each item | Expand Get a repository ruleset — response body — rules item workflows parameters workflows item |
type | string | Required within parent | Known values: workflows |
Referenced models: Get a repository ruleset — response body — rules item workflows parameters workflows item
Get a repository ruleset — response body — rules item workflows parameters workflows item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A workflow that must run for this rule to pass |
path | string | Required within parent | The path to the workflow file |
ref | string | Optional | The ref (branch or tag) of the workflow file to use |
repository_id | JSON | Required within parent | |
repository_id (anyOf 1) | integer | Alternative | The ID of the repository where the workflow is defined |
repository_id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
sha | string | Optional | The commit SHA of the workflow file to use |
Get a repository webhook — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Webhooks for repositories. |
active | boolean | Required within parent | Determines whether the hook is actually triggered on pushes. |
config | Model | Required within parent | Expand Get a webhook configuration for a repository — response body |
created_at | string | Required within parent | Format: date-time |
deliveries_url | string | Optional | Format: uri |
events | array | Required within parent | Determines what events the hook is triggered for. Default: ['push']. |
events[] | string | Each item | |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | Unique identifier of the webhook. |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
last_response | Model | Required within parent | Expand Get a repository webhook — response body — last response |
name | string | Required within parent | The name of a valid service, use 'web' for a webhook. |
ping_url | string | Required within parent | Format: uri |
test_url | string | Required within parent | Format: uri |
type | string | Required within parent | |
updated_at | string | Required within parent | Format: date-time |
url | string | Required within parent | Format: uri |
Referenced models: Get a repository webhook — response body — last response, Get a webhook configuration for a repository — response body
Get a repository webhook — response body — last response
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
code | JSON | Required within parent | |
code (anyOf 1) | JSON | Alternative | |
code (anyOf 1) (anyOf 1) | integer | Alternative | |
code (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
code (anyOf 2) | null | Alternative | |
message | JSON | Required within parent | |
message (anyOf 1) | string | Alternative | |
message (anyOf 2) | null | Alternative | |
status | JSON | Required within parent | |
status (anyOf 1) | string | Alternative | |
status (anyOf 2) | null | Alternative |
Get a webhook configuration for a repository — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Configuration object of the webhook |
content_type | string | Optional | The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`. |
insecure_ssl | Model | Optional | Expand Get a webhook configuration for a repository — response body — insecure ssl |
secret | string | Optional | If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/webhooks/event-payloads/#delivery-headers). |
url | string | Optional | The URL to which the payloads will be delivered. Format: uri |
Referenced models: Get a webhook configuration for a repository — response body — insecure ssl
Get a webhook configuration for a repository — response body — insecure ssl
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | string | Alternative | Determines whether the SSL certificate of the host for `url` will be verified when delivering payloads. Supported values include `0` (verification is performed) and `1` (verification is not performed). The default is `0`. **We strongly recommend not setting this to `1` as you are subject to man-in-the-middle and other attacks.** |
$ (anyOf 2) | JSON | Alternative | |
$ (anyOf 2) (anyOf 1) | number | Alternative | |
$ (anyOf 2) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get access restrictions — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Branch Restriction Policy |
apps | array | Required within parent | |
apps[] | object | Each item | |
apps[].client_id | string | Optional | |
apps[].created_at | string | Optional | |
apps[].description | string | Optional | |
apps[].events | array | Optional | |
apps[].events[] | string | Each item | |
apps[].external_url | string | Optional | |
apps[].html_url | string | Optional | |
apps[].id | JSON | Optional | |
apps[].id (anyOf 1) | integer | Alternative | |
apps[].id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
apps[].name | string | Optional | |
apps[].node_id | string | Optional | |
apps[].owner | object | Optional | |
apps[].owner.avatar_url | string | Optional | |
apps[].owner.description | string | Optional | |
apps[].owner.events_url | string | Optional | |
apps[].owner.followers_url | string | Optional | |
apps[].owner.following_url | string | Optional | |
apps[].owner.gists_url | string | Optional | |
apps[].owner.gravatar_id | string | Optional | |
apps[].owner.hooks_url | string | Optional | |
apps[].owner.html_url | string | Optional | |
apps[].owner.id | JSON | Optional | |
apps[].owner.id (anyOf 1) | integer | Alternative | |
apps[].owner.id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
apps[].owner.issues_url | string | Optional | |
apps[].owner.login | string | Optional | |
apps[].owner.members_url | string | Optional | |
apps[].owner.node_id | string | Optional | |
apps[].owner.organizations_url | string | Optional | |
apps[].owner.public_members_url | string | Optional | |
apps[].owner.received_events_url | string | Optional | |
apps[].owner.repos_url | string | Optional | |
apps[].owner.site_admin | boolean | Optional | |
apps[].owner.starred_url | string | Optional | |
apps[].owner.subscriptions_url | string | Optional | |
apps[].owner.type | string | Optional | |
apps[].owner.url | string | Optional | |
apps[].owner.user_view_type | string | Optional | |
apps[].permissions | object | Optional | |
apps[].permissions.contents | string | Optional | |
apps[].permissions.issues | string | Optional | |
apps[].permissions.metadata | string | Optional | |
apps[].permissions.single_file | string | Optional | |
apps[].slug | string | Optional | |
apps[].updated_at | string | Optional | |
apps_url | string | Required within parent | Format: uri |
teams | array | Required within parent | |
teams[] | Model | Each item | Expand List teams — response body — item |
teams_url | string | Required within parent | Format: uri |
url | string | Required within parent | Format: uri |
users | array | Required within parent | |
users[] | object | Each item | |
users[].avatar_url | string | Optional | |
users[].events_url | string | Optional | |
users[].followers_url | string | Optional | |
users[].following_url | string | Optional | |
users[].gists_url | string | Optional | |
users[].gravatar_id | string | Optional | |
users[].html_url | string | Optional | |
users[].id | JSON | Optional | |
users[].id (anyOf 1) | integer | Alternative | Format: int64 |
users[].id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
users[].login | string | Optional | |
users[].node_id | string | Optional | |
users[].organizations_url | string | Optional | |
users[].received_events_url | string | Optional | |
users[].repos_url | string | Optional | |
users[].site_admin | boolean | Optional | |
users[].starred_url | string | Optional | |
users[].subscriptions_url | string | Optional | |
users[].type | string | Optional | |
users[].url | string | Optional | |
users[].user_view_type | string | Optional | |
users_url | string | Required within parent | Format: uri |
Referenced models: List teams — response body — item
Get admin branch protection — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Protected Branch Admin Enforced |
enabled | boolean | Required within parent | |
url | string | Required within parent | Format: uri |
Get all contributor commit activity — response body — value array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Contributor Activity |
author | Model | Required within parent | Expand Get an issue — response body — user |
total | JSON | Required within parent | |
total (anyOf 1) | integer | Alternative | |
total (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
weeks | array | Required within parent | |
weeks[] | object | Each item | |
weeks[].a | JSON | Optional | |
weeks[].a (anyOf 1) | integer | Alternative | |
weeks[].a (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
weeks[].c | JSON | Optional | |
weeks[].c (anyOf 1) | integer | Alternative | |
weeks[].c (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
weeks[].d | JSON | Optional | |
weeks[].d (anyOf 1) | integer | Alternative | |
weeks[].d (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
weeks[].w | JSON | Optional | |
weeks[].w (anyOf 1) | integer | Alternative | |
weeks[].w (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Referenced models: Get an issue — response body — user
Get all custom property values for a repository — response body — item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Custom property name and associated value |
property_name | string | Required within parent | The name of the property |
value | JSON | Required within parent | |
value (anyOf 1) | JSON | Alternative | The value assigned to the property |
value (anyOf 1) (anyOf 1) | JSON | Alternative | |
value (anyOf 1) (anyOf 1) (anyOf 1) | string | Alternative | |
value (anyOf 1) (anyOf 1) (anyOf 2) | null | Alternative | |
value (anyOf 1) (anyOf 2) | array | Alternative | |
value (anyOf 1) (anyOf 2)[] | string | Each item | |
value (anyOf 2) | null | Alternative |
Get all repository topics — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A topic aggregates entities that are related to a subject. |
names | array | Required within parent | |
names[] | string | Each item |
Get an autolink reference of a repository — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | An autolink reference. |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
is_alphanumeric | boolean | Required within parent | Whether this autolink reference matches alphanumeric characters. If false, this autolink reference only matches numeric characters. |
key_prefix | string | Required within parent | The prefix of a key that is linkified. |
updated_at | JSON | Optional | |
updated_at (anyOf 1) | string | Alternative | Format: date-time |
updated_at (anyOf 2) | null | Alternative | |
url_template | string | Required within parent | A template for the target URL that is generated if a key was found. |
Get an environment — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Details of a deployment environment |
created_at | string | Required within parent | The time that the environment was created, in ISO 8601 format. Format: date-time |
deployment_branch_policy | Model | Optional | Expand Get an environment — response body — deployment branch policy |
html_url | string | Required within parent | |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | The id of the environment. Format: int64 |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
name | string | Required within parent | The name of the environment. |
node_id | string | Required within parent | |
protection_rules | array | Optional | Built-in deployment protection rules for the environment. |
protection_rules[] | JSON | Each item | |
protection_rules[] (anyOf 1) | object | Alternative | |
protection_rules[] (anyOf 1).id | JSON | Required within parent | |
protection_rules[] (anyOf 1).id (anyOf 1) | integer | Alternative | |
protection_rules[] (anyOf 1).id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
protection_rules[] (anyOf 1).node_id | string | Required within parent | |
protection_rules[] (anyOf 1).type | string | Required within parent | |
protection_rules[] (anyOf 1).wait_timer | Model | Optional | Expand Get an environment — response body — protection rules item id, node id, type, wait timer wait timer |
protection_rules[] (anyOf 2) | object | Alternative | |
protection_rules[] (anyOf 2).id | JSON | Required within parent | |
protection_rules[] (anyOf 2).id (anyOf 1) | integer | Alternative | |
protection_rules[] (anyOf 2).id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
protection_rules[] (anyOf 2).node_id | string | Required within parent | |
protection_rules[] (anyOf 2).prevent_self_review | boolean | Optional | Whether deployments to this environment can be approved by the user who created the deployment. |
protection_rules[] (anyOf 2).reviewers | array | Optional | The people or teams that may approve jobs that reference the environment. You can list up to six users or teams as reviewers. The reviewers must have at least read access to the repository. Only one of the required reviewers needs to approve the job for it to proceed. |
protection_rules[] (anyOf 2).reviewers[] | object | Each item | |
protection_rules[] (anyOf 2).reviewers[].reviewer | JSON | Optional | |
protection_rules[] (anyOf 2).reviewers[].reviewer (anyOf 1) | Model | Alternative | Expand List users — response body — item |
protection_rules[] (anyOf 2).reviewers[].reviewer (anyOf 2) | Model | Alternative | Expand List teams — response body — item |
protection_rules[] (anyOf 2).reviewers[].type | string | Optional | The type of reviewer. Known values: User, Team |
protection_rules[] (anyOf 2).type | string | Required within parent | |
protection_rules[] (anyOf 3) | object | Alternative | |
protection_rules[] (anyOf 3).id | JSON | Required within parent | |
protection_rules[] (anyOf 3).id (anyOf 1) | integer | Alternative | |
protection_rules[] (anyOf 3).id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
protection_rules[] (anyOf 3).node_id | string | Required within parent | |
protection_rules[] (anyOf 3).type | string | Required within parent | |
updated_at | string | Required within parent | The time that the environment was last updated, in ISO 8601 format. Format: date-time |
url | string | Required within parent |
Referenced models: Get an environment — response body — deployment branch policy, List users — response body — item, List teams — response body — item, Get an environment — response body — protection rules item id, node id, type, wait timer wait timer
Get an environment — response body — deployment branch policy
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | object | Alternative | The type of deployment branch policy for this environment. To allow all branches to deploy, set to `null`. |
$ (anyOf 1).custom_branch_policies | boolean | Required within parent | Whether only branches that match the specified name patterns can deploy to this environment. If `custom_branch_policies` is `true`, `protected_branches` must be `false`; if `custom_branch_policies` is `false`, `protected_branches` must be `true`. |
$ (anyOf 1).protected_branches | boolean | Required within parent | Whether only branches with branch protection rules can deploy to this environment. If `protected_branches` is `true`, `custom_branch_policies` must be `false`; if `protected_branches` is `false`, `custom_branch_policies` must be `true`. |
$ (anyOf 2) | null | Alternative |
Get an environment — response body — protection rules item id, node id, type, wait timer wait timer
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | integer | Alternative | The amount of time to delay a job after the job is initially triggered. The time (in minutes) must be an integer between 0 and 43,200 (30 days). |
$ (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get branch protection — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Branch Protection |
allow_deletions | object | Optional | |
allow_deletions.enabled | boolean | Optional | |
allow_force_pushes | object | Optional | |
allow_force_pushes.enabled | boolean | Optional | |
allow_fork_syncing | object | Optional | Whether users can pull changes from upstream when the branch is locked. Set to `true` to allow fork syncing. Set to `false` to prevent fork syncing. |
allow_fork_syncing.enabled | boolean | Optional | Default: false |
block_creations | object | Optional | |
block_creations.enabled | boolean | Optional | |
enabled | boolean | Optional | |
enforce_admins | Model | Optional | Expand Get admin branch protection — response body |
lock_branch | object | Optional | Whether to set the branch as read-only. If this is true, users will not be able to push to the branch. |
lock_branch.enabled | boolean | Optional | Default: false |
name | string | Optional | |
protection_url | string | Optional | |
required_conversation_resolution | object | Optional | |
required_conversation_resolution.enabled | boolean | Optional | |
required_linear_history | object | Optional | |
required_linear_history.enabled | boolean | Optional | |
required_pull_request_reviews | Model | Optional | Expand Get pull request review protection — response body |
required_signatures | object | Optional | |
required_signatures.enabled | boolean | Required within parent | |
required_signatures.url | string | Required within parent | Format: uri |
required_status_checks | Model | Optional | Expand Get branch protection — response body — required status checks |
restrictions | Model | Optional | Expand Get access restrictions — response body |
url | string | Optional |
Referenced models: Get access restrictions — response body, Get admin branch protection — response body, Get pull request review protection — response body, Get branch protection — response body — required status checks
Get branch protection — response body — required status checks
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Protected Branch Required Status Check |
checks | array | Required within parent | |
checks[] | object | Each item | |
checks[].app_id | JSON | Required within parent | |
checks[].app_id (anyOf 1) | JSON | Alternative | |
checks[].app_id (anyOf 1) (anyOf 1) | integer | Alternative | |
checks[].app_id (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
checks[].app_id (anyOf 2) | null | Alternative | |
checks[].context | string | Required within parent | |
contexts | array | Required within parent | |
contexts[] | string | Each item | |
contexts_url | string | Optional | |
enforcement_level | string | Optional | |
strict | boolean | Optional | |
url | string | Optional |
Get community profile metrics — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Community Profile |
content_reports_enabled | boolean | Optional | |
description | JSON | Required within parent | |
description (anyOf 1) | string | Alternative | |
description (anyOf 2) | null | Alternative | |
documentation | JSON | Required within parent | |
documentation (anyOf 1) | string | Alternative | |
documentation (anyOf 2) | null | Alternative | |
files | Model | Required within parent | Expand Get community profile metrics — response body — files |
health_percentage | JSON | Required within parent | |
health_percentage (anyOf 1) | integer | Alternative | |
health_percentage (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
updated_at | JSON | Required within parent | |
updated_at (anyOf 1) | string | Alternative | Format: date-time |
updated_at (anyOf 2) | null | Alternative |
Referenced models: Get community profile metrics — response body — files
Get community profile metrics — response body — files
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
code_of_conduct | Model | Required within parent | Expand Get community profile metrics — response body — files code of conduct |
code_of_conduct_file | Model | Required within parent | Expand Get community profile metrics — response body — files readme |
contributing | Model | Required within parent | Expand Get community profile metrics — response body — files readme |
issue_template | Model | Required within parent | Expand Get community profile metrics — response body — files readme |
license | Model | Required within parent | Expand Create a fork — response body — license |
pull_request_template | Model | Required within parent | Expand Get community profile metrics — response body — files readme |
readme | Model | Required within parent | Expand Get community profile metrics — response body — files readme |
Referenced models: Get community profile metrics — response body — files code of conduct, Get community profile metrics — response body — files readme, Create a fork — response body — license
Get community profile metrics — response body — files code of conduct
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | object | Alternative | Code of Conduct Simple |
$ (anyOf 1).html_url | JSON | Required within parent | |
$ (anyOf 1).html_url (anyOf 1) | string | Alternative | Format: uri |
$ (anyOf 1).html_url (anyOf 2) | null | Alternative | |
$ (anyOf 1).key | string | Required within parent | |
$ (anyOf 1).name | string | Required within parent | |
$ (anyOf 1).url | string | Required within parent | Format: uri |
$ (anyOf 2) | null | Alternative |
Get community profile metrics — response body — files readme
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | object | Alternative | |
$ (anyOf 1).html_url | string | Required within parent | Format: uri |
$ (anyOf 1).url | string | Required within parent | Format: uri |
$ (anyOf 2) | null | Alternative |
Get page views — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | View Traffic |
count | JSON | Required within parent | |
count (anyOf 1) | integer | Alternative | |
count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
uniques | JSON | Required within parent | |
uniques (anyOf 1) | integer | Alternative | |
uniques (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
views | array | Required within parent | |
views[] | Model | Each item | Expand Get page views — response body — views item |
Referenced models: Get page views — response body — views item
Get page views — response body — views item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
count | JSON | Required within parent | |
count (anyOf 1) | integer | Alternative | |
count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
timestamp | string | Required within parent | Format: date-time |
uniques | JSON | Required within parent | |
uniques (anyOf 1) | integer | Alternative | |
uniques (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get pull request review protection — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Protected Branch Pull Request Review |
bypass_pull_request_allowances | object | Optional | Allow specific users, teams, or apps to bypass pull request requirements. |
bypass_pull_request_allowances.apps | array | Optional | The list of apps allowed to bypass pull request requirements. |
bypass_pull_request_allowances.apps[] | Model | Each item | Expand Get an app — response body |
bypass_pull_request_allowances.teams | array | Optional | The list of teams allowed to bypass pull request requirements. |
bypass_pull_request_allowances.teams[] | Model | Each item | Expand List teams — response body — item |
bypass_pull_request_allowances.users | array | Optional | The list of users allowed to bypass pull request requirements. |
bypass_pull_request_allowances.users[] | Model | Each item | Expand List users — response body — item |
dismiss_stale_reviews | boolean | Required within parent | |
dismissal_restrictions | object | Optional | |
dismissal_restrictions.apps | array | Optional | The list of apps with review dismissal access. |
dismissal_restrictions.apps[] | Model | Each item | Expand Get an app — response body |
dismissal_restrictions.teams | array | Optional | The list of teams with review dismissal access. |
dismissal_restrictions.teams[] | Model | Each item | Expand List teams — response body — item |
dismissal_restrictions.teams_url | string | Optional | |
dismissal_restrictions.url | string | Optional | |
dismissal_restrictions.users | array | Optional | The list of users with review dismissal access. |
dismissal_restrictions.users[] | Model | Each item | Expand List users — response body — item |
dismissal_restrictions.users_url | string | Optional | |
require_code_owner_reviews | boolean | Required within parent | |
require_last_push_approval | boolean | Optional | Whether the most recent push must be approved by someone other than the person who pushed it. Default: false |
required_approving_review_count | JSON | Optional | |
required_approving_review_count (anyOf 1) | integer | Alternative | Maximum: 6 Minimum: 0 |
required_approving_review_count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
url | string | Optional | Format: uri |
Referenced models: Get an app — response body, List users — response body — item, List teams — response body — item
Get repository clones — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Clone Traffic |
clones | array | Required within parent | |
clones[] | Model | Each item | Expand Get page views — response body — views item |
count | JSON | Required within parent | |
count (anyOf 1) | integer | Alternative | |
count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
uniques | JSON | Required within parent | |
uniques (anyOf 1) | integer | Alternative | |
uniques (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Referenced models: Get page views — response body — views item
Get repository content — response body — Content Directory
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | array | Root | A list of directory items |
$[] | object | Each item | |
$[]._links | object | Required within parent | |
$[]._links.git | JSON | Required within parent | |
$[]._links.git (anyOf 1) | string | Alternative | Format: uri |
$[]._links.git (anyOf 2) | null | Alternative | |
$[]._links.html | JSON | Required within parent | |
$[]._links.html (anyOf 1) | string | Alternative | Format: uri |
$[]._links.html (anyOf 2) | null | Alternative | |
$[]._links.self | string | Required within parent | Format: uri |
$[].content | string | Optional | |
$[].download_url | JSON | Required within parent | |
$[].download_url (anyOf 1) | string | Alternative | Format: uri |
$[].download_url (anyOf 2) | null | Alternative | |
$[].git_url | JSON | Required within parent | |
$[].git_url (anyOf 1) | string | Alternative | Format: uri |
$[].git_url (anyOf 2) | null | Alternative | |
$[].html_url | JSON | Required within parent | |
$[].html_url (anyOf 1) | string | Alternative | Format: uri |
$[].html_url (anyOf 2) | null | Alternative | |
$[].name | string | Required within parent | |
$[].path | string | Required within parent | |
$[].sha | string | Required within parent | |
$[].size | JSON | Required within parent | |
$[].size (anyOf 1) | integer | Alternative | |
$[].size (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
$[].type | string | Required within parent | Known values: dir, file, submodule, symlink |
$[].url | string | Required within parent | Format: uri |
Get repository content — response body — Submodule Content
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | An object describing a submodule |
_links | object | Required within parent | |
_links.git | JSON | Required within parent | |
_links.git (anyOf 1) | string | Alternative | Format: uri |
_links.git (anyOf 2) | null | Alternative | |
_links.html | JSON | Required within parent | |
_links.html (anyOf 1) | string | Alternative | Format: uri |
_links.html (anyOf 2) | null | Alternative | |
_links.self | string | Required within parent | Format: uri |
download_url | JSON | Required within parent | |
download_url (anyOf 1) | string | Alternative | Format: uri |
download_url (anyOf 2) | null | Alternative | |
git_url | JSON | Required within parent | |
git_url (anyOf 1) | string | Alternative | Format: uri |
git_url (anyOf 2) | null | Alternative | |
html_url | JSON | Required within parent | |
html_url (anyOf 1) | string | Alternative | Format: uri |
html_url (anyOf 2) | null | Alternative | |
name | string | Required within parent | |
path | string | Required within parent | |
sha | string | Required within parent | |
size | JSON | Required within parent | |
size (anyOf 1) | integer | Alternative | |
size (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
submodule_git_url | string | Required within parent | Format: uri |
type | string | Required within parent | Known values: submodule |
url | string | Required within parent | Format: uri |
Get repository content — response body — Symlink Content
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | An object describing a symlink |
_links | object | Required within parent | |
_links.git | JSON | Required within parent | |
_links.git (anyOf 1) | string | Alternative | Format: uri |
_links.git (anyOf 2) | null | Alternative | |
_links.html | JSON | Required within parent | |
_links.html (anyOf 1) | string | Alternative | Format: uri |
_links.html (anyOf 2) | null | Alternative | |
_links.self | string | Required within parent | Format: uri |
download_url | JSON | Required within parent | |
download_url (anyOf 1) | string | Alternative | Format: uri |
download_url (anyOf 2) | null | Alternative | |
git_url | JSON | Required within parent | |
git_url (anyOf 1) | string | Alternative | Format: uri |
git_url (anyOf 2) | null | Alternative | |
html_url | JSON | Required within parent | |
html_url (anyOf 1) | string | Alternative | Format: uri |
html_url (anyOf 2) | null | Alternative | |
name | string | Required within parent | |
path | string | Required within parent | |
sha | string | Required within parent | |
size | JSON | Required within parent | |
size (anyOf 1) | integer | Alternative | |
size (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
target | string | Required within parent | |
type | string | Required within parent | Known values: symlink |
url | string | Required within parent | Format: uri |
Get repository permissions for a user — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Repository Collaborator Permission |
permission | string | Required within parent | |
role_name | string | Required within parent | |
user | Model | Required within parent | Expand Get repository permissions for a user — response body — user |
Referenced models: Get repository permissions for a user — response body — user
Get repository permissions for a user — response body — user
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | Model | Alternative | Expand Get repository permissions for a user — response body — user Collaborator |
$ (anyOf 2) | null | Alternative |
Referenced models: Get repository permissions for a user — response body — user Collaborator
Get repository permissions for a user — response body — user Collaborator
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Collaborator |
avatar_url | string | Required within parent | Format: uri |
email | JSON | Optional | |
email (anyOf 1) | string | Alternative | |
email (anyOf 2) | null | Alternative | |
events_url | string | Required within parent | |
followers_url | string | Required within parent | Format: uri |
following_url | string | Required within parent | |
gists_url | string | Required within parent | |
gravatar_id | JSON | Required within parent | |
gravatar_id (anyOf 1) | string | Alternative | |
gravatar_id (anyOf 2) | null | Alternative | |
html_url | string | Required within parent | Format: uri |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | Format: int64 |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
login | string | Required within parent | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | |
name (anyOf 2) | null | Alternative | |
node_id | string | Required within parent | |
organizations_url | string | Required within parent | Format: uri |
permissions | object | Optional | |
permissions.admin | boolean | Required within parent | |
permissions.maintain | boolean | Optional | |
permissions.pull | boolean | Required within parent | |
permissions.push | boolean | Required within parent | |
permissions.triage | boolean | Optional | |
received_events_url | string | Required within parent | Format: uri |
repos_url | string | Required within parent | Format: uri |
role_name | string | Required within parent | |
site_admin | boolean | Required within parent | |
starred_url | string | Required within parent | |
subscriptions_url | string | Required within parent | Format: uri |
type | string | Required within parent | |
url | string | Required within parent | Format: uri |
user_view_type | string | Optional |
Get repository ruleset history — response body — item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | The historical version of a ruleset |
actor | object | Required within parent | The actor who updated the ruleset |
actor.id | JSON | Optional | |
actor.id (anyOf 1) | integer | Alternative | |
actor.id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
actor.type | string | Optional | |
updated_at | string | Required within parent | Format: date-time |
version_id | JSON | Required within parent | |
version_id (anyOf 1) | integer | Alternative | The ID of the previous version of the ruleset |
version_id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get repository ruleset version — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (allOf 1) | Model | All variants apply | Expand Get repository ruleset history — response body — item |
$ (allOf 2) | object | All variants apply | |
$ (allOf 2).state | object | Required within parent | The state of the ruleset version |
Referenced models: Get repository ruleset history — response body — item
Get rules for a branch — response body — item
Referenced models: Get a repository ruleset — response body — rules item branch name pattern, Get a repository ruleset — response body — rules item code coverage, Get a repository ruleset — response body — rules item code quality, Get a repository ruleset — response body — rules item code scanning, Get a repository ruleset — response body — rules item commit author email pattern, Get a repository ruleset — response body — rules item commit message pattern, Get a repository ruleset — response body — rules item committer email pattern, Get a repository ruleset — response body — rules item copilot code review, Get a repository ruleset — response body — rules item creation, Get a repository ruleset — response body — rules item deletion, Get a repository ruleset — response body — rules item file extension restriction, Get a repository ruleset — response body — rules item file path restriction, Get a repository ruleset — response body — rules item license compliance scanning, Get a repository ruleset — response body — rules item max file path length, Get a repository ruleset — response body — rules item max file size, Get a repository ruleset — response body — rules item merge queue, Get a repository ruleset — response body — rules item non fast forward, Get a repository ruleset — response body — rules item pull request, Get a repository ruleset — response body — rules item required deployments, Get a repository ruleset — response body — rules item required linear history, Get a repository ruleset — response body — rules item required signatures, Get a repository ruleset — response body — rules item required status checks, Get rules for a branch — response body — item / ruleset_source_type: Repository, Organization, type: update repository ruleset data for rule, Get a repository ruleset — response body — rules item tag name pattern, Get a repository ruleset — response body — rules item update, Get a repository ruleset — response body — rules item workflows
Get rules for a branch — response body — item / ruleset_source_type: Repository, Organization, type: update repository ruleset data for rule
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | User-defined metadata to store domain-specific information limited to 8 keys with scalar values. |
ruleset_id | JSON | Optional | |
ruleset_id (anyOf 1) | integer | Alternative | The ID of the ruleset that includes this rule. |
ruleset_id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
ruleset_source | string | Optional | The name of the source of the ruleset that includes this rule. |
ruleset_source_type | string | Optional | The type of source for the ruleset that includes this rule. Known values: Repository, Organization |
Get status checks protection — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Status Check Policy |
checks | array | Required within parent | |
checks[] | object | Each item | |
checks[].app_id | JSON | Required within parent | |
checks[].app_id (anyOf 1) | JSON | Alternative | |
checks[].app_id (anyOf 1) (anyOf 1) | integer | Alternative | |
checks[].app_id (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
checks[].app_id (anyOf 2) | null | Alternative | |
checks[].context | string | Required within parent | |
contexts | array | Required within parent | |
contexts[] | string | Each item | |
contexts_url | string | Required within parent | Format: uri |
strict | boolean | Required within parent | |
url | string | Required within parent | Format: uri |
Get the combined status for a specific reference — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Combined Commit Status |
commit_url | string | Required within parent | Format: uri |
repository | Model | Required within parent | Expand Transfer a repository — response body |
sha | string | Required within parent | |
state | string | Required within parent | |
statuses | array | Required within parent | |
statuses[] | Model | Each item | Expand Get the combined status for a specific reference — response body — statuses item |
total_count | JSON | Required within parent | |
total_count (anyOf 1) | integer | Alternative | |
total_count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
url | string | Required within parent | Format: uri |
Referenced models: Transfer a repository — response body, Get the combined status for a specific reference — response body — statuses item
Get the combined status for a specific reference — response body — statuses item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
avatar_url | JSON | Required within parent | |
avatar_url (anyOf 1) | string | Alternative | Format: uri |
avatar_url (anyOf 2) | null | Alternative | |
context | string | Required within parent | |
created_at | string | Required within parent | Format: date-time |
description | JSON | Required within parent | |
description (anyOf 1) | string | Alternative | |
description (anyOf 2) | null | Alternative | |
id | JSON | Required within parent | |
id (anyOf 1) | integer | Alternative | |
id (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
node_id | string | Required within parent | |
required | JSON | Optional | |
required (anyOf 1) | boolean | Alternative | |
required (anyOf 2) | null | Alternative | |
state | string | Required within parent | |
target_url | JSON | Required within parent | |
target_url (anyOf 1) | string | Alternative | Format: uri |
target_url (anyOf 2) | null | Alternative | |
updated_at | string | Required within parent | Format: date-time |
url | string | Required within parent | Format: uri |
Get the hash algorithm for a repository — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Repository hash algorithm |
hash_algorithm | string | Required within parent | The Git hash algorithm used by this repository. Known values: sha1, sha256 |
Get the hourly commit count for each day — response body — array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | array | Root | Code Frequency Stat |
$[] | JSON | Each item | |
$[] (anyOf 1) | integer | Alternative | |
$[] (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get the last year of commit activity — response body — value array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Commit Activity |
days | array | Required within parent | |
days[] | JSON | Each item | |
days[] (anyOf 1) | integer | Alternative | |
days[] (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
total | JSON | Required within parent | |
total (anyOf 1) | integer | Alternative | |
total (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
week | JSON | Required within parent | |
week (anyOf 1) | integer | Alternative | |
week (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get the status of a Git Hub Pages deployment — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
status | string | Optional | The current status of the deployment. Known values: deployment_in_progress, syncing_files, finished_file_sync, updating_pages, purging_cdn, deployment_cancelled, deployment_failed, deployment_content_failed, deployment_attempt_error, deployment_lost, succeed |
Get the weekly commit count — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
all | array | Required within parent | |
all[] | JSON | Each item | |
all[] (anyOf 1) | integer | Alternative | |
all[] (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
owner | array | Required within parent | |
owner[] | JSON | Each item | |
owner[] (anyOf 1) | integer | Alternative | |
owner[] (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get top referral paths — response body — item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Content Traffic |
count | JSON | Required within parent | |
count (anyOf 1) | integer | Alternative | |
count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
path | string | Required within parent | |
title | string | Required within parent | |
uniques | JSON | Required within parent | |
uniques (anyOf 1) | integer | Alternative | |
uniques (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Get top referral sources — response body — item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Referrer Traffic |
count | JSON | Required within parent | |
count (anyOf 1) | integer | Alternative | |
count (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
referrer | string | Required within parent | |
uniques | JSON | Required within parent | |
uniques (anyOf 1) | integer | Alternative | |
uniques (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |