import requests
url = "https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id} \
--header 'Authorization: Bearer <token>'{
"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"
}Read a pipeline authority request
One request: the run that raised it, the protected settings it asks for against the approved authority, where it stands and who decided it. Requires pipelines.read.
import requests
url = "https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/api/v1/org/pipelines/authority-requests/{id} \
--header 'Authorization: Bearer <token>'{
"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
Response
The 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