import requests
url = "https://api.platform.ankra.app/org/service-admission/eligibility"
headers = {"cookie": "ankra_session="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'ankra_session='}};
fetch('https://api.platform.ankra.app/org/service-admission/eligibility', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://api.platform.ankra.app/org/service-admission/eligibility \
--cookie ankra_session={
"environment": {
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"application_name": "<string>",
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_name": "<string>",
"namespace": "<string>",
"consumer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"policy": {
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"region": "<string>",
"data_boundary": "<string>",
"local_only": true,
"revision": 2,
"source": "organisation_declared",
"updated_at": "2023-11-07T05:31:56Z"
}
},
"items": [
{
"package": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"publisher_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"version": "<string>",
"capability": "<string>",
"digest": "<string>",
"first_party": true,
"created_at": "2023-11-07T05:31:56Z"
},
"reason": {
"code": "hosted_unavailable",
"message": "<string>",
"fix": "<string>"
},
"modes": [
{
"mode": "hosted",
"state": "available",
"reason": {
"code": "hosted_unavailable",
"message": "<string>",
"fix": "<string>"
},
"capacity": {
"state": "fits",
"reason": "<string>",
"plan_id": "<string>",
"quota": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
},
"committed": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
},
"transient": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
},
"required": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
}
},
"secret_inputs": [
"<string>"
],
"setting_refusals": [
{
"parameter": "<string>",
"value": 123,
"reason": {
"code": "hosted_unavailable",
"message": "<string>",
"fix": "<string>"
}
}
]
}
]
}
],
"next_cursor": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}Preview managed service eligibility (browser session)
Answers which catalogue package versions and modes one application environment - the namespace an application is, or is about to be, deployed to on a cluster - could set up right now, and for each that it cannot, the reason and what to do: a cluster that does not deploy through the Ankra native engine, a playground short of capacity, a mode that is not available (Ankra-hosted), a missing permission, and the rest a prepare refuses with. It runs the checks a prepare runs, through the same code, in a transaction it rolls back: no review is recorded, no name reserved and no review quota spent; the name is the one check it cannot make, since the name is chosen at setup. The service is previewed on the environment’s own cluster with the package’s default settings, and once more for each setting value that asks more of the environment than the default does (the PostgreSQL Production tier, which needs a node for each instance and a verified backup vault); a value a prepare would refuse is listed in the mode’s setting_refusals with its reason. An environment that is not bound yet is checked the way setup would bind it, which needs the application deployed in that namespace. Capacity the platform cannot establish reads unknown, never fits. It is a preview, not a reservation: it takes no lock, so a review quota, capacity or policy that changes before the setup is prepared can still refuse it, and the prepare answers authoritatively. Requires the applications rollout, applications.read and clusters.read on the cluster to ask, and profiles.read to read the catalogue; a member who may read but not deploy gets every mode blocked with permission_required. package_version_id checks one version; otherwise limit (default 10, at most 25) and after page the catalogue in its own order.
import requests
url = "https://api.platform.ankra.app/org/service-admission/eligibility"
headers = {"cookie": "ankra_session="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'ankra_session='}};
fetch('https://api.platform.ankra.app/org/service-admission/eligibility', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://api.platform.ankra.app/org/service-admission/eligibility \
--cookie ankra_session={
"environment": {
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"application_name": "<string>",
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_name": "<string>",
"namespace": "<string>",
"consumer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"policy": {
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"region": "<string>",
"data_boundary": "<string>",
"local_only": true,
"revision": 2,
"source": "organisation_declared",
"updated_at": "2023-11-07T05:31:56Z"
}
},
"items": [
{
"package": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"publisher_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"version": "<string>",
"capability": "<string>",
"digest": "<string>",
"first_party": true,
"created_at": "2023-11-07T05:31:56Z"
},
"reason": {
"code": "hosted_unavailable",
"message": "<string>",
"fix": "<string>"
},
"modes": [
{
"mode": "hosted",
"state": "available",
"reason": {
"code": "hosted_unavailable",
"message": "<string>",
"fix": "<string>"
},
"capacity": {
"state": "fits",
"reason": "<string>",
"plan_id": "<string>",
"quota": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
},
"committed": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
},
"transient": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
},
"required": {
"limits_cpu_millicores": 123,
"limits_memory_mib": 123,
"requests_cpu_millicores": 123,
"requests_memory_mib": 123
}
},
"secret_inputs": [
"<string>"
],
"setting_refusals": [
{
"parameter": "<string>",
"value": 123,
"reason": {
"code": "hosted_unavailable",
"message": "<string>",
"fix": "<string>"
}
}
]
}
]
}
],
"next_cursor": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}Authorizations
Query Parameters
Response
The environment, and the verdict for every mode of each package version checked.