LithicClientAsync

A client for interacting with the Lithic REST API asynchronously. You can also switch to synchronous execution via the sync method.

This client performs best when you create a single instance and reuse it for all interactions with the REST API. This is because each client holds its own connection pool and thread pools. Reusing connections and threads reduces latency and saves memory. The client also handles rate limiting per client. This means that creating and using multiple instances at the same time will not respect rate limits.

The threads and connections that are held will be released automatically if they remain idle. But if you are writing an application that needs to aggressively release unused resources, then you may call close.

Inheritors

Types

Link copied to clipboard
interface WithRawResponse

A view of LithicClientAsync that provides access to raw HTTP responses for each method.

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open suspend fun apiStatus(requestOptions: RequestOptions): ApiStatus

abstract suspend fun apiStatus(params: ClientApiStatusParams = ClientApiStatusParams.none(), requestOptions: RequestOptions = RequestOptions.none()): ApiStatus

Status of api

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun cards(): CardServiceAsync
Link copied to clipboard
abstract fun close()

Closes this client, relinquishing any underlying resources.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun events(): EventServiceAsync
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun fraud(): FraudServiceAsync
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun reports(): ReportServiceAsync
Link copied to clipboard
Link copied to clipboard
abstract fun sync(): LithicClient

Returns a version of this client that uses synchronous execution.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Returns a view of this service with the given option modifications applied.

Link copied to clipboard

Returns a view of this service that provides access to raw HTTP responses for each method.