List invitations
Returns your organization's invitations, newest first — who has been asked to join, on what terms, and how many seats each invitation still has left.
GET /v1/iam/invitations
| Address | https://api.hanzo.ai/v1/iam/invitations |
| Method | GET |
| Operation | get_iam_invitations |
| Auth | Authorization: Bearer $HANZO_API_KEY |
Returns your organization's invitations, newest first — who has been asked to join, on what terms, and how many seats each invitation still has left.
You see the invitations of the organization your credentials run, and no one else's: your own, or one you own or administer.
Request
1 field.
| Field | In | Type | Required | Description |
|---|---|---|---|---|
owner | query | string | — |
Response
| Status | Body | Meaning |
|---|---|---|
200 | iam.invitations.ListOutput | ok |
202 | Approval | held for approval |
default | problem-details | refused |
200 body — 24 fields.
| Field | In | Type | Always | Description |
|---|---|---|---|---|
invitations | body | iam.Invitation[] | — | |
invitations[].application | body | string | — | |
invitations[].code | body | string | — | |
invitations[].createdAt | body | string (date-time) | — | |
invitations[].createdTime | body | string | — | |
invitations[].defaultCode | body | string | — | |
invitations[].deleted | body | boolean | — | |
invitations[].displayName | body | string | — | |
invitations[].email | body | string | — | |
invitations[].generated | body | boolean | — | Generated reports that IAM minted Code itself, from crypto/rand, when the invitation was created. |
invitations[].id | body | string | — | |
invitations[].isRegexp | body | boolean | — | |
invitations[].name | body | string | — | |
invitations[].owner | body | string | — | |
invitations[].phone | body | string | — | |
invitations[].quota | body | integer (int64) | — | |
invitations[].sentTime | body | string | — | SentTime is when an email about this invitation last went to its pinned address (RFC 3339), "" when none has. |
invitations[].signupGroup | body | string | — | |
invitations[].state | body | string | — | |
invitations[].updatedAt | body | string (date-time) | — | |
invitations[].updatedTime | body | string | — | |
invitations[].usedCount | body | integer (int64) | — | |
invitations[].username | body | string | — | |
total | body | integer (int64) | — |
Failure carries the platform error shape — see Errors.
Examples
CLI
SDK
HTTP
MCP
hanzo iam invitations list.ts
.py
.go
.rs
.java
import { Configuration, IamApi } from 'hanzoai';
const api = new IamApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getIamInvitations();from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import IamApi
client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = IamApi(client).get_iam_invitations()cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)
resp, _, err := client.IamAPI.GetIamInvitations(context.Background()).Execute()
if err != nil {
return err
}use hanzo_client::apis::{configuration::Configuration, iam_api};
let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();
let result = iam_api::get_iam_invitations(&cfg, Default::default()).await?;import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.IamApi;
ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));
var result = new IamApi(client).getIamInvitations();curl https://api.hanzo.ai/v1/iam/invitations \
-H "Authorization: Bearer $HANZO_API_KEY"MCP reaches iam through the iam tool, which names its 44 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_iam_applications"
}
}
}'Was this page useful?