Create check

Answers one policy question — may this subject take this action on this object — against the CALLER'S OWN org policy set, and answers it with a bare allow/deny.

POST /v1/authz/check

Addresshttps://api.hanzo.ai/v1/authz/check
MethodPOST
Operationpost_authz_check
AuthAuthorization: Bearer $HANZO_API_KEY

Answers one policy question — may this subject take this action on this object — against the CALLER'S OWN org policy set, and answers it with a bare allow/deny.

The org comes from the gateway-minted X-Org-Id and picks the per-org enforcer, so a decision is always rendered by that tenant's policies and never by another's. A request carrying no org is refused rather than answered from a shared or default set: collapsing tenants together is the one failure a policy engine must not have.

Body: {sub, obj, act}, all three required. The reply echoes them beside allow so a cached or logged decision carries the question it answered.

Request

The document declares no body for POST /v1/authz/check. The handler is typed in cloud but its shape is not yet emitted, so the fields are not listed here — ask MCP's describe for post_authz_check, which answers from the running route.

Response

The document declares no response body for this operation. It answers 200 on success and the platform error shape on failure — see Errors.

Examples

hanzo authz check
import { Configuration, AuthzApi } from 'hanzoai';

const api = new AuthzApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.postAuthzCheck();
from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import AuthzApi

client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = AuthzApi(client).post_authz_check()
cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)

resp, _, err := client.AuthzAPI.PostAuthzCheck(context.Background()).Execute()
if err != nil {
	return err
}
use hanzo_client::apis::{configuration::Configuration, authz_api};

let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();

let result = authz_api::post_authz_check(&cfg, Default::default()).await?;
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.AuthzApi;

ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));

var result = new AuthzApi(client).postAuthzCheck();
curl -X POST https://api.hanzo.ai/v1/authz/check \
  -H "Authorization: Bearer $HANZO_API_KEY"

MCP declares no tool for authz — tools/list on https://api.hanzo.ai/v1/mcp names the products it does reach. Use HTTP or an SDK.


Authz API · All Hanzo APIs · Interactive reference

Was this page useful?