Create a login intent for the calling agent
/agent/v1/login_intents● SupportedReturns
201
Only for yourself, and only for your own computer: the agent, its organization and its platform computer all come from the credential and the agent's record, and the request body accepts no field at all (place included), so this call can be aimed neither at another agent nor at somebody else's computer. The member driving the session must be that agent's sponsor: the code becomes a thirty-day cli login for the agent, so only the sponsor may open one, and a session that names no member (a terminal customer's session) is refused. A cli session is refused (a login token cannot mint another login). The code lives five minutes and is redeemed once, at the gateway, where the redeem credential rides in Authorization.
Errors follow the Anthropic error format (type / message / request_id) — see error codes
Request
curl
curl https://api.deepraxis.com/agent/v1/login_intents \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'Python
import requests
opts = dict(
base_url="https://api.deepraxis.com/agent",
api_key="$PRAXIS_API_KEY",
)
# /agent 是我们自己的 Managed Agents 形状,直接发 HTTP 请求(Bearer 认证)
resp = requests.post(
f"{opts['base_url']}/v1/login_intents",
headers={"Authorization": f"Bearer {opts['api_key']}"},
json={},
)
print(resp.status_code, resp.json())TypeScript
const opts = {
baseURL: "https://api.deepraxis.com/agent",
apiKey: "$PRAXIS_API_KEY",
};
// /agent 是我们自己的 Managed Agents 形状,直接发 HTTP 请求(Bearer 认证)
const resp = await fetch(`${opts.baseURL}/v1/login_intents`, {
method: "POST",
headers: { Authorization: `Bearer ${opts.apiKey}`, "Content-Type": "application/json" },
body: JSON.stringify({}),
});
console.log(resp.status, await resp.json());Response 201
{
"code": "pli_00000000000000000000000000000000",
"expires_at": "2026-01-01T00:05:00.000Z"
}Response
HTTP 201
The one-time login code and when it stops working; the code is answered once and never again.
application/json
| Name | Type | Description |
|---|---|---|
| code | string | The one-time login code (pli_ plus 32 Crockford base32 characters) to redeem on the agent's own computer with praxis login --intent. It lives five minutes and redeems once; store it nowhere. |
| expires_at | string | When the code stops being redeemable, in RFC 3339: five minutes after it was created. |