Commissions
Endpoint reference: ✅ Verified live against production on 10 May 2026. Commissions are the holder’s earnings from sold orders. Each delivered order generates a commission record tied to that holder’s NFT. Dr Green pays commissions in either USD (fiat) or ETH (on-chain), so amounts are tracked in both currencies on every record.
Endpoints
Status enum
(Other states may exist —
PROCESSING, FAILED — but only PENDING and PAID were observed live.)
GET /dapp/commissions — list records
Each record represents one order’s commission. Paginated.
Query parameters
Canonical payload
urlencode(query) if any present, else "{}".
Response shape (verified)
🪲amountInEthis null on PAID records in observed data — even though the field exists. Either ETH wasn’t the payout rail for those, or it’s a backend gap. Defensively handle null. DisplayamountInDollaras the primary figure.
🪲order.currencyandorder.agentProfitInUSDare both null in observed records. They’re declared in the response but populated inconsistently. Don’t rely on either for display — useorder.totalAmount(USD) andorder.agentProfit.
🪲order.orderLogs[]is an audit trail withactivitystrings like"Delivered","Approved","Created". Useful for showing a per-order timeline if you surface order history.
🪲isPayableappears to gate whether the holder can claim —trueafter the order is delivered,falsewhile in earlier states. Confirm with Dr Green for full state machine. 🔒
GET /dapp/commissions/summary — aggregate by status
The headline numbers for a holder’s earnings dashboard.
Canonical payload
{}
Response shape (verified)
⚠️ The wrapper field iscommissionSummary, notsummary. Other endpoints usesummary. Mind the inconsistency.
🪲totalInDollaris justPENDING.amountInDollar + PAID.amountInDollar. No equivalenttotalInEth. If you need it, sum yourself.
Display patterns
GET /dapp/commissions/managers — sub-manager commissions
For holders who run a team. Returns commissions earned by managers under this holder. Paginated.
Canonical payload
urlencode(query) if pagination params, else "{}".
Response shape
itemCount: 0). Backend code suggests fields include userId, firstName, lastName, email, plus per-manager commission stats.
GET /dapp/commissions/managers/summary — manager-team aggregate
Canonical payload
{}
Response shape (verified)
🪲inActiveAgents(camelCase split inconsistently — usual would beinactiveAgents). Document the field name as-is.
🪲 All totalCommission figures are USD only here — no ETH equivalent at the manager-summary level.
Common patterns
Render a “what am I owed” widget
Reconcile against orders
Polling for commission accrual
Commissions appear after Dr Green marks an orderDELIVERED. Poll /dapp/commissions/summary every 15 minutes when an order has been recently approved; switch to longer intervals once delivery confirmed.