create Charge Intent
suspend fun createChargeIntent(request: ChargeIntentsRequests.CreateChargeIntentRequest): Pair<ChargeIntent?, NetworkingError?>
Creates a new charge intent, attaching the current Sonar session ID and live fraud signals before sending.
Return
A Pair containing the created ChargeIntent on success, or a NetworkingError on failure.
Parameters
request
The parameters for the charge intent to create.
fun createChargeIntent(request: ChargeIntentsRequests.CreateChargeIntentRequest, completionHandler: (ChargeIntent?, NetworkingError?) -> Unit)
Creates a new charge intent, attaching the current Sonar session ID and live fraud signals before sending.
Executes the network request on a background thread and delivers the result to completionHandler.
Parameters
request
The parameters for the charge intent to create.
completion Handler
Called with the created ChargeIntent on success, or a NetworkingError on failure.