P2P Card Credit
POSThttps://pay.fondy.eu/api/p2pcredit
This endpoint allows a merchant to perform a peer-to-peer (P2P) card credit transaction, transferring funds directly to a recipient's card number or a stored receiver token. The request must include either receiver_card_number
or receiver_rectoken
, along with transaction details such as order_id
, order_desc
, and amount
.
To secure this request, the merchant must generate a signature using their Credit private key specifically for p2pcredit
operations.
Request
Header Parameters
Content-Type stringrequired
Possible values: [application/json
, application/xml
, application/x-www-form-urlencoded
]
Specifies the format for the request. Response will be in the same format.
Default value:
application/json
- application/json
- application/xml
- application/x-www-form-urlencoded
Body
request object
Body
request object
Body
request object
Responses
- 200
The response for a successful transaction.
- application/json
- Schema
- Example (auto)
- final
- error
Schema
response object
{
"response": {
"order_id": "ORDER_12345678",
"merchant_id": 1,
"amount": 0,
"currency": "AED",
"order_status": "created",
"response_status": "string",
"signature": "string",
"tran_type": "purchase",
"sender_cell_phone": "string",
"sender_account": "string",
"masked_card": "string",
"card_bin": 0,
"card_type": "VISA",
"rrn": "string",
"approval_code": "string",
"response_code": 0,
"response_description": "string",
"reversal_amount": 0,
"settlement_amount": 0,
"settlement_currency": "AED",
"order_time": "2024-07-29T15:51:28.071Z",
"settlement_date": "2024-07-29",
"eci": 5,
"fee": 0,
"payment_system": "string",
"sender_email": "string",
"payment_id": 0,
"actual_amount": 0,
"actual_currency": "AED",
"product_id": "string",
"merchant_data": "string",
"verification_status": "verified",
"rectoken": "string",
"rectoken_lifetime": "2024-07-29T15:51:28.071Z",
"additional_info": {
"bank_name": "string",
"bank_country": "string",
"bank_response_code": "string",
"card_product": "string",
"card_category": "string",
"settlement_fee": 0,
"capture_status": "string",
"client_fee": 0,
"ipaddress_v4": "string",
"capture_amount": 0,
"card_type": "VISA",
"reservation_data": "string",
"bank_response_description": "string",
"transaction_id": 0,
"timeend": "2024-07-29T15:51:28.071Z",
"card_number": "string",
"payment_method": "apple"
}
}
}
Final Response
{
"response": {
"order_id": "ID1234",
"merchant_id": 1,
"amount": 1020,
"currency": "GBP",
"order_status": "approved",
"response_status": "success",
"signature": "1773cf135bd89656131134b98637894dad42f808",
"tran_type": "purchase",
"sender_cell_phone": "+1234567890",
"sender_account": "customer_account",
"masked_card": "444444XXXXXX5555",
"card_bin": 444444,
"card_type": "VISA",
"rrn": "123456789",
"approval_code": "654321",
"response_code": 100,
"response_description": "Transaction approved",
"reversal_amount": 0,
"settlement_amount": 1020,
"settlement_currency": "EUR",
"order_time": "21.12.2014 11:21:30",
"settlement_date": "21.12.2014",
"eci": 5,
"fee": 10,
"payment_system": "card",
"sender_email": "customer@example.com",
"payment_id": 123456789012345,
"actual_amount": 1020,
"actual_currency": "EUR",
"product_id": "hotel_booking_1234",
"merchant_data": "custom_data",
"verification_status": "verified",
"rectoken": "da39a3ee5e6b4b0d3255bfef95601890afd80709",
"rectoken_lifetime": "01.01.2018 00:00:00",
"additional_info": {
"bank_name": "Some bank in US country",
"bank_country": "US",
"bank_response_code": "decln_1000",
"card_product": "DEBIT",
"card_category": "CLASSIC",
"settlement_fee": 0.2,
"capture_status": "captured",
"client_fee": 0.3,
"ipaddress_v4": "8.8.8.8",
"capture_amount": 200,
"card_type": "VISA",
"reservation_data": null,
"bank_response_description": "General decline",
"transaction_id": 1058755083,
"timeend": "10.01.2018 11:21:30",
"card_number": "4444555566661111",
"payment_method": "apple"
}
}
}
Error Response
{
"response": {
"response_status": "failure",
"error_message": "General decline",
"error_code": "1000"
}
}
- csharp
- curl
- dart
- go
- http
- java
- javascript
- kotlin
- c
- nodejs
- objective-c
- ocaml
- php
- powershell
- python
- r
- ruby
- rust
- shell
- swift
- HTTPCLIENT
- RESTSHARP
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Post, "https://pay.fondy.eu/api/p2pcredit");
request.Headers.Add("Accept", "application/json");
var content = new StringContent("{\n \"request\": {\n \"merchant_id\": 1396424,\n \"order_id\": \"besh_p2p_1743690601\",\n \"amount\": 10000,\n \"currency\": \"USD\",\n \"order_desc\": \"Fondy P2P Card Credit Payment via Python API\",\n \"receiver_card_number\": 4444555566661111,\n \"signature\": \"19059322c0efdfd445d38c2ac19034cfd926151d\"\n }\n}", null, "application/json");
request.Content = content;
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
ResponseClear