Skip to main content
The collection function can be invoked Alignet One SDK from your app iOS to display the payment form and get the result of the operation.
Before starting SDKcomplete Installation SDK iOS and generates an Access Token from your backend using Authentication.

Methods available

CARD

Credit and debit cards.

YAPE

Recovery with wallet Yape.

QR

Recovery with mobile bills by QR.

BANK_TRANSFER

Loan by Bank Transfer.

CUOTEALO

Payment financed with Cuotéalo.

PAGO_EFECTIVO

Payment with code or channel PagoEfectivo.

Integration Flow

1

The SDK

Add UIKit and Alignet One at ViewController from where you will start the flow.
2

Build the request

Crea PAYMEChargesRequest with transaction data, buyer, billing and configuration.
3

PaymeClient Configure

Initiates PaymeClient with delegate, merchantCode and atmosphere.
4

Invoked form

Send accessToken and paymeChargesRequest in invokeCaptureForm.
5

That's a quiet procedure.

Implement onRespondsPayme and onPaymeEvents To close the flow into your app.

Import PaymeSDK

Main parameters

PaymeClient

  • delegate: instance that implements methods of PaymeClientDelegate.
  • merchantCode: Merchant code delivered by Alignet.
  • PaymeEnviroment.development: Test environment.
  • PaymeEnviroment.production: production environment.
  • from: UINavigationController or controller from where the SDK.
  • accessToken: token generated from backend for this request.
  • paymeChargesRequest: with information about the transaction.

Example of initiation

The accessToken should be generated from backend for the application. Do not include credentials or secrets inside the app.

Implement delegates

To complete integration, class should implement PaymeClientDelegate.

Events available

BUILD_FORM

It indicates what methods were shown to the user.

CHOOSE_PAYMENT_METHOD

It indicates the payment method chosen by the user.

RETURN_LIST_PAYMENT_METHODS

He indicates that his user returned to his list of methods.

CANCEL_PAYMENT_METHOD

He indicates that the user cancelled a payment method.

PRESS_PAY_BUTTON

It indicates that the user pressed the payment button.

CLOSE_PAYME

indicates that the user closed the SDK.

Validation of result

Use onRespondsPayme to update the user experience but confirms the final status from backend as required by the flow or payment method.

Next step

Input and exit parameters

Check the complete details of objects sent and received by SDK.