/mcp routes.
REST response envelope
Success
data with meta (page, limit, total).
Error
code field is derived from the HTTP status:
Validation errors on 400 may include a comma-joined message from field validators.
Common HTTP statuses
Authentication errors
Inbound agent webhook errors return the same envelope with 401 for invalid
X-EZ-Signature or clock skew.
Rate limits
Authenticated requests include rate limit headers:Tiers
Rate limits apply per API key or OAuth user id.
MCP JSON-RPC errors
MCP routes (POST /mcp, GET /mcp/sse) return JSON-RPC errors instead of the REST envelope:
MCP session errors
Signal ingestion outcomes
Inbound signal webhooks return 200 with anoutcome field even when no trade executes:
Treat
skipped and unmatched as non-retryable unless you change the payload.
Signal validation errors (HTTP 400)
skipReason dictionary (selected)
Execution error tags (in executionResult.errorMessage)
Full registry: see
ingestReasons.ts in the backend.
Retry guidance
Debugging tips
- Compare your string-to-sign against the SDK’s
signRestRequestoutput for REST HMAC. - For inbound webhooks, verify canonical JSON key ordering matches
stableJsonin echozero-sdk. - Check
X-RateLimit-Remainingbefore bulk operations. - Use
GET /statusto verify OAuth tokens without hitting scoped routes.