Get the recorded test timings of a repository's stage
import requests
url = "https://platform.ankra.app/api/v1/org/pipeline-repositories/{repository_id}/pipeline-tests/timings"
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/pipeline-repositories/{repository_id}/pipeline-tests/timings', 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/pipeline-repositories/{repository_id}/pipeline-tests/timings \
--header 'Authorization: Bearer <token>'{
"stage": "<string>",
"branch": "<string>",
"group_by": "file",
"runs_sampled": 1,
"is_partial": true,
"entries": [
{
"file": "<string>",
"suite": "<string>",
"name": "<string>",
"test_key": "<string>",
"duration_ms": 1,
"samples": 2
}
]
}Pipelines
Get the recorded test timings of a repository's stage
The mean recorded duration of each file or test of one stage across the newest runs of a branch, for a sharding script to balance by. Requires pipelines.read. Read-only.
GET
/
api
/
v1
/
org
/
pipeline-repositories
/
{repository_id}
/
pipeline-tests
/
timings
Get the recorded test timings of a repository's stage
import requests
url = "https://platform.ankra.app/api/v1/org/pipeline-repositories/{repository_id}/pipeline-tests/timings"
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/pipeline-repositories/{repository_id}/pipeline-tests/timings', 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/pipeline-repositories/{repository_id}/pipeline-tests/timings \
--header 'Authorization: Bearer <token>'{
"stage": "<string>",
"branch": "<string>",
"group_by": "file",
"runs_sampled": 1,
"is_partial": true,
"entries": [
{
"file": "<string>",
"suite": "<string>",
"name": "<string>",
"test_key": "<string>",
"duration_ms": 1,
"samples": 2
}
]
}Authorizations
Query Parameters
Response
The stage's test timings.