API Reference
Reference
Routes, object models, enums, settings, and error shapes.
Route reference
| Method | Route |
|---|---|
| GET | /api/partner/v1/companies |
Auth session Use List user companies Return teams available to the signed-in MakeCrypto user for portal tooling. | |
| POST | /api/partner/v1/onboarding/company |
Auth partner onboarding secret Use Create company onboarding link Create a partner-prefilled company onboarding draft and return a merchant claim URL. Include an oauth block to auto-connect a validated OAuth app after the merchant completes onboarding. | |
| GET | /api/partner/v1/makepay/payment-links |
Auth MakePay API key Use List payment links Return every MakePay payment link for the API key's company. | |
| POST | /api/partner/v1/makepay/payment-links |
Auth MakePay API key or public Use Create payment link Create an API-key merchant payment link, or omit API headers to create an anonymous one-time link. | |
| POST | https://www.makepay.io/api/public/anonymous-payment-links |
Auth public Use Create anonymous payment link Public MakePay endpoint for one-time anonymous checkout links with explicit settlement priorities, branding, and optional webhooks. | |
| POST | /gateway/pay/{makepayKeyId} |
Auth public form key Use Submit HTML payment form Accept browser form fields, create a hosted payment link, and redirect the customer to checkout. | |
| GET | /api/partner/v1/makepay/payment-links/{uid} |
Auth MakePay API key Use Get payment-link detail Return one MakePay payment link with its latest session and timeline events. | |
| PATCH | /api/partner/v1/makepay/payment-links/{uid} |
Auth MakePay API key Use Update payment-link status Set a payment link to active, paused, or archived. | |
| POST | /api/partner/v1/makepay/payment-links/{uid}/send-request-email |
Auth MakePay API key Use Send payment request Send or resend the hosted payment link to a customer email address. | |
| GET | /api/partner/v1/makepay/subscriptions |
Auth MakePay API key Use List subscriptions Return recurring MakePay subscription schedules. | |
| POST | /api/partner/v1/makepay/subscriptions |
Auth MakePay API key Use Create subscription Create a recurring MakePay subscription and first invoice. | |
| GET | /api/partner/v1/makepay/customers |
Auth MakePay API key Use List customers Return MakePay customer profiles for the API key's company. | |
| POST | /api/partner/v1/makepay/customers |
Auth MakePay API key Use Upsert customer Create or update a MakePay customer by email. | |
| POST | /api/partner/v1/makepay/customers/{customerId}/portal |
Auth MakePay API key Use Create customer portal link Generate a 24-hour signed MakePay customer portal URL on demand. | |
| GET | /api/partner/v1/timezones |
Auth public Use List timezones Return supported IANA timezone identifiers. | |
| GET | /api/partner/v1/makepay/settings |
Auth MakePay API key Use Read MakePay settings Read settlement, redirect, fee, checkout policy, and underpayment settings. | |
| PUT | /api/partner/v1/makepay/settings |
Auth MakePay API key Use Update MakePay settings Update settlement asset, product status, redirects, fee policy, and checkout policy. | |
| GET | /api/partner/v1/makepay/destination-assets |
Auth MakePay API key Use List destination assets Return supported settlement assets and the current default asset. | |
| GET | /api/partner/v1/makepay/webhook-requests |
Auth MakePay API key Use List webhook deliveries Inspect payment and subscription webhook delivery attempts and retry state. | |
Partner onboarding OAuth
POST /api/partner/v1/onboarding/company can include an optional oauth
object. MakeCrypto validates the OAuth app, redirect URI, scopes, and PKCE
challenge before creating the onboarding link. When the merchant completes
onboarding, MakeCrypto creates the company, grants the OAuth app access to that
company, and redirects to the registered redirectUri with an authorization
code.
{
"idempotencyKey": "merchant_123",
"company": {
"name": "Acme Markets",
"website": "https://acme.example"
},
"oauth": {
"clientId": "mco_app_example",
"redirectUri": "https://apps.makecrypto.io/oauth/callback",
"scope": "company:read makepay:payment-links:write makepay:settings:read",
"state": "merchant_123",
"codeChallenge": "PKCE_S256_CODE_CHALLENGE",
"codeChallengeMethod": "S256"
}
}
The partner app should keep the matching PKCE code_verifier and exchange the
returned code through POST /oauth/token.
PaymentLink object
| Field | Type | Notes |
|---|---|---|
id | string | Internal UUID. |
uid | string | Public payment-link identifier used in hosted and embedded checkout routes. |
status | "active" | "paused" | "archived" | Merchant-managed link state. |
payload | PaymentLinkPayload | Merchant order, amount, customer, redirect, metadata, branding, and runtime fields. |
created_at | string | ISO timestamp. |
updated_at | string | ISO timestamp. |
expires_at | string | null | Resolved expiration timestamp, or null for no expiration. |
publicUrl | string | Hosted MakePay checkout URL, included on create, list, detail, and status update responses. |
PaymentLinkPayload
| Field | Type | Notes |
|---|---|---|
title | string | Display label for the payment. |
description | string | Customer-facing description. |
amount | string | Decimal amount to collect. |
fiatCurrency | string | Optional display currency such as USD or EUR. |
currency | string | Settlement symbol such as USDT, USDC, or BTC. |
asset | string | Exact destination asset identifier. Use this when a symbol exists on multiple chains. |
skipQuoteAcceptance | boolean | null | Optional per-link checkout policy override. true skips Review, false requires Review, omitted or null inherits merchant settings. |
orderId | string | Merchant order or invoice reference. |
invoicePdfUrl | string | Optional HTTP(S) PDF URL shown as an invoice button in merchant payment details. |
customerEmail | string | Used for email requests and webhook payloads. |
clientId | string | Optional merchant-side customer identifier. |
returnUrl | string | Merchant URL for generic return navigation. |
successUrl | string | Merchant URL for completed payments. |
failureUrl | string | Merchant URL for failed or cancelled payments. |
expirationTime | "15m" | "1h" | "12h" | "24h" | "72h" | "never" | Requested payment-link lifetime. |
metadata | Record<string, unknown> | Merchant-defined metadata returned in dashboards and webhooks. |
runtimeMode | "merchant_target_net_v2" | Injected by the API for new payment links. |
billingVersion | "v2" | Injected by the API for new payment links. |
merchantName | string | Injected from company branding when available. |
merchantPictureUrl | string | Injected from company profile when available. |
merchantLogoUrl | string | Injected from merchant branding when available. |
merchantPaymentLinkTheme | "light" | "dark" | "system" | Injected from merchant checkout theme settings. |
Contact object
| Field | Type | Notes |
|---|---|---|
id | string | Internal UUID. |
uid | string | Public MakePay contact identifier used in portal links. |
email | string | Contact email. |
name | string | null | Contact display name. Editable from the customer portal. |
clientId | string | null | Merchant-side contact identifier. Read-only in the portal. |
metadata | Record<string, unknown> | Merchant-defined metadata. |
createdAt | string | ISO timestamp. |
updatedAt | string | ISO timestamp. |
urls | { customerPortal: string } | Present on portal generation responses. Do not persist this URL. |
Bookkeeping counterparties are also contacts. A contact can be a customer,
vendor, or both, and expense creation searches the same contact list used by
payment links and subscriptions.
Bookkeeping wallet activity
Outgoing chain transfers can be saved from the wallet activity detail modal.
When bookkeeping details are saved for an outgoing transfer, MakeCrypto creates
or updates one expense for that wallet activity, reconciles it through
walletActivityEventId, and carries any private invoice or receipt files linked
to the transfer into the expense evidence view. Re-saving the same transfer is
idempotent and updates the paired expense instead of creating a duplicate.
Expense detail pages show the saved bookkeeping fields, attached files,
reconciliation links, and paired chain-transfer details. The same
createBookkeepingExpenseFromActivity API accepts either
walletActivityEventId or walletActivityEventKey for server-side workflows.
Customer portal response
POST /api/partner/v1/makepay/customers/{customerId}/portal
returns a signed portal URL for the stored customer.
{
"ok": true,
"companyId": "acct_123",
"customer": {
"id": "b834dd77-69b8-41a9-a4b6-95bc9dd14c2d",
"uid": "cus_01hzy4k6p4w9y2x7e2z7n8a2xm",
"email": "buyer@example.com",
"name": "Ada Lovelace",
"clientId": "client_1042",
"metadata": {
"source": "api"
},
"createdAt": "2026-04-20T10:00:00.000Z",
"updatedAt": "2026-04-20T10:00:00.000Z",
"urls": {
"customerPortal": "https://makepay.io/billing?company=acct_123&customer=cus_01hzy4k6p4w9y2x7e2z7n8a2xm&expires=1776765600&signature=8d1f..."
}
},
"expiresAt": "2026-04-21T10:00:00.000Z"
}The URL is valid for 24 hours and uses the company's verified
payment_link_domain when available. Otherwise it falls back to the MakePay
public origin.
| Query parameter | Notes |
|---|---|
company | MakeCrypto company account ID that owns the customer. |
customer | MakePay customer UID. |
expires | Unix timestamp in seconds. |
signature | HMAC signature over v1:{companyId}:{customerUid}:{expires}. |
Generate portal links on demand when the customer opens billing. Expired, tampered, or cross-customer URLs are rejected before portal data is loaded.
Subscription object
| Field | Type | Notes |
|---|---|---|
id | string | Internal UUID. |
uid | string | Merchant-facing subscription identifier. |
status | "active" | "paused" | "overdue" | "cancelled" | Current subscription state. |
customerEmail | string | Customer email used for reminders and portal matching. |
label | string | Customer-facing subscription label. |
description | string | null | Optional subscription description. |
amountUsd | string | Recurring USD amount. |
settlementAsset | string | Destination settlement asset identifier. |
cadence | "weekly" | "biweekly" | "monthly" | "custom_months" | "yearly" | Display cadence. |
billingIntervalUnit | "week" | "month" | "year" | Billing interval unit. |
billingIntervalCount | number | Number of units between billing cycles. |
startAt | string | ISO timestamp for the first billing cycle. |
timezone | string | IANA timezone used for reminder timing. |
metadata | Record<string, unknown> | Merchant-defined metadata and advanced redirect/tolerance settings. |
cycles | SubscriptionCycle[] | Generated billing cycles returned by list routes and dashboard calls. |
Subscriptions move to overdue when an unpaid cycle is at least 24 hours past
its dueAt timestamp. MakePay sends a signed
makepay.subscription.status_changed webhook whenever the subscription status
changes.
MakePaySettings
| Field | Type | Notes |
|---|---|---|
status | "active" | "paused" | Product availability for the team. |
defaultDestinationAsset | string | null | Default asset identifier used when payment links provide only currency. |
feePaidBy | "client" | "merchant" | Default fee payer for MakePay checkouts. A payment link can override this with payload.feePaidBy. |
skipQuoteAcceptance | boolean | Default checkout policy. When true, MakePay accepts the first valid quote and skips the payer Review step unless a link overrides it. |
merchantSurchargePercent | number | Silent quote target adjustment from -1 to 1 percent. |
returnRedirectUrl | string | null | Fallback redirect after checkout. |
successRedirectUrl | string | null | Redirect after completed payment. |
failureRedirectUrl | string | null | Redirect after cancelled or failed payment. |
underpaymentPercentEnabled | boolean | Enables percentage tolerance. |
underpaymentPercentThreshold | number | Allowed underpayment percentage. |
underpaymentFixedEnabled | boolean | Enables fixed tolerance. |
underpaymentFixedThreshold | number | Allowed fixed underpayment amount. |
DestinationAsset
| Field | Type | Notes |
|---|---|---|
assetIdentifier | string | Canonical chain, symbol, and contract identifier. |
chainCode | string | Settlement chain code. |
chainName | string | Human-readable chain name. |
symbol | string | Asset symbol. |
name | string | Asset name. |
decimals | number | Token decimals. |
isDefault | boolean | Whether this asset is the current company default. |
Status values
active: the link can be opened and paid.paused: the link remains visible to the merchant but should not accept new payment starts.archived: the link is hidden from active views and should be treated as closed.
Subscription status values:
active: the subscription is collecting scheduled invoices normally.paused: reminders and merchant/customer changes have paused the subscription.overdue: at least one unpaid cycle is 24 hours or more past its due date.cancelled: the subscription is ended and unpaid generated cycles are cancelled.
Error shape
Errors return JSON with error and, when available, errorCode.
{
"errorCode": "invalid_destination_asset",
"error": "payload.asset ETH.USDT-... is not available for supported settlement routes."
}