1. Docs
  2. API Reference
  3. Get hierarchy schema for the active Environment

Get hierarchy schema for the active Environment

GET/portal/v1/accounts/{accountSlug}/applications/{appSlug}/environments/{envSlug}/hierarchy-schema

Authentication

  • Bearer Token Authorization

    JWT access token

Path Parameters

Name Required Type Description
envSlugRequiredstring

Code samples

cURLJavaScriptPythonGo
curl -X GET "https://api.canopy.dev/portal/v1/accounts/{accountSlug}/applications/{appSlug}/environments/value/hierarchy-schema" \
  -H "Authorization: Bearer $CANOPY_TOKEN"

Responses

200 Hierarchy schema returned
{
  "node_types": [
    "string"
  ],
  "allowed_children": {},
  "max_depth": 0,
  "root_node_type": "string"
}

application/json

  • node_typesstring[]*
  • allowed_childrenany object*
  • max_depthnumber*
  • root_node_typestring
401 Invalid or expired token
403 This token is not authorized for this endpoint (wrong principal type — e.g., admin token on identity-only endpoint, or vice versa)
404 Environment not found in this Application

Returned object

On this page

Related endpoints

GETList Environments in an Application
POSTCreate a new Environment in an Application
GETGet a single Environment by slug
PATCHRename or re-slug an Environment
DELETEDelete an Environment
GETExport an Environment's configuration as JSON
POSTReplace an Environment's configuration from a JSON payload (destructive)
GETGet the Environment's access model
PUTSwitch the Environment's access model
PATCHUpdate hierarchy schema for the active Environment
POSTRevert this Environment from hierarchy to flat