PayMeNow Docs

Merchant API

If you want to automate product management from your own backend โ€” for example to sync your product catalog, create one-off invoices, or run A/B tests on pricing โ€” use the merchant API with your secret key.

Keys

Every PayMeNow merchant has two keys. Find them in your dashboard under Settings.

Key Prefix Where it goes Visibility
API key pmn_live_... Embed data-api-key attribute Public (buyers can see it)
Secret key pmn_sec_... X-API-Secret-Key header from your server Never ship to the browser

If a secret key leaks, rotate it immediately from the dashboard.

Create a product

POST https://paymenow.dev/api/products
X-API-Secret-Key: pmn_sec_...
Content-Type: application/json

{
  "name": "Pro Plan",
  "description": "Monthly subscription",
  "amount": 2500,
  "currency": "usd"
}

Response:

{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "name": "Pro Plan",
  "description": "Monthly subscription",
  "amount": 2500,
  "currency": "usd",
  "active": true,
  "created_at": "2026-10-02T10:00:00Z"
}

Amounts are in the currency's smallest unit (cents, pence, etc).

List products

GET /api/products
X-API-Secret-Key: pmn_sec_...
{ "products": [ { "id": "550e8400-e29b-41d4-a716-446655440000", "name": "Pro Plan", ... } ] }

Returns only active products.

Update a product

PATCH /api/products/{id}
X-API-Secret-Key: pmn_sec_...
Content-Type: application/json

{ "amount": 3000 }

Updatable fields: name, description, amount, currency. name cannot be empty, and amount follows the same rules as create. You can also edit products in the dashboard under Products โ†’ Edit.

Changes apply to new checkouts immediately. Embeds that use the product id charge the new price without any change to your page. Update any price or name you show in your own page text, and the display attributes (data-name, data-amount, data-currency) on add-to-cart buttons. Items already in a buyer's cart keep showing the old price until added again, but are charged the new price.

Deactivate a product

DELETE /api/products/{id}
X-API-Secret-Key: pmn_sec_...

Products are soft-deleted. Payments already created against the product remain in your history.

Using products in the embed

Once you have a product id, drop it in the embed on your site:

<div id="paymenow-form"
  data-api-key="pmn_live_..."
  data-product-id="550e8400-e29b-41d4-a716-446655440000">
</div>
<script src="https://paymenow.dev/embed/paymenow.js"></script>

The embed only sees the public api_key. The amount is resolved server-side at charge time, so buyers cannot tamper with the price.