Docs
Live demo
GET/api/v2/targets/{id}/k8s/cluster-roles
targets:readAPI token

Retrieve discovered ClusterRoles in the Kubernetes target (cluster-scoped RBAC resources)

Parameters

Path1 required of 1
idstringpathrequired

Target ID (UUID)

Responses

200

OK

ListK8sClusterRolesResponse · 2 fields
12 fields
annotationsmap of string → string
created_atstring
discovered_atstring
field_managerstring
idstring
labelsmap of string → string
9 fields
ownership_statestringrequired
unmanagedprincipal_createdadoptedorphaned
credential_ownershipstring
externalprincipal_managedunknown
link_idstring
adopted_atstring

The rule that created a Principal-created account.

native_identity_statestring

Whether Principal recorded the account instance it created or adopted. Set only for PostgreSQL and MongoDB accounts Principal created or adopted. Principal removes the account, revokes its access or changes its password only when it is verified. Mismatch means the account was recreated outside Principal.

verifiedunverifiedmismatch
native_identity_sourcestring

How Principal recorded the account instance: created right after it created the account, adopted from discovery at adoption, or observed by the first discovery or apply that saw it.

createdadoptedobserved
managed_objectManagedObjectResponse

Rule, template or identity this Principal object belongs to. Filled by the resource explorer inventory. Absent for objects Principal does not manage.

13 fields
labelstringrequired

Short English phrase naming the object for a person, such as "Role for Data policy" or "Unused shared role of template Namespace viewer v1". Never contains IDs or hashes.

owner_kindstringrequired

What made Principal create the object.

rule_rolerule_bindingtemplate_roletemplate_bindingprofile_roleprofile_bindingservice_accountlegacydeleted_ruleother_targetunknown
rule_idstring · uuid

Rule the object belongs to. For owner_kind deleted_rule the rule no longer exists and must not be linked.

rule_namestring

Name a person gave the rule. Absent when the rule has no own name.

template_namestring

Template whose role or binding this is.

template_versioninteger

Template version the shared role or binding was created from.

template_usagestring

Whether rules of the target still use a shared template role. Absent when unknown.

in_useunused
used_by_rulesarray of ManagedObjectRuleResponse

Rules of the target whose bindings use a shared template role.

identity_idstring · uuid

Identity the object grants access to, when it exists in the organization.

identity_namestring

Display name of the identity.

object_kindstringrequired

Kubernetes kind of the object.

object_namestringrequired

Raw Kubernetes object name, for technical details and copying only.

namespacestring

Namespace of a namespaced object.

namestring
resource_versionstring
rulesarray of K8sRBACRuleResponse
4 fields
api_groupsarray of string
resource_namesarray of string
resourcesarray of string
verbsarray of string
target_idstring
totalinteger

Common errors: 400 401 403 404 429 504. They mean the same for every operation, see Errors.

↑ ↓ to moveEnter to openEsc to close