POST api/Merchant/v1/ReversePurchase
Method reverse the purchase payment.
Request Information
URI Parameters
None.
Body Parameters
ReversePurchaseRequest| Name | Description | Type | Additional information |
|---|---|---|---|
| purchaseId |
Id of purchase (M) |
globally unique identifier |
None. |
| amountToReverse |
If partial reverse, give reversed amount. If full reverse, give null. |
decimal number |
None. |
| description |
Desccription for reason. |
string |
None. |
| OrganizationCode | string |
None. |
|
| UserName | string |
None. |
|
| Password | string |
None. |
Request Formats
application/json, text/json
Sample:
{
"purchaseId": "1a6f8037-bd07-4007-8f04-1e5d4234146f",
"amountToReverse": 1.0,
"description": "sample string 2",
"OrganizationCode": "sample string 3",
"UserName": "sample string 4",
"Password": "sample string 5"
}
application/xml, text/xml
Sample:
<ReversePurchaseRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers.Merchant"> <OrganizationCode xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">sample string 3</OrganizationCode> <Password xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">sample string 5</Password> <UserName xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">sample string 4</UserName> <amountToReverse>1</amountToReverse> <description>sample string 2</description> <purchaseId>1a6f8037-bd07-4007-8f04-1e5d4234146f</purchaseId> </ReversePurchaseRequest>
application/x-www-form-urlencoded
Sample:
Response Information
Resource Description
ReversePurchaseReply| Name | Description | Type | Additional information |
|---|---|---|---|
| Reply | PurchaseReply |
None. |
|
| Ok | boolean |
None. |
|
| ErrorMessage | string |
None. |
|
| ErrorCode | string |
None. |
|
| Message | string |
None. |
Response Formats
application/json, text/json
Sample:
{
"Reply": {
"Id": "f1c931d4-031d-4f94-affc-e36a4ab01200",
"PurchaseProcessUrl": "sample string 2",
"Status": 0
},
"Ok": true,
"ErrorMessage": "sample string 2",
"ErrorCode": "sample string 3",
"Message": "sample string 4"
}
application/xml, text/xml
Sample:
<ReversePurchaseReply xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers.Merchant">
<ErrorCode xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">sample string 3</ErrorCode>
<ErrorMessage xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">sample string 2</ErrorMessage>
<Message xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">sample string 4</Message>
<Ok xmlns="http://schemas.datacontract.org/2004/07/FfApi.Controllers">true</Ok>
<Reply>
<Id>f1c931d4-031d-4f94-affc-e36a4ab01200</Id>
<PurchaseProcessUrl>sample string 2</PurchaseProcessUrl>
<Status>Ok</Status>
</Reply>
</ReversePurchaseReply>