Payment and Transaction Services

Complete Payment

post
/v2/terminal-host/payment

This service starts the payment transaction on the terminal. The payment is completed by presenting the card on the POS device. Example: "You complete the transaction started by the sales application and receive fields such as paymentId/authCode."

Authorization (Bearer Token):

  • The token value is the access_token returned by the OAuth token service.

  • Header format: Authorization: Bearer {access_token}

Authorizations
AuthorizationstringRequired

Authorization with Bearer Token. Header format: Authorization: Bearer {access_token}

The access_token is generated by the OAuth token service and is used in Terminal Host services.

Body
conversationIdstringRequired

ID value used to match the request and response. It is determined by the merchant, and the value sent in the request is returned in the response.

localestring · enumRequired

Response language.

Possible values:
deviceUniqueIdstringRequired

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdstringRequired

uniqueId value generated by the sales application for this sales transaction.

pricenumber · doubleRequired

Price Value

currencystringRequired

Currency

salesTypestring · enumRequired

Sales Type.

Possible values:
paymentIdstringOptional

Payment Number. This field is mandatory when performing a postAuth (provision closing) transaction.

installmentinteger · enumRequired

Installment Count

Possible values:
Responses
chevron-right
200

Success

application/json
conversationIdstringOptional

Unique value sent by the merchant for request-response matching and transaction tracking.

localestring · enumOptional

Response language

Possible values:
deviceUniqueIdstringOptional

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdstringOptional

Unique reference number generated by the sales application for the transaction.

statusstringOptional

Transaction result. (SUCCESS, FAILURE, etc.)

errorCodestringOptional

Error code returned if the transaction fails. It is empty for successful transactions.

errorMessagestringOptional

Descriptive error message returned in case of an error.

errorGroupstringOptional

Group/category information of the error.

systemTimeinteger · int64Optional

Unix timestamp value of when the transaction was processed in iyzico systems.

transactionDateTimestringOptional

Date and time when the transaction occurred on the terminal/host (ISO-8601).

authCodestringOptional

Approval (authorization) code generated by the bank/host.

paymentIdstringOptional

Transaction-based unique payment ID generated by iyzico.

paymentDatestringOptional

Date when the transaction is posted (YYYYMMDD).

pricenumber · doubleOptional

Transaction amount.

installmentinteger · int32Optional

Installment count. Returns 0 or 1 for single-payment transactions.

currencystringOptional

Transaction currency (e.g. TRY).

binNumberstringOptional

First 6 digits of the card (BIN).

lastFourDigitsstringOptional

Last 4 digits of the card number.

hostReferencestringOptional

Transaction reference number generated by the bank/host system.

cardTypestringOptional

Card type. (CREDIT_CARD, DEBIT_CARD, etc.)

acquirerIdstringOptional

Institution ID of the acquiring bank that processes the transaction.

issuerIdstringOptional

Institution ID of the issuing bank.

bankMerchantIdstringOptional

Merchant number assigned by the bank for the merchant.

bankTerminalIdstringOptional

Terminal number defined for the terminal at the bank.

batchNostringOptional

Batch (end-of-day) number that includes the transaction.

stanNostringOptional

System Trace Audit Number (STAN).

posEntryModeCodestringOptional

Code indicating how card information was entered into the POS (e.g. chip, magnetic stripe, contactless).

cancelHostReferencestringOptional

Void transaction reference number

refundHostReferencestringOptional

Refund transaction reference number

post
/v2/terminal-host/payment

Sample Collection

Query Transaction Status

post
/v2/terminal-host/payment/query-transaction-status

This service queries the status of a previously completed transaction. Example: You can retrieve the payment status and any error details using the paymentId.

Authorization (Bearer Token):

  • The token value is the access_token returned by the OAuth token service.

  • Header format: Authorization: Bearer {access_token}

Authorizations
AuthorizationstringRequired

Authorization with Bearer Token. Header format: Authorization: Bearer {access_token}

The access_token is generated by the OAuth token service and is used in Terminal Host services.

Body

Service that queries the status of a transaction.

conversationIdstringRequired

ID value used to match the request and response. It is determined by the merchant, and the value sent in the request is returned in the response.

localestring · enumRequired

Response language.

Possible values:
paymentIdstringRequired

Payment Number to be queried

deviceUniqueIdstringRequired

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdone of · nullableRequired

Unique reference number generated during the transaction for the payment/void/refund operation to be queried.

stringOptional
or
nullOptional
Responses
chevron-right
200

Success

application/json
conversationIdstringOptional

Unique value sent by the merchant for request-response matching and transaction tracking.

localestring · enumOptional

Response language

Possible values:
deviceUniqueIdstringOptional

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdstringOptional

Unique reference number generated by the sales application for the transaction.

statusstringOptional

Transaction result. (SUCCESS, FAILURE, etc.)

errorCodestringOptional

Error code returned if the transaction fails. It is empty for successful transactions.

errorMessagestringOptional

Descriptive error message returned in case of an error.

errorGroupstringOptional

Group/category information of the error.

systemTimeinteger · int64Optional

Unix timestamp value of when the transaction was processed in iyzico systems.

transactionDateTimestringOptional

Date and time when the transaction occurred on the terminal/host (ISO-8601).

authCodestringOptional

Approval (authorization) code generated by the bank/host.

paymentIdstringOptional

Transaction-based unique payment ID generated by iyzico.

paymentDatestringOptional

Date when the transaction is posted (YYYYMMDD).

pricenumber · doubleOptional

Transaction amount.

installmentinteger · int32Optional

Installment count. Returns 0 or 1 for single-payment transactions.

currencystringOptional

Transaction currency (e.g. TRY).

binNumberstringOptional

First 6 digits of the card (BIN).

lastFourDigitsstringOptional

Last 4 digits of the card number.

hostReferencestringOptional

Transaction reference number generated by the bank/host system.

cardTypestringOptional

Card type. (CREDIT_CARD, DEBIT_CARD, etc.)

acquirerIdstringOptional

Institution ID of the acquiring bank that processes the transaction.

issuerIdstringOptional

Institution ID of the issuing bank.

bankMerchantIdstringOptional

Merchant number assigned by the bank for the merchant.

bankTerminalIdstringOptional

Terminal number defined for the terminal at the bank.

batchNostringOptional

Batch (end-of-day) number that includes the transaction.

stanNostringOptional

System Trace Audit Number (STAN).

posEntryModeCodestringOptional

Code indicating how card information was entered into the POS (e.g. chip, magnetic stripe, contactless).

cancelHostReferencestringOptional

Void transaction reference number

refundHostReferencestringOptional

Refund transaction reference number

post
/v2/terminal-host/payment/query-transaction-status
circle-exclamation

Query Status – Important Note

Sample Collection

Void Payment

post
/v2/terminal-host/payment/void

This service cancels an eligible payment. Example: "The cancellation process is initiated with paymentId and paymentDate. The cancellation is completed by swiping the card on the POS device."

Authorization (Bearer Token):

  • The token value is the access_token returned by the OAuth token service.

  • Header format: Authorization: Bearer {access_token}

Authorizations
AuthorizationstringRequired

Authorization with Bearer Token. Header format: Authorization: Bearer {access_token}

The access_token is generated by the OAuth token service and is used in Terminal Host services.

Body

Payment Reversal Service.

conversationIdstringRequired

ID value used to match the request and response. It is determined by the merchant, and the value sent in the request is returned in the response.

localestring · enumRequired

Response language.

Possible values:
paymentIdstringRequired

Payment Number to be voided

paymentDatestringRequired

Date when the transaction is posted (YYYYMMDD).

deviceUniqueIdstringRequired

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdstringRequired

A unique reference number generated for the void transaction

reasonstringOptional

Void reason

descriptionstringOptional

Void description

Responses
chevron-right
200

Success

application/json
conversationIdstringOptional

Unique value sent by the merchant for request-response matching and transaction tracking.

localestring · enumOptional

Response language

Possible values:
deviceUniqueIdstringOptional

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdstringOptional

Unique reference number generated by the sales application for the transaction.

statusstringOptional

Transaction result. (SUCCESS, FAILURE, etc.)

errorCodestringOptional

Error code returned if the transaction fails. It is empty for successful transactions.

errorMessagestringOptional

Descriptive error message returned in case of an error.

errorGroupstringOptional

Group/category information of the error.

systemTimeinteger · int64Optional

Unix timestamp value of when the transaction was processed in iyzico systems.

transactionDateTimestringOptional

Date and time when the transaction occurred on the terminal/host (ISO-8601).

authCodestringOptional

Approval (authorization) code generated by the bank/host.

paymentIdstringOptional

Transaction-based unique payment ID generated by iyzico.

paymentDatestringOptional

Date when the transaction is posted (YYYYMMDD).

pricenumber · doubleOptional

Transaction amount.

installmentinteger · int32Optional

Installment count. Returns 0 or 1 for single-payment transactions.

currencystringOptional

Transaction currency (e.g. TRY).

binNumberstringOptional

First 6 digits of the card (BIN).

lastFourDigitsstringOptional

Last 4 digits of the card number.

hostReferencestringOptional

Transaction reference number generated by the bank/host system.

cardTypestringOptional

Card type. (CREDIT_CARD, DEBIT_CARD, etc.)

acquirerIdstringOptional

Institution ID of the acquiring bank that processes the transaction.

issuerIdstringOptional

Institution ID of the issuing bank.

bankMerchantIdstringOptional

Merchant number assigned by the bank for the merchant.

bankTerminalIdstringOptional

Terminal number defined for the terminal at the bank.

batchNostringOptional

Batch (end-of-day) number that includes the transaction.

stanNostringOptional

System Trace Audit Number (STAN).

posEntryModeCodestringOptional

Code indicating how card information was entered into the POS (e.g. chip, magnetic stripe, contactless).

cancelHostReferencestringOptional

Void transaction reference number

refundHostReferencestringOptional

Refund transaction reference number

post
/v2/terminal-host/payment/void

Sample Collection

Refund Payment

post
/v2/terminal-host/payment/refund

This service performs a refund operation on an eligible payment (partial/total). Example: "A refund process is initiated with paymentId and price. The cancellation process is completed by swiping the card on the POS device."

Authorization (Bearer Token):

  • The token value is the access_token returned by the OAuth token service.

  • Header format: Authorization: Bearer {access_token}

Authorizations
AuthorizationstringRequired

Authorization with Bearer Token. Header format: Authorization: Bearer {access_token}

The access_token is generated by the OAuth token service and is used in Terminal Host services.

Body
conversationIdstringRequired

ID value used to match the request and response. It is determined by the merchant, and the value sent in the request is returned in the response.

localestring · enumRequired

Request language.

Possible values:
paymentIdstringRequired

Payment number to be refunded

deviceUniqueIdstringRequired

Unique identifier defined for the terminal/device where the transaction is performed.

pricenumber · doubleRequired

Transaction amount.

transactionReferenceIdstringRequired

Unique reference number generated by the sales application for the refund transaction.

paymentDatestringRequired

Date when the transaction is posted (YYYYMMDD).

reasonstringOptional

Refund Reason

descriptionstringOptional

Refund Description

Responses
chevron-right
200

Success

application/json
conversationIdstringOptional

Unique value sent by the merchant for request-response matching and transaction tracking.

localestring · enumOptional

Response language

Possible values:
deviceUniqueIdstringOptional

Unique identifier defined for the terminal/device where the transaction is performed.

transactionReferenceIdstringOptional

Unique reference number generated by the sales application for the transaction.

statusstringOptional

Transaction result. (SUCCESS, FAILURE, etc.)

errorCodestringOptional

Error code returned if the transaction fails. It is empty for successful transactions.

errorMessagestringOptional

Descriptive error message returned in case of an error.

errorGroupstringOptional

Group/category information of the error.

systemTimeinteger · int64Optional

Unix timestamp value of when the transaction was processed in iyzico systems.

transactionDateTimestringOptional

Date and time when the transaction occurred on the terminal/host (ISO-8601).

authCodestringOptional

Approval (authorization) code generated by the bank/host.

paymentIdstringOptional

Transaction-based unique payment ID generated by iyzico.

paymentDatestringOptional

Date when the transaction is posted (YYYYMMDD).

pricenumber · doubleOptional

Transaction amount.

installmentinteger · int32Optional

Installment count. Returns 0 or 1 for single-payment transactions.

currencystringOptional

Transaction currency (e.g. TRY).

binNumberstringOptional

First 6 digits of the card (BIN).

lastFourDigitsstringOptional

Last 4 digits of the card number.

hostReferencestringOptional

Transaction reference number generated by the bank/host system.

cardTypestringOptional

Card type. (CREDIT_CARD, DEBIT_CARD, etc.)

acquirerIdstringOptional

Institution ID of the acquiring bank that processes the transaction.

issuerIdstringOptional

Institution ID of the issuing bank.

bankMerchantIdstringOptional

Merchant number assigned by the bank for the merchant.

bankTerminalIdstringOptional

Terminal number defined for the terminal at the bank.

batchNostringOptional

Batch (end-of-day) number that includes the transaction.

stanNostringOptional

System Trace Audit Number (STAN).

posEntryModeCodestringOptional

Code indicating how card information was entered into the POS (e.g. chip, magnetic stripe, contactless).

cancelHostReferencestringOptional

Void transaction reference number

refundHostReferencestringOptional

Refund transaction reference number

post
/v2/terminal-host/payment/refund

Sample Collection

Last updated