Create refund transaction
using System.Net.Http.Headers;var client = new HttpClient();var request = new HttpRequestMessage{ Method = HttpMethod.Post, RequestUri = new Uri("https://api.diller.app/api/v2.0/stores/your-store-id/members/m_nsr714RRBEHX/transactions/your-transaction-id/refund"), Headers = { { "Authorization", "Bearer <token>" }, }, Content = new StringContent("{ \"reason\": \"example\", \"external_id\": \"example\", \"external_receipt_id\": \"example\", \"created_at\": \"2026-04-15T12:00:00Z\", \"payment_details\": [ { \"payment_method\": \"example\", \"sub_total\": 1 } ], \"eft_pos\": \"example\", \"total\": 1, \"total_tax\": 1, \"total_discount\": 1, \"currency\": \"example\", \"round_off_amount\": 1, \"origin\": { \"system_id\": \"example\", \"employee_id\": \"example\", \"department_id\": \"example\", \"department_name\": \"example\", \"channel\": \"example\" }, \"details\": [ { \"product\": { \"external_id\": \"example\", \"sku\": \"example\", \"name\": \"example\", \"brand\": \"example\", \"external_voucher_id\": \"example\", \"category\": { \"name\": \"example\", \"external_id\": \"example\" }, \"gtin\": { \"type\": \"Isbn\", \"code\": \"example\" } }, \"quantity\": 1, \"unit_price\": 1, \"unit_measure\": \"example\", \"tax_percentage\": 1, \"discount\": 1, \"total_price\": 1, \"deducted_stamps\": [ { \"stamp_card_id\": 1, \"count\": 1 } ] } ], \"department_id\": \"example\" }") { Headers = { ContentType = new MediaTypeHeaderValue("application/json") } }};using (var response = await client.SendAsync(request)){ response.EnsureSuccessStatusCode(); var body = await response.Content.ReadAsStringAsync(); Console.WriteLine(body);}package main
import ( "fmt" "strings" "net/http" "io")
func main() {
url := "https://api.diller.app/api/v2.0/stores/your-store-id/members/m_nsr714RRBEHX/transactions/your-transaction-id/refund"
payload := strings.NewReader("{ \"reason\": \"example\", \"external_id\": \"example\", \"external_receipt_id\": \"example\", \"created_at\": \"2026-04-15T12:00:00Z\", \"payment_details\": [ { \"payment_method\": \"example\", \"sub_total\": 1 } ], \"eft_pos\": \"example\", \"total\": 1, \"total_tax\": 1, \"total_discount\": 1, \"currency\": \"example\", \"round_off_amount\": 1, \"origin\": { \"system_id\": \"example\", \"employee_id\": \"example\", \"department_id\": \"example\", \"department_name\": \"example\", \"channel\": \"example\" }, \"details\": [ { \"product\": { \"external_id\": \"example\", \"sku\": \"example\", \"name\": \"example\", \"brand\": \"example\", \"external_voucher_id\": \"example\", \"category\": { \"name\": \"example\", \"external_id\": \"example\" }, \"gtin\": { \"type\": \"Isbn\", \"code\": \"example\" } }, \"quantity\": 1, \"unit_price\": 1, \"unit_measure\": \"example\", \"tax_percentage\": 1, \"discount\": 1, \"total_price\": 1, \"deducted_stamps\": [ { \"stamp_card_id\": 1, \"count\": 1 } ] } ], \"department_id\": \"example\" }")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>") req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close() body, _ := io.ReadAll(res.Body)
fmt.Println(res) fmt.Println(string(body))
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");RequestBody body = RequestBody.create(mediaType, "{ \"reason\": \"example\", \"external_id\": \"example\", \"external_receipt_id\": \"example\", \"created_at\": \"2026-04-15T12:00:00Z\", \"payment_details\": [ { \"payment_method\": \"example\", \"sub_total\": 1 } ], \"eft_pos\": \"example\", \"total\": 1, \"total_tax\": 1, \"total_discount\": 1, \"currency\": \"example\", \"round_off_amount\": 1, \"origin\": { \"system_id\": \"example\", \"employee_id\": \"example\", \"department_id\": \"example\", \"department_name\": \"example\", \"channel\": \"example\" }, \"details\": [ { \"product\": { \"external_id\": \"example\", \"sku\": \"example\", \"name\": \"example\", \"brand\": \"example\", \"external_voucher_id\": \"example\", \"category\": { \"name\": \"example\", \"external_id\": \"example\" }, \"gtin\": { \"type\": \"Isbn\", \"code\": \"example\" } }, \"quantity\": 1, \"unit_price\": 1, \"unit_measure\": \"example\", \"tax_percentage\": 1, \"discount\": 1, \"total_price\": 1, \"deducted_stamps\": [ { \"stamp_card_id\": 1, \"count\": 1 } ] } ], \"department_id\": \"example\" }");Request request = new Request.Builder() .url("https://api.diller.app/api/v2.0/stores/your-store-id/members/m_nsr714RRBEHX/transactions/your-transaction-id/refund") .post(body) .addHeader("Authorization", "Bearer <token>") .addHeader("Content-Type", "application/json") .build();
Response response = client.newCall(request).execute();import axios from 'axios';
const options = { method: 'POST', url: 'https://api.diller.app/api/v2.0/stores/your-store-id/members/m_nsr714RRBEHX/transactions/your-transaction-id/refund', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, data: { reason: 'example', external_id: 'example', external_receipt_id: 'example', created_at: '2026-04-15T12:00:00Z', payment_details: [{payment_method: 'example', sub_total: 1}], eft_pos: 'example', total: 1, total_tax: 1, total_discount: 1, currency: 'example', round_off_amount: 1, origin: { system_id: 'example', employee_id: 'example', department_id: 'example', department_name: 'example', channel: 'example' }, details: [ { product: { external_id: 'example', sku: 'example', name: 'example', brand: 'example', external_voucher_id: 'example', category: {name: 'example', external_id: 'example'}, gtin: {type: 'Isbn', code: 'example'} }, quantity: 1, unit_price: 1, unit_measure: 'example', tax_percentage: 1, discount: 1, total_price: 1, deducted_stamps: [{stamp_card_id: 1, count: 1}] } ], department_id: 'example' }};
try { const { data } = await axios.request(options); console.log(data);} catch (error) { console.error(error);}const url = 'https://api.diller.app/api/v2.0/stores/your-store-id/members/m_nsr714RRBEHX/transactions/your-transaction-id/refund';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"reason":"example","external_id":"example","external_receipt_id":"example","created_at":"2026-04-15T12:00:00Z","payment_details":[{"payment_method":"example","sub_total":1}],"eft_pos":"example","total":1,"total_tax":1,"total_discount":1,"currency":"example","round_off_amount":1,"origin":{"system_id":"example","employee_id":"example","department_id":"example","department_name":"example","channel":"example"},"details":[{"product":{"external_id":"example","sku":"example","name":"example","brand":"example","external_voucher_id":"example","category":{"name":"example","external_id":"example"},"gtin":{"type":"Isbn","code":"example"}},"quantity":1,"unit_price":1,"unit_measure":"example","tax_percentage":1,"discount":1,"total_price":1,"deducted_stamps":[{"stamp_card_id":1,"count":1}]}],"department_id":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.diller.app/api/v2.0/stores/your-store-id/members/m_nsr714RRBEHX/transactions/your-transaction-id/refund \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "reason": "example", "external_id": "example", "external_receipt_id": "example", "created_at": "2026-04-15T12:00:00Z", "payment_details": [ { "payment_method": "example", "sub_total": 1 } ], "eft_pos": "example", "total": 1, "total_tax": 1, "total_discount": 1, "currency": "example", "round_off_amount": 1, "origin": { "system_id": "example", "employee_id": "example", "department_id": "example", "department_name": "example", "channel": "example" }, "details": [ { "product": { "external_id": "example", "sku": "example", "name": "example", "brand": "example", "external_voucher_id": "example", "category": { "name": "example", "external_id": "example" }, "gtin": { "type": "Isbn", "code": "example" } }, "quantity": 1, "unit_price": 1, "unit_measure": "example", "tax_percentage": 1, "discount": 1, "total_price": 1, "deducted_stamps": [ { "stamp_card_id": 1, "count": 1 } ] } ], "department_id": "example" }'Allows for the partial refund of a previous transaction, without taking into account any coupons or stamp cards applied earlier.
If the entire transaction needs to be refunded, consider using the “cancel transaction” endpoint, as it fully reverses the transaction, including coupons and stamp cards.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Store Id
Example
your-store-idMember Id
Example
m_nsr714RRBEHXThe original transaction Id that is being refunded (external_id) from CreateTransaction
Example
your-transaction-idRequest Body
Section titled “Request Body”CreateRefundTransactionRequest object
object
The store’s transaction unique identifier. Eg. Order-1234
The date and time the transaction was created represented as ISO 8601-encoded string.
For example: January 1, 2025 at 13:00, in the time zone of UTC (Coordinated Universal Time) is represented as “2025-01-01T13:00:00Z” or “2025-01-01T13:00:00+00:00”. Important: If no offset is present, then UTC is assumed by default (not the store local time).
object
Electronic funds transfer at point of sale
Total amount paid by the customer, after discounts and taxes
Total amount of taxes paid
Discount amount applied to this purchase
Stores the specific value used for rounding calculations
Represents the origin of the request, by department, employee, system id and channel. Eg. Employee John Doe at Pos number 10 in the store department “New York” submitted this request.
object
The id for of the operator that made the request (if applicable)
Represents the business channel through which the API call occurred. It accepts ‘POS’ for Point-of-Sale systems and ‘OnlineStore’ for online stores. When the channel is empty or not recognized, it defaults to ‘POS’.
object
object
Store’s Product Id
Product Id that identifies the product along all channels (POS, Woocommerce, Shopify, etc.)
object
Defines the GTIN type for the global identifier code e.g. EAN, UPC, ISBN, etc.
object
Unit price including taxes
Value stored from 0.00 to 100.00
Discount amount applied to this product
Total price after dicount and taxes Qty x unit price - discount
Deducts stamps from the member’s current stamp card, affecting only the collected stamps.
object
The number of stamps on this particular stamp cardId. It must be a positive value
The Id assigned by the retailer
object
The store’s transaction unique identifier. Eg. Order-1234
The date and time the transaction was created represented as ISO 8601-encoded string.
For example: January 1, 2025 at 13:00, in the time zone of UTC (Coordinated Universal Time) is represented as “2025-01-01T13:00:00Z” or “2025-01-01T13:00:00+00:00”. Important: If no offset is present, then UTC is assumed by default (not the store local time).
object
Electronic funds transfer at point of sale
Total amount paid by the customer, after discounts and taxes
Total amount of taxes paid
Discount amount applied to this purchase
Stores the specific value used for rounding calculations
Represents the origin of the request, by department, employee, system id and channel. Eg. Employee John Doe at Pos number 10 in the store department “New York” submitted this request.
object
The id for of the operator that made the request (if applicable)
Represents the business channel through which the API call occurred. It accepts ‘POS’ for Point-of-Sale systems and ‘OnlineStore’ for online stores. When the channel is empty or not recognized, it defaults to ‘POS’.
object
object
Store’s Product Id
Product Id that identifies the product along all channels (POS, Woocommerce, Shopify, etc.)
object
Defines the GTIN type for the global identifier code e.g. EAN, UPC, ISBN, etc.
object
Unit price including taxes
Value stored from 0.00 to 100.00
Discount amount applied to this product
Total price after dicount and taxes Qty x unit price - discount
Deducts stamps from the member’s current stamp card, affecting only the collected stamps.
object
The number of stamps on this particular stamp cardId. It must be a positive value
The Id assigned by the retailer
object
The store’s transaction unique identifier. Eg. Order-1234
The date and time the transaction was created represented as ISO 8601-encoded string.
For example: January 1, 2025 at 13:00, in the time zone of UTC (Coordinated Universal Time) is represented as “2025-01-01T13:00:00Z” or “2025-01-01T13:00:00+00:00”. Important: If no offset is present, then UTC is assumed by default (not the store local time).
object
Electronic funds transfer at point of sale
Total amount paid by the customer, after discounts and taxes
Total amount of taxes paid
Discount amount applied to this purchase
Stores the specific value used for rounding calculations
Represents the origin of the request, by department, employee, system id and channel. Eg. Employee John Doe at Pos number 10 in the store department “New York” submitted this request.
object
The id for of the operator that made the request (if applicable)
Represents the business channel through which the API call occurred. It accepts ‘POS’ for Point-of-Sale systems and ‘OnlineStore’ for online stores. When the channel is empty or not recognized, it defaults to ‘POS’.
object
object
Store’s Product Id
Product Id that identifies the product along all channels (POS, Woocommerce, Shopify, etc.)
object
Defines the GTIN type for the global identifier code e.g. EAN, UPC, ISBN, etc.
object
Unit price including taxes
Value stored from 0.00 to 100.00
Discount amount applied to this product
Total price after dicount and taxes Qty x unit price - discount
Deducts stamps from the member’s current stamp card, affecting only the collected stamps.
object
The number of stamps on this particular stamp cardId. It must be a positive value
The Id assigned by the retailer
Responses
Section titled “Responses”OK
object
Examplegenerated
{ "is_ok": true, "details": "example"}Bad Request
object
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example", "errors": { "additionalProperty": [ "example" ] }}