Skip to main content
POST
/
v0
/
customers
Create
curl --request POST \
  --url https://api.paygentic.io/v0/customers \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "consumer": {
    "name": "<string>",
    "email": "jsmith@example.com",
    "phone": "<string>",
    "address": {
      "line1": "<string>",
      "line2": "<string>",
      "city": "<string>",
      "state": "<string>",
      "country": "<string>",
      "zipCode": "<string>"
    }
  },
  "consumerId": "<string>",
  "merchantId": "<string>",
  "taxId": "<string>",
  "taxRates": {}
}'
{
  "customerId": "cus_h3i4j5k6l7m8n9o0",
  "validTaxAddress": {
    "message": null,
    "valid": true
  }
}

Authorizations

Authorization
string
header
required

API key authentication

Body

application/json
merchantId
string
required

The unique identifier for the merchant organization.

consumer
object

Fields to create a new consumer. Will use an existing consumer if one exists with the same email address. Required if consumerId is not provided. Address with complete tax information (country, state, zipCode) is required for tax calculation when using Paygentic Tax.

consumerId
string

The unique identifier for the consumer. Required if consumer is not provided.

taxId
string

Optional business tax registration identifier. Sample values: 'GB123456789' for UK VAT, 'DE123456789' for German VAT, 'FR12345678901' for French VAT. Supplying this value enables inter-company tax handling and exemption from standard tax collection.

taxRates
object

An object mapping plan IDs, metric IDs, or 'default' to a tax rate percentage (e.g., 13 for 13%)

Response

Customer already exists

customerId
string
required
validTaxAddress
object
required

Indicates whether the consumer address is valid for tax calculation when using Paygentic Tax. If valid=false, tax calculation will be skipped and internal invoice flow with default tax rate will be used.