Bill your first customer in an afternoon

One API for subscriptions, usage, invoices and payments. Every key starts in test mode.

first call
import { Mint } from '@globaly-inc/mint-sdk'
 
const mint = new Mint({
  secretKey: process.env.MINT_SECRET_KEY!, // gpy_test_…
})
 
await mint.customers.upsert({
  externalId: 'ws_123',
  email: 'owner@acme.dev',
})
 
const session = await mint.checkout.create({
  customerExternalId: 'ws_123',
  planCode: 'pro_monthly',
  successUrl: 'https://app.acme.dev/billing?ok=1',
  cancelUrl: 'https://app.acme.dev/billing',
})
// session.url is the hosted checkout page

API version 2026-07-01SDK 0.3.0Changelogllms.txt