2. Payment-Based
Confirm Payment Based on Payment
POST
{{Base Adres}}/api/paywall/marketplace/approve/pw/payment
apikeypublic
string
Yes
Public Key obtained from the merchant panel.
apiclientpublic
string
Yes
Public Client obtained from the merchant panel.
The parameters to be sent to the service are as follows:
PaymentId
int
Yes
The payment's ID information on the Paywall side should be used.
Payout
PayoutModel
No
Settings that can be configured at the time of earnings distribution related to the payment are included under this parameter. For example, a special note can be added to the payment receipt at the time of the money transfer.
You can review the following JSON to see the values it accepts.
SameReflectionDateWithMember
bool
No
If you want your marketplace settlements to occur on the same day as the reflection date of your merchant, you must send this parameter as true.
The value date is always based on the merchant’s value date. For example; if the merchant’s reflection date is 01.01 and yours is 05.01, with this parameter both the merchant’s and the platform’s reflection date will be 01.01.
This parameter is only valid for a single merchant. If there is more than one merchant included in the payment request, the parameter will be disabled.
The example JSON and sample codes to be sent to the service are as follows:
{
"PaymentId": 1644501,
"SameReflectionDateWithMember": false,
"Payout": {
"DescriptionApply": true,
"Description": "Ödemeye özel para transferi açıklaması"
}
}
Response returned from the service:
ErrorCode
int
Error code. Returns '0' if the operation is successful.
Result
bool
Returns a true or false value. Returns 'true' if the operation is successful.
Message
string
If the operation fails, this is the message describing the error, and it supports localization based on the locale parameter.
Body
object
Detailed information about the transaction
Example response for a successful operation
{
"ErrorCode": 0,
"Result": true,
"Message": "",
"Body": {
"Success": [
{
"ProductId": 1626132
},
{
"ProductId": 1626133
},
{
"ProductId": 1626134
},
{
"ProductId": 1626135
},
{
"ProductId": 1626136
}
],
"Fail": []
}
}
Example response for a failed operation
{
"ErrorCode": 1,
"Result": false,
"Message": "",
"Body": {
"Success": [],
"Fail": [
{
"ProductId": 1626132,
"Reason": "This product already approved"
},
{
"ProductId": 1626133,
"Reason": "This product already approved"
},
{
"ProductId": 1626134,
"Reason": "This product already approved"
},
{
"ProductId": 1626135,
"Reason": "This product already approved"
},
{
"ProductId": 1626136,
"Reason": "This product already approved"
}
]
}
}
Last updated