Requests, types, and pagination
Immutable request and response models, uploads, raw responses, and pagination.
Resource map
Search every SDK resource and method and open the matching REST endpoint.
Errors, retries, and timeouts
Handle structured errors and configure retry and timeout behavior.
Webhooks
Verify ED25519 signatures and process webhook events.
Advanced usage
Configure language-specific logging, transport, raw responses, and custom requests.
Install
Addcom.telnyx.sdk:telnyx to the Gradle or Maven build using the current version published on Maven Central.
Requirements
This library requires Java 8 or later.Initialize the client and make a request
Quickstart from the current SDK source, usingTELNYX_API_KEY for authentication:
Usage
Client configuration
Configure the client using system properties or environment variables:
System properties take precedence over environment variables.
[!TIP] Don’t create more than one client in the same application. Each client has a connection pool and thread pools, which are more efficient to share between requests.
Modifying configuration
To temporarily use a modified client configuration, while reusing the same connection and thread pools, callwithOptions() on any client or service:
withOptions() method does not affect the original client or service.
Asynchronous execution
The default client is synchronous. To switch to asynchronous execution, call theasync() method:
CompletableFutures.