1. Product Based

Approve Product Based

PUT {{PaymentBaseAddress}}/api/paywall/marketplace/approve/product

Important: In order to use the payment service, you need to send the 'apikeypublic' and 'apiclientpublic' parameters in the 'Header' field. PaymentAPI Address

ParameterTypeMandatoryDescription

apikeypublic

string

Yes

The Public Key obtained from the merchant panel.

apiclientpublic

string

Yes

The Public Client obtained from the merchant panel.

The parameters that need to be sent to the service are as follows:

ParameterTypeMandatoryDescription

ProductIds

List<int>

Yes

During the payment process, the Id information related to the product(s) being sent should be used in the PayWall system. The relevant Id is returned within the response of the product.

If you are unable to store these Id details on your side, you can use the "Payment-Based" confirmation method.

Sample to be sent to the service JSON and sample codes is as follows.

{
    "ProductIds": [
        1626240,
        1626241,
        1626242,
        1626143,
        1626144,
        1626145,
        1626146
    ]
}

The response returned from the service:

ParameterTypeDescription

ErrorCode

int

Error code. If the transaction is successful, it returns a value of '0'.

Result

bool

It returns a value of 'true' for a successful transaction and 'false' otherwise.

Message

string

If the transaction is unsuccessful, this message is specific to the error and provides language support based on the 'locale' parameter.

Body

nesne

Transaction details

Sample response for success

{
    "ErrorCode": 0,
    "Result": true,
    "Message": "",
    "Body": {
        "Success": [
            {
                "ProductId": 1626240
            },
            {
                "ProductId": 1626241
            },
            {
                "ProductId": 1626242
            },
            {
                "ProductId": 1626243
            },
            {
                "ProductId": 1626244
            },
            {
                "ProductId": 1626245
            },
            {
                "ProductId": 1626246
            }
        ],
        "Fail": []
    }
}

Sample response for failure

{
    "ErrorCode": 1,
    "Result": false,
    "Message": "",
    "Body": {
        "Success": [],
        "Fail": [
            {
                "ProductId": 1626240,
                "Reason": "This product marketplace earning calculated not found"
            },
            {
                "ProductId": 1626241,
                "Reason": "This product marketplace earning calculated not found"
            },
            {
                "ProductId": 1626242,
                "Reason": "This product marketplace earning calculated not found"
            },
            {
                "ProductId": 1626243,
                "Reason": "This product marketplace earning calculated not found"
            },
            {
                "ProductId": 1626244,
                "Reason": "This product marketplace earning calculated not found"
            },
            {
                "ProductId": 1626245,
                "Reason": "This product marketplace earning calculated not found"
            },
            {
                "ProductId": 1626246,
                "Reason": "This product marketplace earning calculated not found"
            }
        ]
    }
}

Last updated