Connect to your daemon
Request evaluation packages (v0.1.0). They are not on npm or PyPI. After you receive the archive, install from that directory. Binaries and SDKs are not public downloads.
- AAES_ENDPOINT
- The daemon address configured with
platformd -listen. The default daemon address ishttp://127.0.0.1:8090. The daemon does not terminate TLS by default. - AAES_TOKEN
- The operator-issued bearer token. The credential resolves the tenant. The SDKs fill
tenant_idandactor_idso they match the token.
After you receive the evaluation archive, work from that directory. These examples assume a running daemon and a token associated with a registered caller. Set AAES_ENDPOINT and AAES_TOKEN first. Each example reads the capabilities the caller may use.
For routes and the HTTP contract, see the API reference and download the OpenAPI 3.1 contract. Remaining integration notes ship with the evaluation package.
Go
A zero-dependency Go 1.27 module, separate from the daemon tree. After you receive the evaluation archive, from that directory, replace the module with the supplied source:
go mod edit -replace=github.com/aaes-dev/aaes/sdk/go=./sdk/goRead permitted capabilities and handle a failed request:
package main
import (
"context"
"fmt"
"log"
aaes "github.com/aaes-dev/aaes/sdk/go"
)
func main() {
client, err := aaes.FromEnv()
if err != nil { log.Fatal(err) }
result, err := client.Capabilities(context.Background())
if err != nil { log.Fatal(err) }
fmt.Printf("%d permitted capabilities\n", len(result.Capabilities))
}Python
From the evaluation archive directory, install the supplied Python 3.12+ wheel. Its runtime uses only the standard library; annotated source and PEP 561 metadata are included:
python3 -m pip install ./aaes_sdk-0.1.0-py3-none-any.whlRead the caller's permitted capabilities:
from aaes import AaesError, Client
try:
result = Client.from_env().capabilities()
print(f"{len(result.capabilities)} permitted capabilities")
except AaesError as error:
raise SystemExit(str(error))JavaScript
From the evaluation archive directory, install the supplied ESM package for Node 24+. Public TypeScript declarations and wire response types are included. JavaScript method names are camelCase throughout:
npm install ./aaes-sdk-0.1.0.tgzImport the installed package:
import { Client } from "@aaes/sdk";
try {
const result = await Client.fromEnv().capabilities();
console.log(`${result.capabilities.length} permitted capabilities`);
} catch (error) {
console.error(String(error));
process.exitCode = 1;
}Read the method and authorization matrix. New read APIs retain daemon wire names, such as work_id; existing action results retain their language-native fields.
Methods and helpers
The table lists Go entry points. Python uses snake_case (request_access, present_grant). JavaScript uses camelCase (requestAccess, presentGrant). Use the SDK methods page for the full matrix.
| Go entry point | Purpose |
|---|---|
aaes.FromEnv() | Construct a client from the environment. |
Capabilities | Read the capabilities this caller may use. |
Catalogue | Read capabilities this caller can request access to. |
Health | Check daemon health. |
Action | Record a decision and, when allowed, mint a grant. Does not execute the downstream action. |
Brokered | Decide, then execute through AAES's connector. |
Federate | Federation interface; unavailable in the supplied distribution. Calls return 403 ("no federated backend") until an operator wires a minting backend. |
PresentGrant | Bind a stored grant to the authenticated caller. |
RequestAccess | Submit an access request. |
AccessRequest | Read an access request. |
Observe | Report an effect authorized under pass_through custody. |
Refresh | Clear the cached caller identity so the next action fetches it again. |
aaes.VerifyHint | A helper, not receipt verification. Use aaesctl verify to verify receipts. |
ListWork, Work | Bounded work pages and one work record. |
ListApprovals, Approval | Authorized approval queue and intent-bound decisions. |
ListEntitlements | Usable, expired, and revoked access for the permitted actor. |
ListReceipts, Receipt | Scoped sealed evidence with daemon-reported coverage: an AAES-defined accounting measure over the configured and captured population, not a measure of all enterprise agent activity. |
ManagerCards, DecideManagerCard | Agent-manager inbox and explicit bound decisions; never automatically retried. |
NewOperator, RevokeAccessRequest | Separate person-token client for access revocation; not an agent authority grant. |
Daemon refusals are JSON with a reason. A remedy is included when the daemon can name the smallest change that would satisfy the refusal.
Request safety and verification
- Registered destinations. An action does not accept a caller-supplied application URL, HTTP method, or credential. Brokered calls use deployment-controlled application credentials. Federation, when separately wired and validated, instead returns credential material or issuance instructions and the registered target to the caller. The bearer token authenticates the daemon caller; it is not an application credential to embed in an action.
- Caller identity.
tenant_idandactor_idare claims that must match the token. The SDKs fill them. - Explicit retries. Retry is limited to
503, is opt-in, and requires an effect key. Automatic retries are permitted only for release-documented operations and failure stages; never use a new effect key merely to get past a conflict or an uncertain result. On the decision routes a daemon-originated 503 precedes the sealed decision, so nothing was committed or executed; a post-seal failure arrives as 403 in the route's decision shape, whose receipt records how far the action got. On the federated route a 503 can follow a sealed decision (a mint or marker failure), but no grant material was released and the live-grant slot was freed, so a retry with the same effect key step is permitted there. A missing response (timeout, reset connection, intermediary error) is not evidence of anything. Reconcile first viaGET /v1/receipts?work_id=…and the intent, effect and effect-id fields the read API publishes, or give the work ID, effect key step and your correlation identifiers to the operator to find the sealed decision in the journal. A missing receipt is not proof nothing was committed; a duplicate-effect 409 proves recording, not downstream success; and 409 also covers other state conflicts, so the status alone never identifies the situation. Read the reason. Remaining retry notes ship with the evaluation package. - Receipt verification. The SDKs do not verify receipts. Use the offline operator CLI.
Verify offline
Given an export and public key from your evaluation install, run:
aaesctl verify --export <export.jsonl> --pubkey <key.pub>No running service is required. See the CLI reference for offline audit commands, or return to the API reference for the daemon contract.
