Resolve the caller's operational authority in the Environment
/portal/v1/accounts/{accountSlug}/applications/{appSlug}/environments/{envSlug}/workspace/contextThe caller's operational-administration authority in this Environment, which the Admin Workspace resolves on entry: has_access, environment_wide, accessible_node_ids and capabilities. No capability is required. A caller with no live assignment here gets has_access: false with an empty scope, not a 403. The account owner and holders of workspace.administer_all get Environment-wide access and every operational capability without needing an assignment. Everyone else gets the union of capabilities granted by the roles of their live assignments, and the node subtrees those assignments cover.
Authentication
AuthorizationJWT access token. Never send alongside X-API-Key: a request carrying both is refused.
Path Parameters
accountSlugstring Required The Account's slug. An unknown one answers 404.
appSlugstring Required The Application's slug within the Account.
envSlugstring Required The Environment's slug within the Application.
Responses
application/json
data *WorkspaceContextResponseDto
application/json
error *ApiErrorBodyDto
application/json
error *ApiErrorBodyDto
application/json
error *ApiErrorBodyDto
Returned object
curl -X GET "https://auth.canopy-io.com/portal/v1/accounts/value/applications/value/environments/value/workspace/context" \ -H "Authorization: Bearer $CANOPY_TOKEN"
{ "data": { "has_access": false, "environment_wide": false, "accessible_node_ids": [ "string" ], "capabilities": [ "string" ] } }
Tell us how we can improve this guide.