check_k8s_auth
Checks whether an action is allowed on a Kubernetes resource. This is similar to running kubectl auth can-i.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"parent": "<parent>",
"verb": "<verb>",
"resourceType": "<resourceType>"
},
"name": "check_k8s_auth"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| verb | Yes | Required. The verb to check. e.g. "get", "list", "watch", "create", "update", "patch", "delete". | |
| parent | Yes | Required. The cluster to check authorization against. Format: projects/{project}/locations/{location}/clusters/{cluster} | |
| resource | No | Optional. The name of the resource to check. | |
| namespace | No | Optional. The namespace of the resource. If not specified, "default" is used for namespace-scoped resources. | |
| resourceType | Yes | Required. The type of resource to check. e.g. "pods", "deployments", "services". |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| errors | No | Errors encountered during auth check. | |
| result | No | The result of auth can-i check. |