REFERENCE · EVENTS
Events
Every state change in the protocol emits a typed event. Both on-chain logs and an aggregated WebSocket stream are available.
Event shape
typescript// Every event extends BaseEvent
interface BaseEvent {
id: string; // hash-prefixed
ts: number; // unix seconds
intentId?: string;
agentRef?: string;
walletAddress?: `0x${string}`;
txHash?: `0x${string}`;
}On-chain events follow the same shape with ABI-encoded fields. The WebSocket stream re-serialises them as JSON with the snake-cased wire format above.
Intent events
Agent events
Cast events
Seal events
| Event | Source | Meaning |
|---|---|---|
IntentSigned | IntentBook | New intent registered on-chain. |
IntentHalted | IntentBook | Intent paused by you or by an agent. |
IntentRevoked | IntentBook | Intent closed. Seal nullified. |
AgentBound | Mesh | An agent has won the fit-poll and bound to an intent. |
PlanProposed | Agent | Agent emitted a plan; bounds check pending. |
PlanRejected | CastRouter | Plan failed bounds check. No tx submitted. |
CastSubmitted | CastRouter | Transaction submitted to the network. |
CastSettled | CastRouter | Transaction confirmed. Outcome attached. |
CastReverted | CastRouter | Transaction reverted on-chain. |
SealMinted | SealRegistry | New seal issued. |
SealExpired | SealRegistry | Seal hit its TTL. |
SealRevoked | SealRegistry | Seal manually revoked. |
Example payload
json// CastSettled — emitted after a successful cast lands
{
"type": "CastSettled",
"id": "evt_92F...",
"ts": 1747749512,
"intentId": "int_8K3...",
"agentRef": "wraith-of-yield@0.4.1",
"txHash": "0xabc...",
"kind": "rotation",
"from": { "venue": "aave", "amount": "4200000000" },
"to": { "venue": "morpho", "amount": "4200000000" },
"gasUsd": 0.003,
"edgeBps": 42,
"outcome": "ok"
}Live event subscription happens through the chain itself in v0.1.0. Subscribe to the topic-0 of each event listed above through your own Base RPC's eth_subscribe, or your indexer of choice (Envio, Goldsky, Ponder, self-hosted). A hosted WebSocket arrives with the runtime.