CheckoutApi

interface CheckoutApi

Interface for the snabble Checkout API

Backend API Documentation: https://docs.snabble.io/docs/api/api_checkout

Inheritors

Functions

Link copied to clipboard
abstract fun abort(checkoutProcessResponse: CheckoutProcessResponse, paymentAbortResult: PaymentAbortResult?)
Link copied to clipboard
abstract fun authorizePayment(checkoutProcessResponse: CheckoutProcessResponse, authorizePaymentRequest: AuthorizePaymentRequest, authorizePaymentResult: AuthorizePaymentResult?)

Authorize a payment of a existing checkout process providing payment credentials.

Link copied to clipboard
abstract fun cancel()

Cancel all operations

Link copied to clipboard
abstract fun createCheckoutInfo(backendCart: BackendCart, checkoutInfoResult: CheckoutInfoResult? = null, timeout: Long = -1)

Creates a checkout info with mandatory price calculation and available payment methods. This document can be used to show the real price to the user and it can be used to start a checkout process as input of {@link #createPaymentProcess}

Link copied to clipboard
abstract fun createPaymentProcess(id: String, signedCheckoutInfo: SignedCheckoutInfo, paymentMethod: PaymentMethod, processedOffline: Boolean, paymentCredentials: PaymentCredentials?, finalizedAt: Date?, paymentProcessResult: PaymentProcessResult?)

Creates a payment process using stored payment credentials and a signed checkout info from create checkout info.

Link copied to clipboard
abstract fun updatePaymentProcess(checkoutProcessResponse: CheckoutProcessResponse, paymentProcessResult: PaymentProcessResult?)

Updates an existing payment process