import requests
url = "https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}/dismiss"
payload = { "reason": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({reason: '<string>'})
};
fetch('https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}/dismiss', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}/dismiss \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"reason": "<string>"
}
'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"repository_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"definition_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"protected_hash": "<string>",
"approved_hash": "<string>",
"run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"head_sha": "<string>",
"ref": "<string>",
"pull_request_number": 123,
"requested_by": "<string>",
"status": "pending",
"resolved_by": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_via": "portal",
"reason": "<string>",
"diff": {
"sections": [
{
"section": "<string>",
"path": "<string>",
"from": "<string>",
"to": "<string>"
}
],
"yaml": "<string>"
},
"last_refusal": {
"sender": "<string>",
"reason": "bot",
"message": "<string>",
"at": "2023-11-07T05:31:56Z"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}Dismiss a pipeline authority request
Declines a pending request with a reason the run’s check run and run page then show. Requires pipelines.manage and a human actor: a service-account token is refused. A request already approved, dismissed or superseded answers 409.
import requests
url = "https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}/dismiss"
payload = { "reason": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({reason: '<string>'})
};
fetch('https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}/dismiss', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}/dismiss \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"reason": "<string>"
}
'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"repository_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"definition_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"protected_hash": "<string>",
"approved_hash": "<string>",
"run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"head_sha": "<string>",
"ref": "<string>",
"pull_request_number": 123,
"requested_by": "<string>",
"status": "pending",
"resolved_by": "<string>",
"resolved_at": "2023-11-07T05:31:56Z",
"resolved_via": "portal",
"reason": "<string>",
"diff": {
"sections": [
{
"section": "<string>",
"path": "<string>",
"from": "<string>",
"to": "<string>"
}
],
"yaml": "<string>"
},
"last_refusal": {
"sender": "<string>",
"reason": "bot",
"message": "<string>",
"at": "2023-11-07T05:31:56Z"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
1 - 1000Response
The dismissed request.
The definition to approve: POST /api/v1/org/pipelines/definitions/{definition_id}/approve resolves this request.
Identity of the protected settings an approval grants.
Identity of the settings the raising run executed under instead; null when nothing was ever approved.
The newest pipeline run that raised or joined this request.
The principal behind the run, as <lane>:<identity> (github:, user:).
pending, approved, dismissed, superseded Ankra user id of the person who approved or dismissed it.
portal, github_check, cli, api, null The dismissal's reason; null unless dismissed.
Show child attributes
Show child attributes
The last approval press from a source-control host that was refused; null when none was.
Show child attributes
Show child attributes