Download OpenAPI specification:
APIs for operating Pos terminals according to the MIA standard. This version adds support for working with Hybrid and Static QR codes. A separate API for working with dynamic QR codes is considered deprecated, but is still supported.
POS Activation
POST /pos/api/v1/terminal-activation/init to initialize terminal activation. The response will include the operation result and an activation identifier.POST /pos/api/v1/terminal-activation/confirm to confirm the POS terminal.Operator Authorization and Access Token Retrieval
POST /pos/api/v1/seller/login to authorize the operator and retrieve access tokens.POST /pos/api/v1/seller/refresh to obtain a new pair of tokens based on the refresh token.Operator Shift Management
GET /pos/api/v1/shift/check to check the status of the current shift.POST /pos/api/v1/shift/open to open a new shift.Query version for working with Dynamic, Hybrid, Static QR codes
GET /pos/api/v2/qr/active. There are no restrictions on the number of active dynamic QR codes. POST /pos/api/v2/qr to create a QR code of the desired type in the specified type of amount.Extension model transmits information about the amount of payment charged. When generating a hybrid QR code or a static QR with a free amount, the extension object is not transmitted.
/pos/api/v2/qr/{qrId}/extension to create a new payment request using a static or hybrid QR code. This request does not apply to dynamic QR.GET /pos/api/v2/qr/extension/{extensionId}/check to check the status of a payment request using a QR code. DELETE /pos/api/v2/qr/extension/{extensionId} to cancel all active hybrid QR code extensions. This request is prohibited for other types of QR codes.DELETE /pos/api/v2/qr/{qrId} to cancel the QR code.Close Shift
POST /pos/api/v1/shift/close to close the current shift.Retrieve Z-Report
GET /pos/api/v2/shift/{shiftId}/z-report to retrieve the Z-report for a specific shift.Operator Logout
POST /pos/api/v1/seller/logout to log the operator out of the system.Initializing an operation to bind an operation to a device
| X-DEVICE required | string Device model, e.g: iPhone 14. Browser name - for web |
| X-PLATFORM-TYPE required | string Enum: "ios" "android" "web" "external_system" Indicates the device platform |
| X-PLATFORM-VERSION | string Platform version: 4.4; 10.1. |
| X-INSTALLATION-ID required | string <uuid> Application unique identifier: 628f8a47-50a4-47e4-be12-af6c4dac9573. Generated with every installation |
| X-NATIVE-APP-VERSION | integer Pos terminal container version |
| X-POS-APP-VERSION required | integer Pos terminal application version |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
Request to initiate the operation of binding a terminal to a device
| terminalId required | string Terminal identifier by which the binding to the device is initialized |
| merchantIdno required | string Merchant IDNO who owns the terminal |
{- "terminalId": "string",
- "merchantIdno": "string"
}{- "result": "success",
- "terminalActivationId": "e559d17a-a29b-49c0-878b-af3de2495d39",
- "maskedPhoneNumber": "string",
- "waitTimeToResend": 0
}Resends the OTP code as part of an attempt to bind the terminal to the device
| X-CORRELATION-ID | string <uuid> Unique request identifier |
OTP resend request body
| terminalActivationId required | string <uuid> Unique terminal activation identifier (binding the terminal to the device) |
{- "terminalActivationId": "e559d17a-a29b-49c0-878b-af3de2495d39"
}{- "result": "success",
- "leftAttempts": 0,
- "waitTimeToResend": 0
}Confirmation of terminal binding by entering the OTP code
| X-CORRELATION-ID | string <uuid> Unique request identifier |
OTP confirmation model for terminal-to-device binding operation
| terminalActivationId required | string <uuid> Unique terminal activation identifier (binding the terminal to the device) |
| otpCode required | string <int32> OTP code to confirm the operation |
{- "terminalActivationId": "e559d17a-a29b-49c0-878b-af3de2495d39",
- "otpCode": "string"
}{- "result": "success",
- "leftAttempts": 0
}Gets details about a terminal and its associated merchant using the terminal activation ID.
| posActivationId required | string <uuid> Unique pos terminal activation identifier |
{- "result": "success",
- "terminalId": 0,
- "merchantIdno": "string",
- "merchantName": "string",
- "storeAddress": "string"
}Performing seller authorization to gain access to the activated terminal
| X-CORRELATION-ID | string <uuid> Unique request identifier |
Seller authorization data
| terminalActivationId required | string <uuid> Unique identifier of the activated terminal |
| username required | string Seller username to log in |
| password required | string Seller password |
{- "terminalActivationId": "e559d17a-a29b-49c0-878b-af3de2495d39",
- "username": "string",
- "password": "string"
}{- "result": "success",
- "authTokens": {
- "accessToken": "string",
- "refreshToken": "string",
- "accessTokenExpiresIn": 0
}
}Request to exit the operator account
| X-CORRELATION-ID | string <uuid> Unique request identifier |
Operator logout data
| refreshToken required | string |
{- "refreshToken": "string"
}Updating a pair of tokens based on a refresh token
| X-CORRELATION-ID | string <uuid> Unique request identifier |
Data for refreshing access tokens
| refreshToken required | string |
| terminalActivationId required | string <uuid> Unique identifier of the activated terminal |
{- "refreshToken": "string",
- "terminalActivationId": "e559d17a-a29b-49c0-878b-af3de2495d39"
}{- "result": "success",
- "authTokens": {
- "accessToken": "string",
- "refreshToken": "string",
- "accessTokenExpiresIn": 0
}
}Generates a z-report for a closed shift
| shiftId required | string Unique identifier of the closed shift for which you need to obtain a z-report |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "result": "success",
- "report": "string"
}Generates a Z-report for a closed shift. A Z-report contains a summary of transactions within a shift. It supports multiple output formats (e.g., PDF, JSON, PNG, TXT) and allows generating either a full report (with all transactions) or a short summary.
| shiftId required | string Unique identifier of the closed shift for which you need to obtain a z-report |
| format | string (ReportFormat) Enum: "pdf" "png" "txt" "json" Format of the report. Supported formats: PDF, JSON, PNG, TXT. (default is PDF) |
| isFullReport | boolean Flag to include a full list of transactions in the Z-report (default is false). |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "reportJson": {
- "reportDateTime": "2024-04-04T10:49:54",
- "terminalType": "MiaPos",
- "terminalId": "T123",
- "merchantId": 1824,
- "merchantIdno": "1234567890",
- "workShiftEndDateTime": "2024-04-04T10:49:54",
- "merchant": "Test Merchant",
- "store": "Test Store",
- "operator": "Test User",
- "transactions": {
- "data": [
- {
- "transactionType": "payment",
- "transactionId": 1,
- "transactionDateTime": "2024-04-04T10:49:54",
- "transactionAmount": 234.5,
- "transactionCcy": "MDL"
}
], - "recordCount": 90
}, - "paymentCount": 264,
- "paymentSum": 70508.85,
- "cancellationCount": 6,
- "cancellationSum": 144,
- "totalSum": 70364.85
}, - "result": "success",
- "reportBinary": "string",
- "reportText": [
- "string"
]
}Generates a X-report for a opened shift. A X-report contains a summary of transactions within a shift. It supports multiple output formats (e.g., PDF, JSON, PNG, TXT) and allows generating either a full report (with all transactions) or a short summary.
| shiftId required | string Unique identifier of the opened shift for which you need to obtain a X-report |
| format | string (ReportFormat) Enum: "pdf" "png" "txt" "json" Format of the report. Supported formats: PDF, JSON, PNG, TXT. |
| isFullReport | boolean Flag to include a full list of transactions in the X-report (default is false). |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "reportJson": {
- "reportDateTime": "2024-04-04T10:49:54",
- "terminalType": "MiaPos",
- "terminalId": "T123",
- "merchantId": 1824,
- "merchantIdno": "1234567890",
- "workShiftEndDateTime": "2024-04-04T10:49:54",
- "merchant": "Test Merchant",
- "store": "Test Store",
- "operator": "Test User",
- "transactions": {
- "data": [
- {
- "transactionType": "payment",
- "transactionId": 1,
- "transactionDateTime": "2024-04-04T10:49:54",
- "transactionAmount": 234.5,
- "transactionCcy": "MDL"
}
], - "recordCount": 90
}, - "paymentCount": 264,
- "paymentSum": 70508.85,
- "cancellationCount": 6,
- "cancellationSum": 144,
- "totalSum": 70364.85
}, - "result": "success",
- "reportBinary": "string",
- "reportText": [
- "string"
]
}Generates a receipt for a specific transaction. A receipt contains the essential details of a transaction, such as the transaction amount, payment method, and date. The endpoint supports multiple output formats (e.g., PDF, JSON, PNG, TXT) to accommodate various use cases, such as printing a receipt or integrating it into external systems.
| txId required | string Unique identifier of the transaction for which details need to be obtained |
| format | string (ReportFormat) Enum: "pdf" "png" "txt" "json" Format of the report. Supported formats: PDF, JSON, PNG, TXT. |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "reportJson": {
- "merchant": "Test Merchant Test",
- "store": "Test Store",
- "storeAddress": "str. Mihai Viteazu 15",
- "terminalId": "T123",
- "transactionDateTime": "2024-04-04T10:49:54",
- "transactionId": "00000001",
- "swiftMessageId": "VICBMD2XAXXX250201393",
- "swiftPayerBank": "VICBMD2X",
- "amount": 1,
- "ccy": "MDL"
}, - "result": "success",
- "reportBinary": "string",
- "reportText": [
- "string"
]
}Returns a portion of transactions completed within the shift. From the most current to the oldest
| shiftId required | string Unique shift identifier for which transaction requests are made |
| txId | integer <int64> ID of the transaction from which earlier transactions are requested. If not transmitted, the most current data is returned |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "result": "success",
- "isEnded": true,
- "txList": [
- {
- "id": 0,
- "amount": 0.1,
- "ccy": "string",
- "date": "2024-04-04T10:49:54",
- "type": "paid"
}
]
}Returns information about transaction details based on the passed identifier
| txId required | string Unique identifier of the transaction for which details need to be obtained |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "result": "success",
- "txInfo": {
- "id": 0,
- "amount": 0.1,
- "ccy": "string",
- "date": "2024-04-04T10:49:54",
- "type": "paid",
- "rrn": "string",
- "approvalCode": "string",
- "mсс": "string",
- "swiftMessageType": "string",
- "swiftMessageId": "string",
- "swiftPayerBank": "string"
}
}Initiates a return transaction for a completed transaction.
Request body for initiating a transaction return.
| txId required | integer <int64> Unique identifier of the transaction to be returned. |
| amount | number <double> Amount to be refunded; applicable only if not a full refund. |
| fullRefund required | boolean Indicates whether the return is a full refund (true) or a partial refund (false). |
| ccy | string Currency code for the transaction (e.g., MDL, EUR). |
| reasonCode required | string Code representing the reason for the return. |
| reasonMessage | string Detailed message explaining the reason for the return. |
{- "txId": 0,
- "amount": 0.1,
- "fullRefund": true,
- "ccy": "string",
- "reasonCode": "string",
- "reasonMessage": "string"
}{- "result": "success",
- "requestId": 0
}Generates a dynamic qr for payment for the specified amount (deprecated). Used to create a dynamic QR with a fixed amount type. To create a new QR by type, see the request: /pos/api/v2/qr
Payment information for which you need to generate a QR
| amount required | number <double> Amount to be paid |
{- "amount": 0.1
}{- "result": "success",
- "qrId": "46027dd2-ff11-4c24-8cf5-d54b1f7fd64c",
- "qrExpireIn": 0,
- "qrImage": "string"
}Checks the status using the generated QR code (deprecated). Checks status only using dynamic QR codes. See the request: /pos/api/v2/qr/extension/{extensionId}/check
| qrId required | string Unique QR code identifier |
{- "state": "not_found",
- "errorDescription": "string",
- "txInfo": {
- "id": 0,
- "amount": 0.1,
- "ccy": "string",
- "date": "2024-04-04T10:49:54",
- "type": "paid",
- "rrn": "string",
- "approvalCode": "string",
- "mсс": "string",
- "swiftMessageType": "string",
- "swiftMessageId": "string",
- "swiftPayerBank": "string"
}
}Cancels the generated QR code for payment (deprecated). Old version of QR code cancellation, which works only on the dynamic type. To use the new cancellation functionality, you need to go to the request: DELETE /pos/api/v2/qr/{qrId}
| qrId required | string Unique QR code identifier |
{- "result": "success"
}Receives a list of active QR codes according to the specified type generated from this terminal. Currently, the terminal works with one active QR. If qrType is not transmitted, active QRs are returned without binding to type
| type | string Enum: "dynamic" "static" "hybrid" Type of the QR code |
| isImageRequired | boolean Default: false Indicates whether an image should be included in the QR information |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "result": "success",
- "codes": [
- {
- "qrId": "46027dd2-ff11-4c24-8cf5-d54b1f7fd64c",
- "qrType": "dynamic",
- "amountType": "fixed",
- "qrText": "string",
- "qrImage": "string",
- "extension": {
- "extensionId": "e6532990-9411-4b54-9b41-41ee86c8daab",
- "qrExpireIn": 0,
- "amount": 0.1,
- "minAmount": 0.1,
- "maxAmount": 0.1
}
}
]
}Creates a new QR code with the ability to specify parameters for working with payments
| X-CORRELATION-ID | string <uuid> Unique request identifier |
Information about the QR code configuration for the ability to submit a payment request
| qrType required | string (QrType) Enum: "dynamic" "static" "hybrid" Indicates the types of QR codes the terminal works with. |
| amountType required | string (QrAmountType) Enum: "fixed" "free" "controlled" Indicates the type of amount that can be configured to receive payments |
object Not transmitted for free amount type and hybrid QR code |
{- "qrType": "dynamic",
- "amountType": "fixed",
- "extension": {
- "amount": 0.1,
- "minAmount": 0.1,
- "maxAmount": 0.1
}
}{- "result": "success",
- "qrInfo": {
- "qrId": "46027dd2-ff11-4c24-8cf5-d54b1f7fd64c",
- "qrType": "dynamic",
- "amountType": "fixed",
- "qrText": "string",
- "qrImage": "string",
- "extension": {
- "extensionId": "e6532990-9411-4b54-9b41-41ee86c8daab",
- "qrExpireIn": 0,
- "amount": 0.1,
- "minAmount": 0.1,
- "maxAmount": 0.1
}
}
}Creates a new payment request using the specified QR code. Only available for hybrid and static qr
| qrId required | string Unique QR code identifier |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
Information about the new extension that needs to be created and linked to the QR code
| amount | number <double> Information about the fixed amount that the client must pay. Indicated if the QR was created with a fixed amount type |
| minAmount | number <double> Indicates the minimum amount that the client can pay. Indicated for QR with a controlled amount type |
| maxAmount | number <double> Indicates the maximum amount that the client can pay. Indicated for QR with a controlled amount type |
{- "amount": 0.1,
- "minAmount": 0.1,
- "maxAmount": 0.1
}{- "result": "success",
- "extensionIfo": {
- "extensionId": "e6532990-9411-4b54-9b41-41ee86c8daab",
- "qrExpireIn": 0,
- "amount": 0.1,
- "minAmount": 0.1,
- "maxAmount": 0.1
}
}Checks the status of the submitted payment request using the QR code
| extensionId required | string Unique identifier of the QR code extension |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "state": "not_found",
- "errorDescription": "string",
- "lastTxInfo": {
- "id": 0,
- "amount": 0.1,
- "ccy": "string",
- "date": "2024-04-04T10:49:54",
- "type": "paid",
- "rrn": "string",
- "approvalCode": "string",
- "mсс": "string",
- "swiftMessageType": "string",
- "swiftMessageId": "string",
- "swiftPayerBank": "string"
}, - "totalPayments": 0
}Cancels active QR code extension. Only available for QR hybrid type
| extensionId required | string Unique identifier of the QR code extension |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "result": "success"
}Receives information about the QR code based on the transmitted id. It also returns data about the state of the QR code. Extension info will only be present in the response if it is in the active state.
| qrId required | string Unique QR code identifier |
| isImageRequired | boolean Default: false Indicates whether an image should be included in the QR information |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "state": "not_found",
- "qrInfo": {
- "qrId": "46027dd2-ff11-4c24-8cf5-d54b1f7fd64c",
- "qrType": "dynamic",
- "amountType": "fixed",
- "qrText": "string",
- "qrImage": "string",
- "extension": {
- "extensionId": "e6532990-9411-4b54-9b41-41ee86c8daab",
- "qrExpireIn": 0,
- "amount": 0.1,
- "minAmount": 0.1,
- "maxAmount": 0.1
}
}
}Cancels the QR code along with the active extension for receiving payments
| qrId required | string Unique QR code identifier |
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "result": "success"
}Obtaining information about the seller session
| X-CORRELATION-ID | string <uuid> Unique request identifier |
{- "sellerInfo": {
- "id": 0,
- "fullName": "string"
}, - "terminalInfo": {
- "terminalId": "string",
- "posId": 0
}, - "merchantInfo": {
- "merchantName": "string",
- "merchantIdno": "string"
}, - "placeInfo": {
- "name": "string",
- "address": "string"
}, - "bankInfo": {
- "bankName": "string",
- "image": "string",
- "userGuideUrl": "string",
- "supportPhone": "string",
- "supportEmail": "string"
}
}Retrieve current settings of a POS terminal
{- "result": "success",
- "qrSettings": {
- "qrType": "dynamic",
- "qrAmountType": "fixed",
- "qrTtl": 300,
- "prohibitSettingsChange": false,
- "whenUpdated": "2024-04-04T10:49:54"
}
}Set new QR code settings for a POS terminal.
| qrType required | string (QrType) Enum: "dynamic" "static" "hybrid" Indicates the types of QR codes the terminal works with. |
| qrAmountType required | string (QrAmountType) Enum: "fixed" "free" "controlled" Indicates the type of amount that can be configured to receive payments |
| qrTtl | integer >= 30 Default: 300 Time-to-live for QR codes in seconds |
| prohibitSettingsChange | boolean Default: false Flag to prohibit changes to settings in the MiaPos application |
| whenUpdated | string or null <date-time> Indicates the last update timestamp for POS settings |
{- "qrType": "dynamic",
- "qrAmountType": "fixed",
- "qrTtl": 300,
- "prohibitSettingsChange": false,
- "whenUpdated": "2024-04-04T10:49:54"
}{- "result": "success"
}