- Platform API calls return
ApiResult<T>or throwApiErrorExceptionwhen usingunwrapResult. - A2A task updates can include error metadata via the error extension.
Platform API errors
All API methods returnApiResult<T>. You can branch on result.ok or use unwrapResult and catch errors.
Error helpers
Use the guard helpers to match specific error types.A2A extension errors
When tasks fail or are rejected, agents can emit an error extension payload. Read it withextractUiExtensionData and display a user facing message.