# Charge a saved payment method

> Charges a customer's saved payment method without the customer being present.

Source: https://docs.tappay.mn/reference/payments/create/

Charges a [customer](https://docs.tappay.mn/glossary.md#customer)'s saved [payment](https://docs.tappay.mn/glossary.md#payment) method without the customer being present. Send the `customer`, the `paymentMethod`, the `amount` and a `description`.

`POST /api/v1/payments` Since 2026-09-27

### Authentication

Secret key (Bearer)

### Headers

| Name | Type | Required | Values | Description |
| - | - | - | - | - |
| `TapPay-Version` | string | no | | |
| `TapPay-Timestamp` | string | no | | |
| `TapPay-Nonce` | string | no | | |
| `TapPay-Signature` | string | no | | |
| `Idempotency-Key` | string | yes | | |

### Request body

| Name | Type | Required | Values | Description |
| - | - | - | - | - |
| `customer` | string | yes | | |
| `paymentMethod` | string | yes | | |
| `amount` | number | yes | | |
| `description` | string | yes | | |
| `orderId` | string | no | | |
| `terminalId` | string (uuid) | no | | |

### Response 201

| Name | Type | Required | Values | Description |
| - | - | - | - | - |
| `success` | boolean | yes | `true` | |
| `data` | object | yes | | |
| `data.id` | string | yes | | |
| `data.intentId` | string | yes | | |
| `data.invoiceId` | string \| null | yes | | |
| `data.status` | string | yes | `PROCESSING`, `SUCCEEDED`, `FAILED`, `OVERPAID`, `AUTHORIZED`, `CANCELLED` | |
| `data.amount` | number | yes | | |
| `data.currency` | string | yes | | |
| `data.channel` | string | yes | `QPAY`, `NODE_QR`, `WECHAT`, `CARD`, `R2P` | |
| `data.payerWallet` | object \| null | yes | | |
| `data.payerWallet.code` | string | yes | | |
| `data.payerWallet.name` | string | yes | | |
| `data.payerWallet.logoUrl` | string \| null | yes | | |
| `data.payerWallet.type` | string | yes | `APP`, `WEB`, `WECHAT` | |
| `data.sticker` | object \| null | yes | | |
| `data.sticker.serialNo` | string \| null | yes | | |
| `data.sticker.sqrRef` | string | yes | | |
| `data.sticker.name` | string \| null | yes | | |
| `data.feeAmount` | number \| null | yes | | |
| `data.merchantNet` | number \| null | yes | | |
| `data.serviceFeeMerchant` | number | yes | | |
| `data.serviceFeeCustomer` | number | yes | | |
| `data.succeededAt` | string \| null | yes | | |
| `data.createdAt` | string | yes | | |
| `data.fulfillment` | object \| null | yes | | |
| `data.fulfillment.status` | string | yes | `PENDING`, `IN_PROGRESS`, `COMPLETED`, `FAILED`, `CANCELLED` | |
| `data.fulfillment.stage` | string \| null | yes | | |
| `data.fulfillment.message` | string \| null | yes | | |
| `data.fulfillment.updatedAt` | string (date-time) | yes | | |
| `data.receipt` | object \| null | yes | | |
| `data.receipt.receipt` | object | yes | | |
| `data.receipt.receipt.id` | string (uuid) | yes | | |
| `data.receipt.receipt.status` | string | yes | `PENDING`, `REGISTERED`, `FAILED`, `RETURNED` | |
| `data.receipt.receipt.issuer` | string | yes | `MERCHANT`, `NODE` | |
| `data.receipt.receipt.receiptType` | string \| null | yes | `B2C`, `B2B`, `SALES`, `null` | |
| `data.receipt.receipt.ddtd` | string \| null | yes | | |
| `data.receipt.receipt.lottery` | string \| null | yes | | |
| `data.receipt.receipt.qrData` | string \| null | yes | | |
| `data.receipt.receipt.url` | string \| null | yes | | |
| `data.receipt.receipt.merchantReceiptNo` | string \| null | yes | | |
| `data.receipt.receipt.amount` | string \| null | yes | | |
| `data.receipt.receipt.vat` | string \| null | yes | | |
| `data.receipt.receipt.cityTax` | string \| null | yes | | |
| `data.receipt.receipt.issuedAt` | string \| null | yes | | |
| `data.receipt.receipt.returnedAt` | string \| null | yes | | |
| `data.receipt.receipt.failureReason` | string \| null | yes | | |
| `data.receipt.receipt.lines` | array \| null | yes | | |
| `data.receipt.receipt.attempts` | integer | yes | | |
| `data.receipt.receipt.nextAttemptAt` | string \| null | yes | | |
| `data.receipt.receipt.recipientFallback` | boolean | yes | | |
| `data.receipt.receipt.parts` | array \| null | yes | | |
| `data.receipt.history` | array\<object> | yes | | |
| `data.receipt.history[].id` | string (uuid) | yes | | |
| `data.receipt.history[].status` | string | yes | `PENDING`, `REGISTERED`, `FAILED`, `RETURNED` | |
| `data.receipt.history[].issuer` | string | yes | `MERCHANT`, `NODE` | |
| `data.receipt.history[].receiptType` | string \| null | yes | `B2C`, `B2B`, `SALES`, `null` | |
| `data.receipt.history[].ddtd` | string \| null | yes | | |
| `data.receipt.history[].lottery` | string \| null | yes | | |
| `data.receipt.history[].qrData` | string \| null | yes | | |
| `data.receipt.history[].url` | string \| null | yes | | |
| `data.receipt.history[].merchantReceiptNo` | string \| null | yes | | |
| `data.receipt.history[].amount` | string \| null | yes | | |
| `data.receipt.history[].vat` | string \| null | yes | | |
| `data.receipt.history[].cityTax` | string \| null | yes | | |
| `data.receipt.history[].issuedAt` | string \| null | yes | | |
| `data.receipt.history[].returnedAt` | string \| null | yes | | |
| `data.receipt.history[].failureReason` | string \| null | yes | | |
| `data.receipt.history[].lines` | array \| null | yes | | |
| `data.receipt.history[].attempts` | integer | yes | | |
| `data.receipt.history[].nextAttemptAt` | string \| null | yes | | |
| `data.receipt.history[].recipientFallback` | boolean | yes | | |
| `data.receipt.history[].parts` | array \| null | yes | | |
| `data.ebarimt` | object \| null | yes | | |
| `data.ebarimt.id` | string (uuid) | yes | | |
| `data.ebarimt.status` | string | yes | `PENDING`, `REGISTERED`, `FAILED`, `RETURNED` | |
| `data.ebarimt.issuer` | string | yes | `MERCHANT`, `NODE` | |
| `data.ebarimt.receiptType` | string \| null | yes | `B2C`, `B2B`, `SALES`, `null` | |
| `data.ebarimt.ddtd` | string \| null | yes | | |
| `data.ebarimt.lottery` | string \| null | yes | | |
| `data.ebarimt.qrData` | string \| null | yes | | |
| `data.ebarimt.url` | string \| null | yes | | |
| `data.ebarimt.merchantReceiptNo` | string \| null | yes | | |
| `data.ebarimt.amount` | string \| null | yes | | |
| `data.ebarimt.vat` | string \| null | yes | | |
| `data.ebarimt.cityTax` | string \| null | yes | | |
| `data.ebarimt.issuedAt` | string \| null | yes | | |
| `data.ebarimt.returnedAt` | string \| null | yes | | |
| `data.ebarimt.failureReason` | string \| null | yes | | |
| `data.ebarimt.lines` | array \| null | yes | | |
| `data.ebarimt.attempts` | integer | yes | | |
| `data.ebarimt.nextAttemptAt` | string \| null | yes | | |
| `data.ebarimt.recipientFallback` | boolean | yes | | |
| `data.ebarimt.parts` | array \| null | yes | | |
| `data.authorizationType` | string | yes | `FINAL`, `PREAUTH` | |
| `data.preauthMode` | string \| null | yes | `CHARGE_REFUND`, `HOLD`, `null` | |
| `data.preauthStatus` | string \| null | yes | `OPEN`, `FINALIZED`, `AUTO_FINALIZED`, `null` | |
| `data.finalAmount` | string \| null | yes | | |
| `data.finalizeDueAt` | string \| null | yes | | |
| `data.authorizedAt` | string \| null | yes | | |
| `data.preauthRefundId` | string \| null | yes | | |
| `data.paymentMethodId` | string | no | | |
| `data.customer` | string | no | | |
| `data.failureCode` | string \| null | no | | |
| `data.declineRetryable` | boolean | no | | |
| `data.ebarimtRecipient` | object \| null | yes | | |
| `data.ebarimtRecipient.type` | string | yes | `CITIZEN`, `ORG`, `NONE` | |
| `data.ebarimtRecipient.register` | string \| null | yes | | |
| `data.ebarimtRecipient.tin` | string \| null | yes | | |
| `data.ebarimtRecipient.email` | string \| null | yes | | |
| `data.settlement` | object \| null | yes | | |
| `data.settlement.cycleId` | string (uuid) | yes | | |
| `data.settlement.businessDate` | string | yes | | |
| `data.settlement.seq` | integer | yes | | |
| `data.settlement.status` | string | yes | `OPEN`, `RUNNING`, `CLOSED`, `CARRIED` | |
| `data.settlement.credited` | boolean | yes | | |
| `data.promotions` | array\<object> | no | | |
| `data.promotions[].promotionId` | string (uuid) | yes | | |
| `data.promotions[].kind` | string | yes | | |
| `data.promotions[].amount` | number | yes | | |

### Errors

| Code | Status | Message |
| - | - | - |
| [`AUTH-001`](https://docs.tappay.mn/errors.md#AUTH-001) | 401 | The API key is missing, invalid or revoked. |
| [`EVT-206`](https://docs.tappay.mn/errors.md#EVT-206) | 401 | Production keys are not accepted in the sandbox. Use a sandbox key (sk_test\_/pk_test\_). |
| [`EVT-207`](https://docs.tappay.mn/errors.md#EVT-207) | 401 | Sandbox keys are not accepted in production. Use a production key (sk_live\_/pk_live\_). |
| [`AUTH-018`](https://docs.tappay.mn/errors.md#AUTH-018) | 403 | The request came from an IP address that is not on the key's allowlist. |
| [`AUTH-058`](https://docs.tappay.mn/errors.md#AUTH-058) | 403 | The API key does not have the scope this operation requires. |
| [`SIG-002`](https://docs.tappay.mn/errors.md#SIG-002) | 401 | The request timestamp is outside the allowed time window. |
| [`SIG-003`](https://docs.tappay.mn/errors.md#SIG-003) | 401 | The request signature is missing or does not match. |
| [`SIG-005`](https://docs.tappay.mn/errors.md#SIG-005) | 409 | This request nonce was already used. |
| [`VAL-014`](https://docs.tappay.mn/errors.md#VAL-014) | 400 | The TapPay-Version header is not a known API version. |
| [`BIZ-004`](https://docs.tappay.mn/errors.md#BIZ-004) | 403 | The terminal is not active. |
| [`BIZ-005`](https://docs.tappay.mn/errors.md#BIZ-005) | 403 | The merchant account is not in a state that allows this request. |
| [`VAL-002`](https://docs.tappay.mn/errors.md#VAL-002) | 400 | A required field or header is missing. |
| [`VAL-010`](https://docs.tappay.mn/errors.md#VAL-010) | 409 | This Idempotency-Key was already used with a different request body. |
| [`VAL-013`](https://docs.tappay.mn/errors.md#VAL-013) | 409 | A request with this Idempotency-Key is still being processed. |
| [`VAL-001`](https://docs.tappay.mn/errors.md#VAL-001) | 400 | The request failed validation. |
| [`VAL-005`](https://docs.tappay.mn/errors.md#VAL-005) | 400 | A date value is not valid. |
| [`VAL-009`](https://docs.tappay.mn/errors.md#VAL-009) | 400 | A string value is longer than the allowed maximum. |
| [`PAY-001`](https://docs.tappay.mn/errors.md#PAY-001) | 404 | The invoice was not found. |
| [`PAY-012`](https://docs.tappay.mn/errors.md#PAY-012) | 409 | The payment intent is no longer open. |
| [`PAY-017`](https://docs.tappay.mn/errors.md#PAY-017) | 422 | The amount is greater than the remaining amount to pay. |
| [`PAY-027`](https://docs.tappay.mn/errors.md#PAY-027) | 409 | The invoice cannot be paid in its current state. |
| [`PAY-031`](https://docs.tappay.mn/errors.md#PAY-031) | 422 | The customer was not found. |
| [`BIZ-002`](https://docs.tappay.mn/errors.md#BIZ-002) | 400 | The merchant's daily limit would be exceeded. |
| [`BIZ-013`](https://docs.tappay.mn/errors.md#BIZ-013) | 404 | The terminal was not found. |
| [`SET-002`](https://docs.tappay.mn/errors.md#SET-002) | 400 | A required platform setting is missing or unknown. |
| [`SET-007`](https://docs.tappay.mn/errors.md#SET-007) | 422 | The value violates a platform limit. |
| [`FSC-013`](https://docs.tappay.mn/errors.md#FSC-013) | 500 | The fee could not be calculated because the destination cannot be resolved. |
| [`PYO-207`](https://docs.tappay.mn/errors.md#PYO-207) | 422 | The split beneficiary is not active. |
| [`EVT-202`](https://docs.tappay.mn/errors.md#EVT-202) | 422 | The test card number is not a known sandbox test card. |
| [`AFP-001`](https://docs.tappay.mn/errors.md#AFP-001) | 409 | The payment intent is locked by another operation. |
| [`RCR-002`](https://docs.tappay.mn/errors.md#RCR-002) | 422 | The customer request body is not valid. |
| [`RCR-003`](https://docs.tappay.mn/errors.md#RCR-003) | 404 | The payment method was not found. |
| [`RCR-004`](https://docs.tappay.mn/errors.md#RCR-004) | 422 | This kind of payment method is not available. |
| [`RCR-012`](https://docs.tappay.mn/errors.md#RCR-012) | 422 | The provider credentials required for this payment are not configured. |
| [`RCR-051`](https://docs.tappay.mn/errors.md#RCR-051) | 422 | Merchant-initiated payments are not enabled for this merchant. |
| [`RCR-052`](https://docs.tappay.mn/errors.md#RCR-052) | 422 | The payment method requires action from the customer before it can be charged. |
| [`RCR-053`](https://docs.tappay.mn/errors.md#RCR-053) | 422 | The payment method is not active. |
| [`RCR-054`](https://docs.tappay.mn/errors.md#RCR-054) | 422 | The payment rail does not support merchant-initiated payments. |
| [`RCR-055`](https://docs.tappay.mn/errors.md#RCR-055) | 422 | The mandate limit does not allow this charge. |
| [`RCR-056`](https://docs.tappay.mn/errors.md#RCR-056) | 422 | The retry limit for this merchant-initiated payment has been reached. |
| [`RCR-057`](https://docs.tappay.mn/errors.md#RCR-057) | 422 | The payment method's usage does not match this payment. |
| [`SVC-044`](https://docs.tappay.mn/errors.md#SVC-044) | 422 | The merchant service configuration is not valid. |
| [`PRE-002`](https://docs.tappay.mn/errors.md#PRE-002) | 422 | A field in the request is not allowed for pre-authorization payments. |
| [`PRE-014`](https://docs.tappay.mn/errors.md#PRE-014) | 422 | The authorization type is not allowed for this payment. |
| [`RCR-059`](https://docs.tappay.mn/errors.md#RCR-059) | 422 | The card token's scope does not allow this payment. |

Try it in the playground: https://docs.tappay.mn/reference/payments/create/

```bash title="curl"
curl -sS -X POST "https://api.tappay.mn/api/v1/payments" \
  -H "Authorization: Bearer sk_test_YOUR_SECRET_KEY" \
  -H "TapPay-Version: 2026-09-27" \
  -H "Idempotency-Key: $(openssl rand -hex 16)" \
  -H "Content-Type: application/json" \
  -d '{"terminalId":"YOUR_TERMINAL_ID","customer":"CUSTOMER_ID","paymentMethod":"PAYMENT_METHOD_ID","amount":500,"description":"Monthly fee"}'
```

```js title="Node.js"
import { TapPay } from '@tappay-mn/node';

const tappay = new TapPay({ apiKey: 'sk_test_YOUR_SECRET_KEY' });
const payment = await tappay.payments.create({
  body: {
    terminalId: 'YOUR_TERMINAL_ID',
    customer: 'CUSTOMER_ID',
    paymentMethod: 'PAYMENT_METHOD_ID',
    amount: 500,
    description: 'Monthly fee',
  },
});
console.log(JSON.stringify(payment));
```

```php title="PHP"
<?php
require 'vendor/autoload.php';

use TapPay\TapPay;

$tappay = new TapPay(['apiKey' => 'sk_test_YOUR_SECRET_KEY']);
$payment = $tappay->payments->create([
    'body' => [
        'terminalId' => 'YOUR_TERMINAL_ID',
        'customer' => 'CUSTOMER_ID',
        'paymentMethod' => 'PAYMENT_METHOD_ID',
        'amount' => 500,
        'description' => 'Monthly fee',
    ],
]);
echo json_encode($payment);
```

```python title="Python"
import json
import tappay

client = tappay.TapPay("sk_test_YOUR_SECRET_KEY")
payment = client.payments.create({
    "body": {
        "terminalId": "YOUR_TERMINAL_ID",
        "customer": "CUSTOMER_ID",
        "paymentMethod": "PAYMENT_METHOD_ID",
        "amount": 500,
        "description": "Monthly fee",
    },
})
print(json.dumps(payment))
```

```json title="Response"
{
  "success": true,
  "data": {
    "id": "0192f8a4-1b2c-7d3e-8f40-5a6b7c8d9e04",
    "ebarimt": null,
    "intentId": "0192f8a4-1b2c-7d3e-8f40-5a6b7c8d9e03",
    "invoiceId": "0192f8a4-1b2c-7d3e-8f40-5a6b7c8d9e01",
    "status": "SUCCEEDED",
    "amount": 500,
    "currency": "MNT",
    "channel": "CARD",
    "payerWallet": null,
    "sticker": null,
    "feeAmount": 8,
    "merchantNet": 492,
    "serviceFeeMerchant": 0,
    "serviceFeeCustomer": 0,
    "succeededAt": "2026-10-03T08:16:12.000Z",
    "createdAt": "2026-10-03T08:16:12.000Z",
    "fulfillment": null,
    "receipt": null,
    "authorizationType": "FINAL",
    "preauthMode": null,
    "preauthStatus": null,
    "finalAmount": null,
    "finalizeDueAt": null,
    "authorizedAt": null,
    "preauthRefundId": null,
    "ebarimtRecipient": null,
    "settlement": null
  }
}
```

> **Note:** **Merchant-initiated charge**
>
> This call needs no action from the customer. It returns `422` with `RCR-051` when merchant-initiated payments are not enabled for your merchant.

For the full flow, read the [guide](https://docs.tappay.mn/guides/customers-recurring.md).
