For the complete documentation index, see llms.txt. This page is also available as Markdown.

1. Sale

You can use this service to send a sync sale request to your terminals.

POST {{Base Address}}/api/payment/sync/sale

It will be sufficient to send a request to the address provided above. You can use the 'Base Address' as desired for both the Test and Production environments.

Important: To use the Sync Sale service, you need to send the 'apikeyprivate' and 'apiclientprivate' parameters in the 'Header' section.

PhysicalAPI Address

The header information required to be sent to the service is as follows:

Parameter
Type
Compulsory
Description

apikeyprivate

string

Yes

The Private Key obtained from your merchant panel.

apiclientprivate

string

Yes

The Private Client obtained from your merchant panel.

The body information that needs to be sent to the service is as follows:

{
    "TerminalId": "8ff33705-57c7-42dc-8341-a0053e7f3009",
    "SendNotificationDeviceDisconnected": false,
    // "TerminalTagCode": "testpos",
    "MerchantUniqueCode": "{{$guid}}",
    "DisplayCode": "Kişisel Bakım",
    "Amount": 22,
    "CurrencyId": 1,
    "Methods": [
        {
            "PaymentMethodId": 1
        }
    ],
    "CallbackAddress": "https://webhook.site/4768e8e7-12c9-4c3f-949c-c7a616e72acf",
    "SplitPaymentSupport": false,
    "Customer": {
        "Type": 1,
        "FirstName": "eda",
        "MiddleName": "seda",
        "LastName": "meda",
        "CompanyName": "",
        "TaxOfficeCode": "",
        "TaxNumber": "",
        "Phone": "",
        "Email": "",
        "Identity": "11111111110",
        "Country": "Türkiye",
        "City": "İstanbul",
        "District": "Mesela",
        "Neighborhood": "Öyle",
        "Address": "Tam sokağın ortası"
    },
    "Products": [
        {
            "Name": "Saç Tıraşı",
            "TaxGroupId": 10,
            "UnitCodeId": 1,
            "Amount": 22,
            "Quantity": 1,
            "PaymentMethodId": 2
        }
    ],
    "SkipPrintCustomer": false,
    "SkipPrintMerchant": false,
    "SkipPaymentOptionScreen": false,
    "ReceiptOptions": { // Opsiyonal
        "TopSupport": true,
        "Top": {
            "Text": "Üst başlık",
            "FontSize": 10
        },
        "BottomSupport": true,
        "Bottom": {
            "Text": "Alt başlık",
            "FontSize": 50
        }
    }
}
Parameter
Type
Compulsory
Length
Description

string

Yes/No

Guid

Your terminal's identity (ID) information

bool

No

-

Should payments be sent as push notifications if the device is not connected to the Paywall servers (in locked mode)?

string

Yes

25

Tag code

Guid

Yes

-

The tracking number created by your side for the payment.

bool

No

-

Used to receive payments for each specific product.

decimal

Yes

-

Sale amount

string

No

25

The payment code that will be displayed on the terminal when the payment appears.

string

Yes

-

See: Currency

string

No

150

Your callback URL to which we send the payment status. See: Sample

Array<Method>

No

-

You can specify which payment methods should be supported using these parameters.

Customer

No

-

Customer information for the payment.

Array<Product>

Yes

-

Product information

bool

No

-

The customer receipt will not be printed.

bool

No

-

The merchant receipt will not be printed.

bool

No

-

The card payment detail screen (e.g., installments) will not be displayed during the payment.

ReceiptOptions

No

-

Custom settings for the receipt to be issued after the payment.

Method Object<Method>

Parameter
Type
Compulsory
Length
Description

int

Yes

-

Payment Methods

Method Object <ReceiptOptions>

Parameter
Type
Compulsory
Length
Description

bool

Yes

-

Will text be positioned at the top of the receipt?

string

Yes

150

Information to be written at the top of the receipt.

int

Yes

2

The size of the information to be written at the top of the receipt.

bool

Yes

-

Will text be positioned at the bottom of the receipt?

string

Yes

150

Information to be written at the bottom of the receipt.

int

Yes

2

The size of the information to be written at the bottom of the receipt.

Customer Object<Customer>

Parameter
Type
Compulsory
Length
Description

int

Yes

-

Customer Types

string

Yes/No

50

Customer first name

string

No

50

Customer middle name

string

Yes/No

50

Customer last name

string

Yes/No

175

Company name

string

Yes/No

50

Company tax office code

string

Yes/No

25

Company tax number

string

No

20

Phone

string

No

100

Email address

string

Yes/No

20

Identity number

string

No

50

Country

string

No

100

City

string

No

100

District/Neighborhood

string

No

100

Street

string

No

255

Street address

Product Object<Product>

Parameter
Type
Compulsory
Length
Description

string

Yes

75

Product Name

int

Yes

-

The VAT rate of the product

Bkz: Tax Group

int

Yes

-

Product unit information

Bkz: Unit Codes

string

Yes

-

Bkz: Currency

decimal

Yes

150

Product amount

Note: The total of the product amounts must equal the sales amount.

int

Yes

-

Product quantity

The response returned by the service:

Parameter
Type
Description

Result

object

The service returns the details in the response.

ErrorCode

int

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

Succeeded

bool

It returns a true or false value. If the transaction is successful, it returns a value of 'true'.

Failed

bool

It returns a true or false value. If the transaction is unsuccessful, it returns a value of 'true'.

Message

string

If the transaction is erroneous, it returns the error message specified, offering language support according to the locale parameter.

ClientMessage

string

It returns the fixed values of Paywall error codes. You can map them.

Parameter
Type
Description

Guid

The identity information of the Async payment in Paywall. It should be stored.

Guid

It is the identity information of the last transaction of the Async payment.

int

It is the transaction type of the last Async payment. Bkz: Payment Type

int

The last status of the asynchronous payment. Bkz: Payment Status

Last updated