Pay In quickstart

Learn how to tokenize a payment method and make your first Pay In transaction
Applies to:DevelopersPartners

Get started with payment processing in minutes using this interactive browser-based demo, which uses a mock server to simulate real API requests and responses. Follow along to see how easy it can be to tokenize a payment method and process a transaction with Payabli.

Before you begin

This quickstart uses a mock server for educational purposes only. In your own testing and integration, you must use a PCI-compliant method to handle payment data, such as the Payabli Embedded MethodUI Component or your own secure server-side implementation.

Never handle raw payment data directly in your application. Payment card information (card numbers, CVV codes, and so on) is subject to strict PCI DSS (Payment Card Industry Data Security Standard) compliance requirements. Non-compliant handling of payment data can result in:

  • Significant financial penalties
  • Legal liability for data breaches
  • Loss of payment processing privileges

Now that the warnings are out of the way, let’s get started! In this quickstart, you’ll complete two main tasks:

  1. Tokenize a payment method - Convert card payment details into a secure token
  2. Process a transaction - Use that token to complete a payment

You don’t need to download anything, set anything up, or have an API token. Just follow the steps and interact with the mock API requests directly in your browser.

Step 1: Tokenize a payment method

Payment tokenization converts sensitive payment details into a secure, single-use token that can be safely transmitted and stored. Remember that this is a simulated tokenization for learning purposes only, and not PCI-compliant. Refer back to Before you begin for more information.

All required fields are prefilled for you, but feel free to add or change details to see how it works. When you’re ready, click Send Request to simulate tokenizing the card.

This quickstart tokenizes a credit card, but you can also tokenize bank accounts (ACH). Learn more in the Tokenization overview guide.

Interactive demo for POST /TokenStorage/add. Saves a payment method for reuse. This call exchanges sensitive payment information for a token that can be used to process future transactions. The `ReferenceId` value in the response is the `storedMethodId` to use with transactions.
POST
/TokenStorage/add
{}

The mock server simulates the secure tokenization process and returns a secure token instead of storing raw card data. Copy the value from methodReferenceId in the response to use in the next step.

Step 2: Process a transaction

Now use your token to process a payment. Grab the methodReferenceId returned in Step 1 and enter it in paymentMethod.storedMethodId, along with an amount to charge. When you’re ready, click Send Request to simulate processing the payment.

We’ve simplified the request for this demo, but for a real transaction, you can include additional details like customer info, billing address, and so on.

Interactive demo for POST /MoneyIn/getpaid. Make a single transaction. This method authorizes and captures a payment in one step.
POST
/MoneyIn/getpaid
{}

The mock server simulates the payment using the tokenized payment method, and returns a success response. In a real integration, you would handle the response to confirm the payment status and update your app accordingly.

Next steps

Now that you’ve seen how easy it can be to tokenize a payment method and process a transaction, you’re ready to explore more advanced resources.

See these related resources to help you get the most out of Payabli.