Skip to content

Commit 9a09e9f

Browse files
committed
wip
1 parent 9e3700a commit 9a09e9f

File tree

1 file changed

+96
-1
lines changed

1 file changed

+96
-1
lines changed

openapi.json

Lines changed: 96 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,79 @@
158158
"transactionId": {
159159
"$ref": "#/components/schemas/TransactionId"
160160
},
161-
"total": {
161+
"approveTotal": {
162+
"type": "number",
163+
"example": 25.0
164+
}
165+
}
166+
}
167+
}
168+
}
169+
}
170+
}
171+
}
172+
},
173+
"/refund": {
174+
"post": {
175+
"tags": [
176+
"Transaction"
177+
],
178+
"summary": "Refund a transaction",
179+
"description": "Refund a transaction fully or partially.",
180+
"operationId": "refund",
181+
"parameters": [
182+
{
183+
"$ref": "#/components/parameters/Signature"
184+
}
185+
],
186+
"requestBody": {
187+
"description": "The refund object.",
188+
"required": true,
189+
"content": {
190+
"application/json": {
191+
"schema": {
192+
"$ref": "#/components/schemas/Refund"
193+
}
194+
}
195+
}
196+
},
197+
"responses": {
198+
"200": {
199+
"description": "Success response",
200+
"headers": {
201+
"Signature": {
202+
"$ref": "#/components/headers/Signature"
203+
}
204+
},
205+
"content": {
206+
"application/json": {
207+
"schema": {
208+
"properties": {
209+
"salt": {
210+
"type": "string",
211+
"example": "KAC6ZRUacmQit98nFKOpjXgkwdC0Grzl"
212+
},
213+
"merchant": {
214+
"type": "string",
215+
"example": "PUBLICTESTHUF"
216+
},
217+
"orderRef": {
218+
"$ref": "#/components/schemas/OrderRef"
219+
},
220+
"currency": {
221+
"$ref": "#/components/schemas/Currency"
222+
},
223+
"transactionId": {
224+
"$ref": "#/components/schemas/TransactionId"
225+
},
226+
"refundTransactionId": {
227+
"$ref": "#/components/schemas/TransactionId"
228+
},
229+
"refundTotal": {
230+
"type": "number",
231+
"example": 25.0
232+
},
233+
"remainingTotal": {
162234
"type": "number",
163235
"example": 25.0
164236
}
@@ -342,6 +414,29 @@
342414
}
343415
}
344416
},
417+
"Refund": {
418+
"type": "object",
419+
"required": [
420+
"refundTotal",
421+
"currency",
422+
"orderRef"
423+
],
424+
"properties": {
425+
"refundTotal": {
426+
"type": "number",
427+
"default": 0,
428+
"exclusiveMinimum": true,
429+
"minimum": 0,
430+
"example": 25.0
431+
},
432+
"currency": {
433+
"$ref": "#/components/schemas/Currency"
434+
},
435+
"orderRef": {
436+
"$ref": "#/components/schemas/OrderRef"
437+
}
438+
}
439+
},
345440
"OrderRef": {
346441
"type": "string",
347442
"example": "101010515680292482600"

0 commit comments

Comments
 (0)