Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.usepaykit.dev/llms.txt

Use this file to discover all available pages before exploring further.

All providers implement the same interface. Swap by changing one import — no other code changes needed.
// Before
import { stripe } from '@paykit-sdk/stripe';

// After
import { paystack } from '@paykit-sdk/paystack';

export const paykit = new PayKit(paystack()); // everything else is identical

Provider-specific features

Each provider exposes typed provider_metadata for operations not covered by the unified API. TypeScript will autocomplete and enforce the correct shape per provider:
// Stripe checkout — provider_metadata is typed as Stripe.Checkout.SessionCreateParams
await paykit.checkouts.create({
  customer: { email: 'user@example.com' },
  item_id: 'price_123',
  session_type: 'one_time',
  quantity: 1,
  success_url: '...',
  cancel_url: '...',
  provider_metadata: {
    tax_id_collection: { enabled: true }, // fully typed, autocompleted
  },
});

Raw webhook events

Alongside standard PayKit events, each provider emits typed raw events with a provider prefix. This gives you direct access to the original payload when you need fields outside the unified model. See each provider page for the full list of raw events and their types.