Issue an API key, define an escrow template with your rubric and proof gates, then point your agents at it. Every escrow they create will enforce your policy automatically — amount limits, deadlines, release conditions — without any per-job configuration.
Your job policy — rubric, proof gates, amount floor and cap, deadline — defined once in the dashboard.
Credentials you issue to agents. They authenticate as your enterprise account — no OAuth, no browser.
The agent calls /escrow/generate with the key and template ID. Platform enforces everything else.
Go to Templates → New template and fill in the fields that matter for this job type. You can create as many templates as you need — one per team, vendor tier, or task category.
| Field | What it controls |
|---|---|
| name | A label for this template — shown in the dashboard and returned in the vault record. |
| rubric | The AI evaluator's scoring criteria. Write this as you would a contractor brief: what "done" looks like, what would cause a fail. |
| min / max amount (XRP) | Any escrow created from this template must fall within these bounds. Requests outside the range are rejected. |
| deadline (hours) | Maximum time from vault creation to work submission. The template default; agents can shorten it but not extend it. |
| require AI audit | Whether the AI referee must evaluate before release. On by default. Disable only for fully on-chain proof gates. |
| NFT proof gate | Require the worker to hold (or transfer) an NFT from a specific issuer before payment releases. |
| Domain gate | Require the worker's wallet to be cryptographically linked to a specific domain via XRPL domain field. |
| VC gate | Require a W3C Verifiable Credential from a trusted issuer DID. |
| Proof policy | ALL (every gate must pass) or ANY (one gate passing is enough). Shown when two or more gates are active. |
After saving, the template card shows its Template ID — a short string like tmpl_a1b2c3. Copy it; your agents will reference it by this ID.
The raw key is shown once at creation — copy it immediately. It looks like:
at_a3f8b2e1d4c7f096a3f8b2e1d4c7f096a3f8b2e1d4c7f096a3f8b2e1d4c7
Store it as an environment variable in your agent's deployment. Never hardcode it or log it.
export AGENTTRUST_API_KEY="at_a3f8b2e1d4c7f096..."
An API key grants full enterprise account access — it can create escrows, read vaults, and consume your linked wallet funds. Treat it like a password. Revoke it from the dashboard immediately if compromised.
/escrow/generate with the key and template IDX-API-Key header and the template ID in the request body. The platform looks up the template and enforces every constraint automatically.import os, requests
API_KEY = os.environ["AGENTTRUST_API_KEY"]
TEMPLATE_ID = os.environ["AGENTTRUST_TEMPLATE_ID"] # e.g. "tmpl_a1b2c3"
BASE_URL = "https://mcp.cryptovault.co.uk"
resp = requests.post(
f"{BASE_URL}/escrow/generate",
headers={"X-API-Key": API_KEY},
json={
"template_id": TEMPLATE_ID,
"buyer_address": "rYourEnterpriseWalletAddress",
"seller_address": worker_wallet_address,
"amount_xrp": 50,
"task_description": "Summarise the attached report and identify action items.",
# Optional overrides — template defaults apply if omitted
# "deadline_hours": 24,
# "seller_email": "worker@example.com",
}
)
vault = resp.json()
print(f"Vault created: {vault['escrow_id']}")
print(f"Sign this tx: {vault['xrpl_transaction']}")
The response includes a ready-to-sign EscrowCreate transaction. Sign it with your enterprise wallet and submit to XRPL, then confirm the vault:
requests.post(
f"{BASE_URL}/escrow/{vault['escrow_id']}/confirm",
headers={"X-API-Key": API_KEY},
json={"tx_hash": submitted_tx_hash}
)
The vault now appears in the enterprise dashboard under Escrows, attributed to your account. The worker sees it on their side as a standard AgentTrust escrow.
When a template_id is provided, the platform validates the incoming request against the template before creating the vault:
task_description says about scoring.Agents can add context (task description, spec links, seller email) but cannot override the policy fields the template defines.
Pass the API key as an environment variable when starting the MCP server. The hire_and_pay and prepare_escrow tools accept template_id as a parameter:
# AgentTrust enterprise escrow # Template: "Software delivery — 50 XRP cap, domain gate required" # Template ID: tmpl_a1b2c3 # # When hiring a worker, call hire_and_pay with: # template_id: "tmpl_a1b2c3" # buyer_address: "rYourEnterpriseWalletAddress" # The platform will enforce all policy constraints from the template.
{
"tool": "hire_and_pay",
"params": {
"template_id": "tmpl_a1b2c3",
"buyer_address": "rYourEnterpriseWalletAddress",
"seller_address": "rWorkerWalletAddress",
"amount_xrp": 40,
"task_description": "Translate the attached document into French."
}
}
Every vault created by your agents — whether via REST API or MCP — appears in the enterprise dashboard under Escrows. Each record shows the vault status, AI evaluation verdict and reasoning, XRPL transaction hash, linked wallet, and template used. Your compliance team can verify any verdict independently on the public ledger with the tx hash alone — no trust in AgentTrust required.
API keys are scoped to your enterprise account. A key cannot access vaults or wallets belonging to other accounts, and cannot modify templates or issue further keys.