Skip to main content
SDK methods return their resource data directly. A failed validation, engine call, or transport throws ApiError; uncaught errors fail the run and are logged by the runtime. ApiError preserves message, request identity, optional HTTP status, code, failure class, operation evidence, validated details, and cause. Catch to add context and rethrow, or isolate an independent task. Never catch-log-return after a required read or trade fails: returning marks the run successful. Deliberate no-trade decisions may return normally. Messages include distinct causes; error.details?.diagnostics holds provider evidence and rejected quotes separately. Never replace failed live data with a default; missing memory instead returns null fields. LIFECYCLE_TIMEOUT and SUBMISSION_UNCERTAIN can be externally ambiguous. Retain the operation’s evidence; never retry automatically. A known submission failure keeps its code when the deadline expires, with the deadline explanation appended. The SDK never retries a write after response loss.