Skip to main content

Charge repeat customers

Repeat customers expect fast, frictionless checkout. Instead of asking them to re-enter their name, email, and payment details every time, use the customer and payment method IDs from their first purchase to create instant checkout flows. This guide shows you how to charge returning customers with saved payment methods and how to handle cases where they want to use a different payment method.

Use MCP for repeat-customer context

An authenticated AI agent can look up the customer and create an unpaid order. pay_order requires your exact amount and masked-method confirmation before starting collection; new details and OTP stay in secure Inttegro Checkout.

MCP tools: get_customer, create_order, pay_order or get_order

Confirmed MCP actions require explicit form confirmation before Inttegro changes state.

How it works

After a customer's first successful payment, Inttegro automatically creates a customer record and attaches their payment method to it. You'll find payment.customer.id and payment.paymentMethod.id in the order response. Store these IDs in your database linked to your user account. When the customer returns, reference them with customerId and optionally paymentMethodId instead of passing full details. Inttegro handles OTP delivery and payment confirmation just like the first time, but checkout is faster because you're not collecting information again.

Choose your integration approach

Select how you want to charge repeat customers:

The simplest repeat customer flow uses both customerId and paymentMethodId for instant, one-click checkout. The customer doesn't need to re-enter any information—just confirm the OTP and the payment completes.

Charge with saved method

POST/orders/create
SDK versionv12.0.0
import * as Inttegro from '@inttegro/inttegro-sdk'

const inttegro = new Inttegro.InttegroClient({
apiKey: process.env.INTTEGRO_API_KEY!,
})
const result = await inttegro.orders.create({
requestMeta: {
idempotencyKey: "order_repeat_001",
},
executePayment: true,
customerId: "cu_abc123",
paymentMethodId: "pm_saved_method",
lineItems: [
{
type: Inttegro.LineItemTypes.Product,
product: {
type: Inttegro.ProductTypes.Digital,
name: "Premium Subscription",
quantity: 1,
price: {
currency: "ghs",
value: 5000,
},
},
},
],
})

Response​

Note

This is a partial response showing key attributes. See the complete Order object for all available fields.

Response excerpt

SDK versionv12.0.0
OrderResponse {
order: { … },
}

What's different:

  • No customerData or paymentMethodData needed—everything is already on file
  • Inttegro sends OTP to the phone number associated with the saved payment method
  • Customer confirms with OTP just like the first purchase

The confirmation step is identical to first-time payments. Submit the returned order ID, payment ID, confirmation-request ID, and the customer's token as shown in Confirm a payment.

Subscription renewals

Store the customer and payment-method IDs when a customer subscribes. For each renewal, use the saved-method request shown above, give the order a unique idempotency key for that billing period, and use the current plan as its line item. If the returned payment requires confirmation, ask the customer to complete it. Mark the renewal paid only after the order reports a successful payment.

Testing

Use an application configured for the test environment. Create the first test order to obtain customer and payment-method IDs, then use those IDs on the repeat order. If the response requires confirmation, follow Confirm a payment with orderId, paymentId, confirmationId, and the test token supplied for that environment. Do not hardcode a universal token value.

Key tips

Store both IDs: Always save payment.customer.id and payment.paymentMethod.id from the response after the first payment. You need the customer ID to associate future orders and the payment method ID for fast checkout.

Customer profile vs payment method: A customer can have multiple payment methods. When you use customerId + paymentMethodData, you're adding a new payment method to an existing customer. When you use customerId + paymentMethodId, you're charging an existing payment method.

Payment method verification: All payment methods require OTP confirmation, even saved ones. This protects both you and the customer—it proves the customer has access to the phone at the time of payment.

Handle expired payment methods: Phone numbers change, accounts get closed. If a payment fails with an expired or invalid payment method error, prompt the customer to add a new payment method using the customerId + paymentMethodData pattern.

Next steps

You now know how to build fast, one-click checkout for repeat customers while maintaining security through OTP verification.