From a45a14f4d225ab8012f6866c9dcf23257b532bb9 Mon Sep 17 00:00:00 2001 From: github-openapi-bot <69533958+github-openapi-bot@users.noreply.github.com> Date: Thu, 18 Nov 2021 06:06:42 -0500 Subject: [PATCH] Update OpenAPI Descriptions --- lib/rest/static/decorated/api.github.com.json | 290 +++++++++++++++++- lib/rest/static/decorated/ghes-3.0.json | 290 +++++++++++++++++- lib/rest/static/decorated/ghes-3.1.json | 290 +++++++++++++++++- lib/rest/static/decorated/ghes-3.2.json | 290 +++++++++++++++++- lib/rest/static/decorated/ghes-3.3.json | 290 +++++++++++++++++- lib/rest/static/decorated/github.ae.json | 290 +++++++++++++++++- .../dereferenced/api.github.com.deref.json | 141 +++++++++ .../static/dereferenced/ghes-3.0.deref.json | 122 ++++++++ .../static/dereferenced/ghes-3.1.deref.json | 141 +++++++++ .../static/dereferenced/ghes-3.2.deref.json | 141 +++++++++ .../static/dereferenced/ghes-3.3.deref.json | 141 +++++++++ .../static/dereferenced/github.ae.deref.json | 122 ++++++++ 12 files changed, 2524 insertions(+), 24 deletions(-) diff --git a/lib/rest/static/decorated/api.github.com.json b/lib/rest/static/decorated/api.github.com.json index 5d85ff2a50fe..fa38d8fd9039 100644 --- a/lib/rest/static/decorated/api.github.com.json +++ b/lib/rest/static/decorated/api.github.com.json @@ -38237,13 +38237,13 @@ "x-codeSamples": [ { "lang": "Shell", - "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://api.github.com/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'", - "html": "
curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://api.github.com/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
+ "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://api.github.com/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'",
+ "html": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://api.github.com/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
},
{
"lang": "JavaScript",
- "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
- "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
+ "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
+ "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
}
],
"summary": "Update branch protection",
@@ -38288,6 +38288,64 @@
"rawType": "array",
"rawDescription": "The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.",
"childParamsGroups": []
+ },
+ "checks": {
+ "type": "array of objects",
+ "description": "The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
+ "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'",
+ "html": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
},
{
"lang": "JavaScript",
- "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
- "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
+ "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
+ "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
}
],
"summary": "Update branch protection",
@@ -36186,6 +36186,64 @@
"rawType": "array",
"rawDescription": "The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.",
"childParamsGroups": []
+ },
+ "checks": {
+ "type": "array of objects",
+ "description": "The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
+ "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'",
+ "html": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
},
{
"lang": "JavaScript",
- "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
- "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
+ "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
+ "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
}
],
"summary": "Update branch protection",
@@ -36308,6 +36308,64 @@
"rawType": "array",
"rawDescription": "The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.",
"childParamsGroups": []
+ },
+ "checks": {
+ "type": "array of objects",
+ "description": "The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
+ "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'",
+ "html": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
},
{
"lang": "JavaScript",
- "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
- "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
+ "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
+ "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
}
],
"summary": "Update branch protection",
@@ -37554,6 +37554,64 @@
"rawType": "array",
"rawDescription": "The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.",
"childParamsGroups": []
+ },
+ "checks": {
+ "type": "array of objects",
+ "description": "The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
+ "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'",
+ "html": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n http(s)://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
},
{
"lang": "JavaScript",
- "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
- "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
+ "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
+ "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
}
],
"summary": "Update branch protection",
@@ -37790,6 +37790,64 @@
"rawType": "array",
"rawDescription": "The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.",
"childParamsGroups": []
+ },
+ "checks": {
+ "type": "array of objects",
+ "description": "The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
+ "source": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'",
+ "html": "curl \\\n -X PUT \\\n -H \"Accept: application/vnd.github.v3+json\" \\\n https://{hostname}/api/v3/repos/octocat/hello-world/branches/BRANCH/protection \\\n -d '{\"required_status_checks\":{\"strict\":true,\"contexts\":[\"contexts\"],\"checks\":[{\"context\":\"context\",\"app_id\":\"app_id\"}]},\"enforce_admins\":true,\"required_pull_request_reviews\":{\"dismissal_restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"]},\"dismiss_stale_reviews\":true,\"require_code_owner_reviews\":true,\"required_approving_review_count\":42},\"restrictions\":{\"users\":[\"users\"],\"teams\":[\"teams\"],\"apps\":[\"apps\"]}}'
"
},
{
"lang": "JavaScript",
- "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
- "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
+ "source": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})",
+ "html": "await octokit.request('PUT /repos/{owner}/{repo}/branches/{branch}/protection', {\n owner: 'octocat',\n repo: 'hello-world',\n branch: 'branch',\n required_status_checks: {\n strict: true,\n contexts: [\n 'contexts'\n ],\n checks: [\n {\n context: 'context',\n app_id: 'app_id'\n }\n ]\n },\n enforce_admins: true,\n required_pull_request_reviews: {\n dismissal_restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ]\n },\n dismiss_stale_reviews: true,\n require_code_owner_reviews: true,\n required_approving_review_count: 42\n },\n restrictions: {\n users: [\n 'users'\n ],\n teams: [\n 'teams'\n ],\n apps: [\n 'apps'\n ]\n }\n})\n
"
}
],
"summary": "Update branch protection",
@@ -29558,6 +29558,64 @@
"rawType": "array",
"rawDescription": "The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.",
"childParamsGroups": []
+ },
+ "checks": {
+ "type": "array of objects",
+ "description": "The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The list of status checks to require in order to merge into this branch.
", + "items": { + "type": "object", + "properties": { + "context": { + "type": "string", + "description": "The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + "app_id": { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.
The name of the required check
", + "name": "context", + "in": "body", + "rawType": "string", + "rawDescription": "The name of the required check", + "childParamsGroups": [] + }, + { + "type": "string", + "description": "The ID of the GitHub App that must provide this check. Set to null
to accept the check from any source.