Customers

Customer profiles with payment methods, addresses, and billing history

Customers represent the people or businesses you bill. Each customer can have multiple payment methods, addresses, subscriptions, and orders associated with them.

What is a Customer?

A Customer record stores:

  • Contact information - Name, email, phone
  • Payment methods - Cards, bank accounts for future charges
  • Addresses - Billing and shipping addresses
  • Billing history - All invoices, orders, and subscriptions
  • Custom fields - Additional data you define

Customer Fields

FieldTypeDescription
emailstringPrimary email address (required)
namestringFull name or business name
phonestringPhone number
currencystringPreferred currency for invoices
tax_idstringTax identification number (VAT, EIN, etc.)
metadataobjectCustom key-value data

Creating Customers

Automatic Creation

Customers are automatically created when:

  • A new email completes checkout
  • You create an invoice for a new email
  • Imported from integrations (PracticeHub, Wodify, etc.)

Via Dashboard

  1. Navigate to Customer
  2. Click + New Customer
  3. Enter email and other details
  4. Save the customer

Via API

const customer = await client.customers.create({
  email: 'john@example.com',
  name: 'John Smith',
  phone: '+1-555-123-4567',
  currency: 'USD',

  // Optional: Billing address
  address: {
    line1: '123 Main St',
    line2: 'Suite 100',
    city: 'San Francisco',
    state: 'CA',
    postalCode: '94102',
    country: 'US',
  },

  // Optional: Tax ID for business customers
  taxId: 'US123456789',

  // Optional: Custom metadata
  metadata: {
    salesRep: 'jane@company.com',
    tier: 'enterprise',
  },
});

console.log(customer.data.id); // cus_xxxxxxxx

Business Customers (B2B)

For B2B billing, you can associate customers with a business entity:

  • Business name - Legal entity name
  • Tax ID - VAT number, EIN, etc.
  • Business address - Separate from individual address
Enable business checkout in your checkout link settings to collect business information during purchase.

Payment Methods

Customers can have multiple saved payment methods:

TypeDescriptionSupported
CardCredit/debit cards (Visa, Mastercard, Amex, etc.)Yes
ACHUS bank accounts (ACH Direct Debit)Yes
SEPAEuropean bank accountsComing soon

Payment methods are securely tokenized by your payment gateway. RevKeen never stores raw card numbers.

Default Payment Method

One payment method can be marked as default. This is automatically used for:

  • Subscription renewals
  • Auto-pay invoices
  • Retry attempts during dunning

Addresses

Customers can have multiple addresses with different types:

Address TypeUsed For
BillingInvoice "Bill To" address, tax calculations
ShippingPhysical product delivery

Customer Portal

Customers can self-manage their account through the Customer Portal:

  • View and pay invoices
  • Download invoice PDFs
  • Update payment methods
  • Manage subscriptions (pause, cancel)
  • View billing history
Customer Portal is available at checkout.revkeen.com/portal/[your-slug]

Custom Fields

Extend customer data with custom fields defined in Settings → Custom Fields:

  • Text fields (IDs, notes)
  • Numbers (account numbers, scores)
  • Dates (birthdays, contract dates)
  • Dropdowns (status, category)
  • Checkboxes (preferences, consent)

Customer Events

EventWhen Triggered
customer.createdCustomer record is created
customer.updatedCustomer details are modified
customer.payment_method.attachedPayment method is added
customer.payment_method.detachedPayment method is removed

Related