Fiat Payment Settings
These endpoints let you read and update your default service-fee payer for fiat (card) payments. This setting is used as the default for fiat checkout flows whenserviceFeePayer is not explicitly provided per order.
You can represent the same setting in two UI-friendly ways:
serviceFeePayerDefault:"customer"or"merchant"customerPaysServiceFee:trueorfalse
Endpoints
GET /api/fiat/settingsPATCH /api/fiat/settings
These endpoints are protected. You must be authenticated.
Base URL
All examples use:https://www.niftipay.com
Authentication
These endpoints support two authentication methods:1) API Key (recommended for integrations)
Send your API key in thex-api-key header.
2) Session cookie (browser / dashboard usage)
If you are authenticated via the dashboard.Get Fiat Settings
Endpoint
GET /api/fiat/settings
Returns your current fiat settings.
Response fields
| Field | Type | Notes |
|---|---|---|
serviceFeePayerDefault | string | "customer" or "merchant". |
customerPaysServiceFee | boolean | Convenience boolean for UI toggle. true means customer pays. |
Example request
Example response (customer pays by default)
Example response (merchant pays by default)
Update Fiat Settings
Endpoint
PATCH /api/fiat/settings
Updates your default fiat service-fee payer.
You can send either payload format
Option A — explicit enum
Option B — boolean toggle (UI friendly)
truemaps to"customer"andfalsemaps to"merchant".
Example: set default to customer pays
Example response
Example: set default to merchant pays (using boolean)
Example response
Error responses
Invalid JSON (400)
If the request body is not valid JSON:Invalid payload (400)
If you don’t provide a valid payer using one of the supported formats:{ "serviceFeePayerDefault": "user" }{ "customerPaysServiceFee": "sometimes" }{}
Missing migration/table (500)
This route requires the fiat settings table to exist for writes. If theuserFiatSetting table is missing, PATCH returns: