Skip to navigation

Overview

Availability:

  • All card types

Process

Processing a one-time card payment is a multi-step process:

1

Card tokenization

Register the card to tokenize its sensitive data so it can be used for payment.

2

Payment request

Call the POST Create a Direct Card PayIn endpoint to initiate the payment.

3

3DS redirection

If required by the issuer, redirect the user to the issuer’s Access Control Server (ACS) to complete strong customer authentication.

4

Payment outcome

Mangopay updates the Statusof the pay-in from CREATED to SUCCEEDED or FAILED to indicate the result.

Set up webhooks for the following event types:

  • PAYIN_NORMAL_SUCCEEDED
  • PAYIN_NORMAL_FAILED

Call the GET View a PayIn endpoint to confirm the result and customize the user’s post-pay experience.

5

Card deactivation

Call the PUT Deactivate or edit a Card endpoint to disable the CardId if you don’t have the user’s permission to save their payment details.

See the how-to guide for a detailed walkthrough of these steps you need to take:

Sequence diagram

The following diagram details the full flow described above:

opt [If SCA required by issuer] Send payment request from end user POST Create Card Registration Return: AccessKey, PreregistrationData, CardRegistrationURL Send: AccessKey, PreregistrationData, CardRegistrationURL Send: AccessKey, PreregistrationData, CardRegistrationURL, and card details Return: RegistrationData Send: RegistrationData PUT Update Card Registration Return CardId Fetch: IP address, browser information Return: IP address, browser information POST Create Direct Card PayIn Request payment Notify that authentication is required Return: SecureModeRedirectURL, Status as CREATED Redirect end user Authentication (SCA) completed by end user Verify authentication Return end user to SecureModeReturnURL Change pay-in Status to SUCCEEDED or FAILED Send webhook PAYIN_NORMAL_SUCCEEDED or PAYIN_NORMAL_FAILED GET View PayIn Return Status Confirm payment outcome PUT Deactivate or edit Card 1. Card tokenization 2. Payment request 3. 3DS redirection 4. Payment outcome 5. Card deactivation App / website Platform Mangopay API Tokenization server ACS (issuer)