Welcome to our new developer portal! Use the "Ask" button to chat with our AI Agent.
For the complete documentation index, see llms.txt. This page is also available as Markdown.

D1 SDK error management

When D1 SDK API is not able to succeed, it returns an error in its callback. In the API documentation, each API lists its possible errors.

D1Exception.getMessage() (Android) and D1Error.errorDescription (iOS) provide a String representation of the error information. It is recommended for the issuer application to include the error stack trace in their support tickets as in the following code snippets:

Example: read the error message (Android)
D1Exception d1Exception; // thrown by SDK API
String message = d1Exception.getMessage();

Truncated error content

If you have a size constraint on the error information and needs a truncation, use the following APIs to obtain a brief version of the error:

D1Exception.getErrorCode() returns D1Exception.ErrorCode that describes the error type.

Last updated

Was this helpful?