---
title: "refund"
method: POST
path: "/api/secretary-acceptor/purchase/refund"
tags: ["secretary-acceptor-resource"]
---

# refund

`POST /api/secretary-acceptor/purchase/refund`

## Request

- Base URL: `https://api.neonclub.ir`
- URL: `https://api.neonclub.ir/api/secretary-acceptor/purchase/refund`
- Auth: none declared
- TypeScript: <https://skmtc.dev/neonclub/apis/ayria-api/docs/api/secretary-acceptor/purchase/refund/post.ts> (a function with typed inputs; its response is checked against the schema)

## Request body

- PurchaseRefundCommand
  - `acceptorCode` string
  - `purchaseId` integer
  - `refundReason` 'POOR_QUALITY' | 'FOUND_BETTER_ALTERNATIVE' | 'LATE_DELIVERY' | 'CHANGED_MY_MIND' | 'I_NEED_ITS_MONEY' | 'USER_MISTAKE'

## Response `200`

OK

- PspPurchaseDTO
  - `acceptorAmount` number
  - `acceptorAmountActual` number
  - `acceptorCode` string
  - `acceptorDepartment` 'SPORT' | 'CLOTHING' | 'CONSULTING' | 'DIGITAL' | 'RESTAURANT' | 'HEALTH' | 'SCIENCE' | 'STORE' | 'TRAVEL' | 'HOME_APPLIANCE' | 'BEAUTY' | 'JEWELLERY' | 'CULTURE' | 'FORMALITY' | 'ART' | 'CAR' | 'BUILDING'
  - `acceptorName` string
  - `canceled` boolean
  - `city` string
  - `customerAmount` number
  - `customerAmountActual` number
  - `customerAmountDouble` number, double
  - `customerMobile` string
  - `customerName` string
  - `discountAmount` number
  - `discountAmountDouble` number, double
  - `discountAmountOk` boolean
  - `id` integer
  - `metadata` PurchaseMetadataDTO
    - `scoreAmount` number
    - `scoreExchangedValue` number
    - `voucherAmount` number
  - `paymentMethod` 'WALLET' | 'CASH' | 'POS'
  - `purchaseDate` string
  - `purchaseDatePersian` string
  - `purchasePayType` 'CASH' | 'POS' | 'WALLET' | 'SCORE' | 'SCORE_AND_WALLET'
  - `purchaseTime` string
  - `purchaseTimePersian` string
  - `rate` integer
  - `rateComplaints` string
  - `reductionAmount` number
  - `referenceNumber` integer
  - `refundDate` string
  - `refundReason` 'POOR_QUALITY' | 'FOUND_BETTER_ALTERNATIVE' | 'LATE_DELIVERY' | 'CHANGED_MY_MIND' | 'I_NEED_ITS_MONEY' | 'USER_MISTAKE'
  - `refundable` boolean
  - `refunded` boolean
  - `refunder` string
  - `sharedAmount` number
  - `state` string
  - `terminal` string
  - `totalAmount` number
  - `trackingNumber` integer
  - `transactionId` integer
  - `unitedAmount` number
  - `voucherAmount` number
  - `voucherAmountOk` boolean

## Other responses

- `201`: Created
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found

---

[API](https://skmtc.dev/neonclub/apis/ayria-api.md) - [All operations](https://skmtc.dev/neonclub/apis/ayria-api/llms.txt) - [OpenAPI document](https://skmtc.dev/neonclub/apis/ayria-api/revisions/1f6b876e9f89?raw)
