Docs

Build with Paytab.

From quickstarts to deep API references — 18 articles across guides, references and code samples.

18 of 18 articles
Getting started

Create an account and get API keys

Sign up, verify your email, and grab your test + live API keys from the dashboard.

Getting started

Take your first payment

One API call, hosted checkout, done — receive your first test payment in under five minutes.

API reference

Authentication

HTTP Basic auth with your secret key. Never expose secret keys in browsers or mobile apps.

API reference

Pagination & filtering

Cursor-based pagination with limit + starting_after. All list endpoints return has_more.

API reference

Error codes

Standard HTTP status codes plus a machine-readable error type and code on every failure.

API reference

Rate limits

100 read + 100 write requests per second by default. Bursts up to 500 briefly permitted.

Webhooks

Receiving webhooks

Subscribe to real-time events, verify signatures, and reply 2xx within 10 seconds.

Webhooks

Event catalogue

80+ event types across payments, payouts, subscriptions, invoices, disputes and customers.

SDKs

Official SDKs

Node.js, Python, PHP, Ruby, Go, Java and .NET — all generated from our OpenAPI spec.

Testing

Test cards & simulated failures

A full catalogue of test PANs for successes, declines, 3DS flows and specific decline codes.

Security & compliance

PCI, SCA and encryption

PCI DSS Level 1. Card data never touches your servers. SCA/3DS2 handled automatically.

Products

Subscriptions & billing

Plans, trials, coupons, seat-based and usage-based billing with a hosted customer portal.

Products

Marketplaces & Connect

Onboard sellers, split payments across up to 100 recipients, and route payouts per seller.

Products

Payouts to any bank

Faster Payments, SEPA Instant, US ACH and SWIFT — single or batched from CSV.

Tools

Paytab CLI

Scaffold projects, tail webhooks to localhost, trigger test events, and manage resources.

Tutorials

Integration tutorials

Step-by-step guides for Shopify, WooCommerce, Xero, Zapier and custom Next.js apps.

Products

Currencies & languages

135+ presentment currencies, 25 checkout languages, automatic FX at mid-market + 0.5%.

API reference

Full API reference

Every endpoint, every field, every event — with copy-paste curl and SDK examples.

Quickstart

Your first payment

Copy, paste, run. That's it — no boilerplate, no config file.

curl https://api.paytab.co.uk/v1/payments \
  -u sk_test_...: \
  -d amount=4900 \
  -d currency=gbp \
  -d customer_email=ada@example.com \
  -d description="First payment"
API reference

Core endpoints

The endpoints that power 95% of integrations. Full reference on the developer hub.

MethodPathDescription
POST/v1/checkout/sessionsCreate a hosted checkout session
POST/v1/paymentsCreate a payment directly (server-to-server)
GET/v1/payments/:idRetrieve a payment by id
POST/v1/payments/:id/refundRefund a payment, full or partial
POST/v1/customersCreate a customer
POST/v1/subscriptionsCreate a subscription
POST/v1/invoicesCreate and send an invoice
POST/v1/payoutsSend a payout to a bank account
POST/v1/transfersMove funds to a connected account
POST/v1/webhook_endpointsRegister a webhook endpoint
Errors

Common error codes

Every error includes a stable code — surface it, don't parse the message.

card_declined

The issuing bank declined the card.

insufficient_funds

Card has insufficient balance.

expired_card

Card is past its expiry date.

incorrect_cvc

CVC check failed.

authentication_required

3DS challenge required — retry with SCA.

invalid_request_error

Missing or malformed parameters.

rate_limit_error

Too many requests — back off using Retry-After.

idempotency_error

Idempotency key reused with different params.

Webhook events

80+ events you can subscribe to.

Every event is signed, retried with exponential backoff for up to 72 hours, and replayable from the dashboard.

Official SDKs

First-class libraries in every major language.

All SDKs are open source, semver-versioned, and generated directly from our OpenAPI spec — so they never drift from the API.

Node.js
Python
PHP
Ruby
Go
Java
.NET
Glossary

Payments jargon, decoded.

PSP

Payment Service Provider — Paytab acts as your PSP end-to-end.

SCA

Strong Customer Authentication — required by PSD2 for most EEA payments.

3DS2

3D Secure 2 — the modern authentication flow used to satisfy SCA.

MRR

Monthly Recurring Revenue — normalised subscription revenue per month.

Interchange

Fees paid to the card-issuing bank as part of each transaction.

Chargeback

A cardholder-disputed transaction; Paytab handles evidence submission.

Ready to build?

Grab a test key and take your first payment in the next five minutes.