Checkout integration guide
Redirect customers to a hosted, PCI-compliant payment page and verify the result from your backend.
VINR Checkout is a hosted, PCI-compliant payment page. Create a session from your backend, redirect the customer, and we handle cards, Apple Pay, Google Pay, Click-to-Pay, and 3DS. The customer comes back to your successUrl with a session ID you can verify.
When to use Checkout
- No engineering effort on payment UI — VINR renders and maintains the page.
- Lowest PCI scope: SAQ-A applies because card data never touches your servers.
- Works in any backend language — the only requirement is a single REST call.
Need to keep customers on your own page? Use Elements instead.
How it works
Create a session from your backend
POST to /checkout/session with the order amount, currency, and redirect URLs. The response includes a checkoutUrl.
Redirect your customer
Customer pays on the hosted page
The customer completes payment at https://checkout.vinr.com/checkout/{sessionId}. VINR handles card entry, wallet payments, and 3DS challenges.
Verify the result on your backend
When the customer lands on successUrl?sessionId=..., fetch the session result to confirm payment status before fulfilling the order.
Quickstart
Get your API key
Log in to the VINR Dashboard and copy your merchant API key from Settings → API Keys.
Store it as VINR_API_KEY in your environment. Never commit it to source control.
Create the session (backend)
Add an endpoint to your server that creates a Checkout session and returns the checkoutUrl to your frontend.
Redirect the customer (frontend)
Call your backend endpoint, then redirect to the hosted page.
Verify on the success page (backend)
Read the sessionId query parameter VINR appends to successUrl, fetch the result, and branch on status.
(Optional) Listen for webhooks
Polling the result endpoint is fine for simple flows. For reliable async notifications — especially when the customer closes the tab — set up a webhook endpoint and listen for payment.completed.
Configuration options
The table below covers the most commonly used fields. See the full session reference for every field including cart items, promo codes, delivery options, and metadata.
| Field | Type | Required | Description |
|---|---|---|---|
amount | integer | Yes | Amount in minor units (e.g. 5000 = €50.00) |
currency | string | Yes | ISO 4217 code, e.g. "EUR" |
successUrl | string | Yes | HTTPS URL to redirect after successful payment |
cancelUrl | string | Yes | HTTPS URL to redirect when customer cancels |
customer | object | No | Pre-fill customer details; enables guest checkout if omitted |
cartItems | array | No | Line items shown in the checkout UI |
supportedCurrencies | string[] | No | Let the customer switch currency; defaults to currency only |
configId | string | No | Branding/config preset (default: "default-config") |
metadata | object | No | Controls UI behaviors: mode, shipping, promo codes, delivery |
Payment methods
| Method | Coverage |
|---|---|
| Cards (Visa / Mastercard / Amex) | Global |
| Apple Pay | Safari and Apple devices |
| Google Pay | Chrome and Android |
| Click-to-Pay | Mastercard SRC |
3DS authentication is handled automatically — you don't need to write any challenge logic.
Security and PCI scope
Card data never touches your servers. Because customers enter card details on a VINR-hosted domain, SAQ-A is the applicable PCI self-assessment questionnaire. The hosted page sets frame-ancestors 'none' so it cannot be embedded in an iframe. For a full overview of your compliance obligations, see Compliance.