SDK reference
Portal: resources, groups, tags and dashboards
GET/
Every resource of the org you may read, of every kind (Serverless App Services, databases, buckets, domains, repositories, agents), with its resource group and tags. q keeps those with every word in their name, details, id or tags; kind, group (a resource group id, or none) and tag (key or key=value) filter; limit caps the list (default 500). total and counts (by kind) are of every resource you may read, before filters.
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/resources' \
-H "Authorization: Bearer $CACTIVE_TOKEN"GET/
One resource with its resource group and tags.
Parameters and answerscurl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/resources/{kind}/{ref}' \
-H "Authorization: Bearer $CACTIVE_TOKEN"PUT/
Sets a resource's resource group (groupId, or null for none) and its tags (tags: up to 20 { key, value }, keys unique; replaces them all). Needs the right to change that resource.
curl -X PUT 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/resources/{kind}/{ref}' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"groupId": "<groupId>",
"tags": [
{
"key": "example",
"value": "example"
}
]
}'GET/
What happened to a resource, newest first: its entries in the org's audit log, filtered like the log (action, actor) and paged (cursor, limit). Readable by those who may read the resource.
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/resources/{kind}/{ref}/activity' \
-H "Authorization: Bearer $CACTIVE_TOKEN"GET/
Who can reach a resource: each member, their role and what that role lets them do with it (manage, change or read), and the groups whose grants widen access to a Serverless App Service or a repository. Roles are changed in Tenant.
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/resources/{kind}/{ref}/access' \
-H "Authorization: Bearer $CACTIVE_TOKEN"curl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/groups' \
-H "Authorization: Bearer $CACTIVE_TOKEN"POST/
Creates a resource group (name, optional description). Needs resources:write.
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/groups' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"name": "Example"
}'PATCH/
Renames a resource group or changes its description. Needs resources:write.
curl -X PATCH 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/groups/{resourceGroupId}' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"name": "Example",
"description": "example"
}'DELETE/
Deletes a resource group; its resources stay, outside any group. Needs resources:write.
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/groups/{resourceGroupId}' \
-H "Authorization: Bearer $CACTIVE_TOKEN"GET/
Your portal in this org: favourite services in order (null: the defaults), recent resources and the dashboard Dashboard opens. People only.
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/me' \
-H "Authorization: Bearer $CACTIVE_TOKEN"PUT/
Saves your favourite services (favourites: service keys in order, null for the defaults) or the dashboard Dashboard opens (dashboardId).
curl -X PUT 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/me' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"favourites": [
"example"
],
"dashboardId": "<dashboardId>"
}'POST/
Records that you opened a resource (kind, ref), for Recent.
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/me/recent' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"kind": "project",
"ref": "example"
}'GET/
Dashboards you can open: yours and those shared with the organization (without their tiles).
Parameters and answerscurl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/dashboards' \
-H "Authorization: Bearer $CACTIVE_TOKEN"POST/
Creates a dashboard (name, optional shared and tiles); yours alone unless shared.
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/dashboards' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"name": "Example"
}'GET/
A dashboard with its tiles.
Parameters and answerscurl 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/dashboards/{dashboardId}' \
-H "Authorization: Bearer $CACTIVE_TOKEN"PUT/
Changes a dashboard: name, shared (owners only) and tiles (replaced; positions are compacted).
curl -X PUT 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/dashboards/{dashboardId}' \
-H "Authorization: Bearer $CACTIVE_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"name": "Example",
"shared": true,
"tiles": [
{}
]
}'DELETE/
Deletes a dashboard (its owner, or for a shared one those who manage the organization).
Parameters and answerscurl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/portal/dashboards/{dashboardId}' \
-H "Authorization: Bearer $CACTIVE_TOKEN"