Get statements

Reads whether one statement the platform signed about an agent still stands: live, expired, or revoked and when.

GET /v1/principal/statements/{id}

Addresshttps://api.hanzo.ai/v1/principal/statements/{id}
MethodGET
Operationget_principal_statements_by_id
AuthAuthorization: Bearer $HANZO_API_KEY

Reads whether one statement the platform signed about an agent still stands: live, expired, or revoked and when. Open to anyone — a verifier holding a TaxPrincipalCredential checks it here after checking its signature offline against GET /v1/principal/keys. The answer names nothing the statement itself does not.

Request

1 field.

FieldInTypeRequiredDescription
idpathstringyesID is the statement's jti, as its JWS carries it.

Response

StatusBodyMeaning
200principal.Statementok
defaultproblem-detailsrefused

200 body — 10 fields.

FieldInTypeAlwaysDescription
agentbodystring—Agent is the agent it is about.
expiresbodyinteger (int64)—Expires is when it stops standing, unix seconds; zero for a W-9, which stands until the form changes.
formbodystring—Form is the class of tax form it rests on: w9, w8ben or w8bene.
idbodystring—ID is the statement's jti.
issuedbodyinteger (int64)—Issued is when it was signed, unix seconds.
jwsbodystring—JWS is the signed statement itself — the credential an agent presents — answered only to the org it is about.
kindbodystring—Kind is what it states: tax.
orgbodystring—Org is the principal the agent answers to.
revokedbodyinteger (int64)—Revoked is when it was withdrawn, unix seconds; zero while it stands.
statusbodystring—Status is live, expired or revoked.

Failure carries the platform error shape — see Errors.

Examples

hanzo has no subcommand for this operation — the CLI serves only what cloud's live route table confirms. Use HTTP or an SDK.

import { Configuration, PrincipalApi } from 'hanzoai';

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

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

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

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

let result = principal_api::get_principal_statements_by_id(&cfg, Default::default()).await?;
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.PrincipalApi;

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

var result = new PrincipalApi(client).getPrincipalStatementsById();
curl https://api.hanzo.ai/v1/principal/statements/<id> \
  -H "Authorization: Bearer $HANZO_API_KEY"

MCP reaches principal through the principal tool, which names its 7 operations with its own verbs — this one among them, under a name only MCP declares. describe explains any of them:

curl -X POST https://api.hanzo.ai/v1/mcp \
  -H "Content-Type: application/json" \
  -d '{
       "jsonrpc": "2.0",
       "id": 1,
       "method": "tools/call",
       "params": {
         "name": "describe",
         "arguments": {
           "op": "list_principals"
         }
       }
     }'

Principal API · All Hanzo APIs · Interactive reference

Was this page useful?