Multi-agent crews need multi-event receipts
A CrewAI crew has 3-5 agents collaborating. A single flat receipt loses the "who did what" structure. Our wrapper produces one parent receipt per kickoff + one sub-event per agent task. The receipt JSON includes a structured `extensions.crewai_agents` field listing each agent's role, the tools they called, the output they produced. The dashboard renders this as a per-agent timeline — much more useful than one giant blob.
Per-agent cost rollup
Each agent in a crew may use a different model. The receipt logs per-agent cost: "Researcher used Claude $0.18, Analyst used GPT-5 $0.22, Writer used Gemini $0.06". Crews can be optimised: swap the Writer's model for a cheaper one if quality holds. The data lives in the receipt; you don't have to instrument it separately.
Long-running crew runs
CrewAI runs commonly take 60+ seconds across many tool calls. The wrapper streams events to api.genzagents.com as the crew runs (not just at the end) — so if the crew crashes at step 8 of 10, you still have a receipt showing steps 1-7. This is the difference between a useful audit trail and one that vanishes on failure.
Cross-crew handoff
Crews can spawn sub-crews. The wrapper captures parent-child crew relationships: the receipt for sub-crew B includes parent_run_id pointing at crew A. Long composite workflows ("research crew → analyst crew → writer crew") are auditable as a single tree even though they're three separate Crew.kickoff calls.
Process modes — sequential vs hierarchical
CrewAI supports two process modes: sequential (agents in order) and hierarchical (manager + workers). The wrapper detects which mode the crew is using and tags receipts accordingly. Your dashboard filter "show me hierarchical-mode crew runs" surfaces the manager-pattern work for the orgs that prefer that style.
Server-side deployment
Same as LangChain: ship the wrapped crew behind an API, pass the per-user humanId via the wrapper config, every end-user's usage shows up as their own receipts. Use this pattern for SaaS that exposes CrewAI to end-users.
Install
$ npm install @genzagentsio/crewai
import { wrapCrew } from "@genzagentsio/crewai"
const crew = wrapCrew(rawCrew, {
agentDid: "did:genz:...",
apiKey: process.env.GENZAGENTS_API_KEY,
})
await crew.kickoff(inputs)What we capture
Every Crew.kickoff: per-agent task assignments, tool calls, intermediate outputs, final result.
Verify it works
Run wrapped crew → one parent receipt per kickoff, one sub-event per agent task on /dashboard.