POST api/Contact/{handle}/Credit?user={user}
Create a credit transaction
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| handle |
contact handle |
string |
Required |
| user |
Optional user handle - if empty logged in user will be used |
string |
None. |
Body Parameters
details of the transaction
NewCedit| Name | Description | Type | Additional information |
|---|---|---|---|
| Total |
Total credit - in Currency |
decimal number |
None. |
| Currency |
Currency |
string |
None. |
| UrlFailure |
A page to be redirected to in case of failure |
string |
None. |
| UrlSuccess |
A page to be redirected to in case of success |
string |
None. |
| UrlBack |
A page to be redirected to in case of cancel |
string |
None. |
| ClientIpAddress |
Ip Address of end client |
string |
None. |
Request Formats
application/json, text/json
{
"Total": 1.0,
"Currency": "sample string 2",
"UrlFailure": "sample string 3",
"UrlSuccess": "sample string 4",
"UrlBack": "sample string 5",
"ClientIpAddress": "sample string 6"
}
application/xml, text/xml
<NewCedit xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Contact"> <ClientIpAddress>sample string 6</ClientIpAddress> <Currency>sample string 2</Currency> <Total>1</Total> <UrlBack>sample string 5</UrlBack> <UrlFailure>sample string 3</UrlFailure> <UrlSuccess>sample string 4</UrlSuccess> </NewCedit>
application/x-www-form-urlencoded
Response Information
Resource Description
A payment object with elements required to launch axecpta payment
Collection of errors on failure
Return codes
200 - ok
400 - bad request
401 - unauthorized
404 - not found
500 - internal server error
| Name | Description | Type | Additional information |
|---|---|---|---|
| TransactionID |
Transaction id |
string |
None. |
| MerchantID |
Merchant id |
string |
None. |
| Data |
Encrypted data |
string |
None. |
| Len |
Data length |
integer |
None. |
Response Formats
application/json, text/json
{
"TransactionID": "sample string 1",
"MerchantID": "sample string 2",
"Data": "sample string 3",
"Len": 4
}
application/xml, text/xml
<Payment xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Contact"> <Data>sample string 3</Data> <Len>4</Len> <MerchantID>sample string 2</MerchantID> <TransactionID>sample string 1</TransactionID> </Payment>