SDK integration

This guide provides a step-by-step process to integrate the Yuno SDK with Apple Pay. Following this guide will enable seamless payment processing through Apple Pay.

Step 1: Add the Connection

To add the Apple Pay connection to the Yuno dashboard, follow these steps:

  1. Log in to your Yuno dashboard.
  2. Navigate to the Connections section.
  3. Locate and select the Apple Pay option and click Connect.
  4. Provide a Name for the connection, select Apple Pay as Payment method, and provide the information you acquired when following the Prerequisites process.
  5. Click Add. Apple Pay will be added to your connections.

Step 2: Add a Route for Apple Pay

Set up a new route to control how payments are processed through Apple Pay. Follow the steps below:

  1. In the Yuno dashboard, navigate to the Routing section.
  2. The Apple Pay new connection is on the Not published tab.
  3. Set up a new route by pressing Setup on your Apple Pay module and then pressing Create new route.
  4. Add conditions to specify when payments should be routed through Apple Pay.
  5. Add Apple Pay as the payment processor for this route to ensure that payments meeting the defined conditions are processed through Apple Pay.
  6. Save and publish the route once all configurations are properly defined.

The following image displays a simple route through which Apple Pay processes all payments.

  1. Once that is done, you will need to set the route for the Card payment method indicating with which provider you want to process payments with.

Step 3: Checkout Builder

To make Apple Pay available to your end users, follow these steps:

  1. In the Yuno dashboard, navigate to the Checkout Builder section.
  2. Locate the available Payment methods and enable Apple Pay.
  3. Press Publish to make Apple Pay available as a payment option for all transactions that meet the defined routing criteria.

Step 4: Start Using Your Yuno Integration

With your Yuno integration set up, you're ready to start processing payments. Using our standard Full or Lite SDK integration, you can seamlessly offer payments through Apple Pay Wallet, providing your users with a smooth and secure payment experience.

Using Yuno's SDK

  1. Create a Customer: Use the Create Customer endpoint to register the customer's information. (Optional)

  2. Set Up a Checkout Session: You can create a checkout session with a registered customer. Use the Create Checkout Session endpoint, providing the payment amount and location details.

  3. Generate a One-Time Token (OTT): An OTT is a unique identifier Yuno generates to protect your customer's privacy and security. You will obtain the OTT from the Yuno SDK, which handles various payment method scenarios, supports fraud screening, and 3DS authentication. Use payment_method_type = APPLE_PAY. Access Payment type to view available payment types.

  4. Create the Payment: Use the Create Payment endpoint to create a payment. To create the payment, you will inform the data received in the previous three steps.

  5. Retrieve Payment Details: To check the payment status, you can analyze the status and sub_status in the response from the Create Payment endpoint or use the Webhooks. Refer to the Payment Status page to see all possible statuses.

Step 5: Prepare for Testing with Apple Pay

Before you start making test payments with Apple Pay, follow these steps to ensure your setup is correctly configured:

  1. Follow the official Apple Pay test guidelines to create a test account and set up test cards.
  2. Test in Safari to ensure compatibility and functionality.
  3. Set up the testing domain URL in the Apple Pay connection within your Yuno dashboard to ensure that payments are routed correctly during testing.