This SDK is designed for low-change, low-touch customer integration.
- Stable API surface for v1.
- Explicit timeout and retry controls.
- Streaming chat support (
text/event-stream).
- 429 / 5xx automatic retries apply only to GET and HEAD. POST / PUT / PATCH are not retried on those status codes to avoid duplicate side effects.
- Network I/O failures may still be retried for all methods, up to
maxRetries. - Retry delay uses exponential backoff with a capped wait time.
Maven: <dependency><groupId>com.egroupai</groupId><artifactId>ai-sandbox-sdk-java</artifactId><version>1.0.0</version></dependency>
- Construct
AiSandboxClientwithbaseUrlandapiKey. - Call
createAgent(...). - Create a chat channel with
createChatChannel(...)and send the first message withsendChat(...)orsendChatStream(...).
- On HTTP errors,
ApiExceptionincludes optionalgetTraceId()when the server sendsx-trace-id.