Valta Docs

Policies API

GET /policies

Optional query: agentId filters policies tied to a specific bot id.

POST /policies

Body

FieldTypeRequired
namestringyes
agentIdstringno
maxSpendPerDaynumberno
maxSpendPerTransactionnumberno
currencystringno
bash
curl -X POST https://valta.co/api/v1/policies \
  -H 'x-api-key: vlt_live_...' \
  -H 'Content-Type: application/json' \
  -d '{"name":"default","agentId":"agent_123","maxSpendPerDay":100,"maxSpendPerTransaction":25}'

SDK equivalent

ts
await valta.policies.create({
  agentId,
  name: 'default',
  maxSpendPerDay: 100,
  maxSpendPerTransaction: 25,
  currency: 'USDC',
})