---
search:
  tags:
    - creditNotes
    - POST
seo:
  description: >-
    Reference for the POST /v1/credit-notes/{creditNoteId}/refund endpoint in
    the Vortex Payments API.
sidebar:
  label: POST /v1/credit-notes/{creditNoteId}/refund
  badge: POST
title: POST /v1/credit-notes/{creditNoteId}/refund
type: openapi-operation
---
`POST /v1/credit-notes/{creditNoteId}/refund`

**curl**

```bash
curl "https://api.vortex.nyc/v1/credit-notes/:creditNoteId/refund?environment=...&merchantAccountId=..." \
  -X POST \
  -H "Authorization: Bearer $VORTEX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{...}'
```

**TypeScript**

```ts
import { refundBillingCreditNote, createVortex } from "@vortex-api/vortex/2026-09";

const vortex = createVortex({ apiKey: process.env.VORTEX_API_KEY });
const { data } = await refundBillingCreditNote({
  client: vortex,
  path: { creditNoteId: "..." },
  query: { environment: "...", merchantAccountId: "..." },
  body: {...},
});
```

**Request body** (`application/json`, required)

- `environment` (string | null)
- `merchantAccountId` (string | null)
- `creditNoteId` (string | null)
- `paymentId` (string | null)
- `requestedByType` (string | null)
- `requestedByRef` (string | null)
- `refundRequestedAt` (string | null)
- `idempotencyKey` (string | null)

Request body example:

```json
{
  "environment": "sandbox",
  "merchantAccountId": "string",
  "creditNoteId": "string",
  "paymentId": "string",
  "requestedByType": "system",
  "requestedByRef": "string",
  "refundRequestedAt": "string",
  "idempotencyKey": "string"
}
```

**Responses**

- `200` — Success

Response example, 200:

```json
{
  "data": {
    "creditNote": {
      "creditNoteId": "string",
      "creditNoteNumber": "string",
      "invoiceId": "string",
      "customerId": "string",
      "billingAccountId": "string",
      "status": "draft",
      "reason": "duplicated_charge",
      "currency": "string",
      "subtotal": 0,
      "discountAdjustmentTotal": 0,
      "taxTotal": 0,
      "total": 0,
      "creditAmount": 0,
      "refundAmount": 0,
      "offsetAmount": 0,
      "balanceAmount": 0,
      "issuedAt": "string",
      "metadata": {
        "property1": "string",
        "property2": "string"
      },
      "subscriptionId": "string",
      "finalizedAt": "string",
      "description": "string",
      "creditStatus": "available",
      "refundStatus": "pending",
      "billingRefundId": "string",
      "paymentsRefundId": "string",
      "refundRequestedAt": "string",
      "refundResolvedAt": "string"
    },
    "lines": [
      {
        "creditNoteLineId": "string",
        "creditNoteId": "string",
        "description": "string",
        "amount": 0,
        "currency": "string",
        "metadata": {
          "property1": "string",
          "property2": "string"
        },
        "invoiceLineId": "string",
        "bucket": "credit",
        "walletRecreditAmount": 0,
        "cashRefundAmount": 0
      }
    ],
    "invoice": {
      "invoiceId": "string",
      "customerId": "string",
      "billingAccountId": "string",
      "status": "draft",
      "currency": "string",
      "subtotal": 0,
      "discountTotal": 0,
      "taxTotal": 0,
      "total": 0,
      "amountPaid": 0,
      "amountRemaining": 0,
      "metadata": {
        "property1": "string",
        "property2": "string"
      },
      "subscriptionId": "string",
      "creditNoteTotal": 0,
      "customerBalanceAppliedTotal": 0,
      "periodStartAt": "string",
      "periodEndAt": "string",
      "issuedAt": "string",
      "dueAt": "string",
      "finalizedAt": "string",
      "voidedAt": "string",
      "createdAt": "string",
      "updatedAt": "string"
    }
  },
  "requestId": "string"
}
```
