Mint or rotate the application's registry robot
import requests
url = "https://platform.ankra.app/api/v1/org/applications/{application_id}/registry-robot"
payload = { "rotate": False }
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({rotate: false})
};
fetch('https://platform.ankra.app/api/v1/org/applications/{application_id}/registry-robot', 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/applications/{application_id}/registry-robot \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"rotate": false
}
'{
"changed": true,
"message": "<string>",
"needs_app_admin": true,
"robot": {
"created_at": "<string>",
"credential_name": "<string>",
"declared": true,
"host": "<string>",
"manageable": true,
"message": "<string>",
"password_secret_name": "<string>",
"project": "<string>",
"provisioned": true,
"robot_name": "<string>",
"rotated_at": "<string>",
"stale": true,
"username_secret_name": "<string>"
},
"secrets_written": true
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Applications
Mint or rotate the application's registry robot
Make sure a push robot minted for this application backs its repository login: mint one when none does (with Ankra's registry administrator on the organisation's own registry, or with image_registry.admin_credential_name on a registry the organisation operates), refresh its secret when rotate is set, store the login as the platform-managed registry credential ankra-harbor-app-<application-id>, and write it into the repository's Actions secrets. A registry Ankra cannot administer answers 200 with provisioned false and a message naming what would let it. A browser session twin is mounted at the same path without the /api/v1 prefix (cookie authentication).
POST
/
api
/
v1
/
org
/
applications
/
{application_id}
/
registry-robot
Mint or rotate the application's registry robot
import requests
url = "https://platform.ankra.app/api/v1/org/applications/{application_id}/registry-robot"
payload = { "rotate": False }
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({rotate: false})
};
fetch('https://platform.ankra.app/api/v1/org/applications/{application_id}/registry-robot', 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/applications/{application_id}/registry-robot \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"rotate": false
}
'{
"changed": true,
"message": "<string>",
"needs_app_admin": true,
"robot": {
"created_at": "<string>",
"credential_name": "<string>",
"declared": true,
"host": "<string>",
"manageable": true,
"message": "<string>",
"password_secret_name": "<string>",
"project": "<string>",
"provisioned": true,
"robot_name": "<string>",
"rotated_at": "<string>",
"stale": true,
"username_secret_name": "<string>"
},
"secrets_written": true
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Body
application/json
Response
Successful Response