---
title: "Schemas"
description: "Schemas used in requests/responses of our API:"
canonical: "https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas"
---

# Schemas

> Schemas used in requests/responses of our API:

Source: https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas

Schemas used in requests/responses of our API:

## returnUrls

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| success | String(1...2000) | Return URL to use when the transaction succeeds. | | ✅ |
| cancelled | String(1...2000) | Return URL to use when the transaction is cancelled. | | ✅ |
| expired | String(1...2000) | Return URL to use when the transaction is expired. | | ✅ |
| failed | String(1...2000) | Return URL to use when the transaction is failed. | | ✅ |

## amountChangeable

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| min | Int | The minimum of the amount. | Must be higher than 0. | |
| max | Int | The maximum of the amount. | Must be higher than the minimum and lower than 5000000. | |

## action

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| qrcode | [qrcode](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#qrcode) Object | Next action to be performed by merchant (or consumer) to complete the payment. | | |

## qrcode

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| id | String | Identifier of the QR Code known by the iDEAL QR Backend of CM. | | |
| url | String | URL of the iDEAL QR code image to be shown to your customer. | | |

## payment

| Parameter | Type | Description | Constraints | Required |
| - | - | - | - | - |
| payment | String(36) | Payment unique identifier. | | ✅ |
| transaction | String(36) | Transaction unique identifier. | | ✅ |
| idealTransactionId | String(16) | The 16-digit transaction ID within the iDEAL scheme as known by the  issuing bank. The value can have leading zeros. | | ✅ |
| status | String | `OPEN` - Payment has been created. This is the initial status.  <br />`SUCCESS` - Payment successfully paid.  <br />`CANCELLED` - Payment has been cancelled by your customers.  <br />`EXPIRED` - Payment has not succeeded; expired.  <br />`FAILURE` - Payment has not succeeded; unknown reason. | | ✅ |
| createdAt | String(RFC3339) | Creation time. | ISO 8601 date and time. | ✅ |
| amount | Int(1...99999999) | Integer representing the amount of the payment. Denomination in the smallest currency subunit (e.g. eurocents). | | |
| consumerName | String | Name of the customer that completed the payment. | Only present in successful payments. | |
| consumerBic | String(8...11) | Bank Identification Code used by the customer to complete the payment. | Only present in successful payments. | |
| consumerIban | String | IBAN used by the customer to complete the payment. | Only present in successful payments. | |

## refund

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| refundedAmount | Int(0...99999999) | Amount in the smallest currency subunit, as for example eurocents, that has already been refunded. | | ✅ |
| refundedPendingAmount | Int(1...99999999) | Amount in the smallest currency subunit, as for example eurocents, that has been requested to be refunded. | | ✅ |

## summaryItem

| Parameter | Type | Description | Constraints | Required |
| - | - | - | - | - |
| status | String | `OPEN` - Payment has been created. This is the initial status.  <br />`SUCCESS` - Payment successfully paid.  <br />`CANCELLED` - Payment has been cancelled by your customers.  <br />`EXPIRED` - Payment has not succeeded; expired.  <br />`FAILURE` - Payment has not succeeded; unknown reason. | | |
| count | Int | The number of payments with the same status. | | |
| amount | Int(1...99999999) | Integer representing the amount of all the payments with the same status. Denomination in the smallest currency subunit (e.g. eurocents). | | |

## requestedQRCodeInBulk

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| amountChangeable | [amountChangeable](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#amountchangeable) Object | Contains the minimum and maximum values for the amount of a QR code that your customers can set themselves after scanning the code. | | |
| reference | String(1...255) | An identifier specified by you. If webhooks were specified in the request this identifier is added to the webhook request payload. | | **Only when not defined in `defaults`.** |
| amount | Int(1...99999999) | Integer representing the amount of the transaction. Denomination in the smallest currency subunit (e.g. eurocents). | | **Only when not defined in `defaults`.** |
| currency | String (ISO 4217) | ISO 4217 currency code. | | |
| purchaseId | String(1...35) | Identification of the order within your system. Ultimately appears on the payment confirmation (statement and confirmation screen). | | |
| description | String(1...255) | Description of the transaction. | | **Only when not defined in `defaults`.** |
| expiresAt | String(RFC3339) | Expiration time. | ISO 8601 date and time. | **Only when not defined in `defaults`.** |
| reusable | Boolean | Indicates the QR code's ability to accept multiple successful payments. | | |
| size | Int(100...2000) | Determines the size of the image in pixels. (e.g. A size of 200 will produce an image of \~200x200 pixels) | | **Only when not defined in `defaults`.** |
| language | String(ISO 639-1) | Preferred language of the user interface. | ISO 639-1 language. | **Only when not defined in `defaults`.** |
| webhooks | Array of objects | Webhooks enable receiving a web request once a given event occurs. | Find more details [here](https://docs.cm.com/payments/online-payments/guides/webhooks) . | |
| returnUrl | String(2000) | Specifies the URL where your customers will be redirected to when the payment process is completed. | Either `returnUrl` or `returnUrls` must be specified, but not both. | **Only when not defined in `defaults`.** |
| returnUrls | [returnUrls](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#returnurls)    Object | Specifies a URL where your customers will be redirected to per transaction status when the payment process is completed. For example, your customers will be redirected to `returnUrls.success` when the status of the transaction changes to `SUCCESS`. | Either `returnUrl` or `returnUrls` must be specified, but not both. | **Only when not defined in `defaults`.** |

## defaultsForBulkRequest

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| amountChangeable | [amountChangeable](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#amountchangeable)  Object | Contains the minimum and maximum values for the amount of a QR code that your customers can set themselves after scanning the code. | | |
| reference | String(1...255) | An identifier specified by you. If webhooks were specified in the request this identifier is added to the webhook request payload. | | ✅ |
| amount | Int(1...99999999) | Integer representing the amount of the transaction. Denomination in the smallest currency subunit (e.g. eurocents). | | ✅ |
| currency | String (ISO 4217) | ISO 4217 currency code. | | |
| purchaseId | String(1...35) | Identification of the order within your system. Ultimately appears on the payment confirmation (statement and confirmation screen). | | |
| description | String(1...255) | Description of the transaction. | | ✅ |
| expiresAt | String(RFC3339) | Expiration time. | ISO 8601 date and time. | ✅ |
| reusable | Boolean | Indicates the QR code's ability to accept multiple successful payments. | | |
| size | Int(100...2000) | Determines the size of the image in pixels. (e.g. A size of 200 will produce an image of \~200x200 pixels) | | ✅ |
| language | String(ISO 639-1) | Preferred language of the user interface. | ISO 639-1 language. | ✅ |
| webhooks | Array of objects | Webhooks enable receiving a web request once a given event occurs. | Find more details [here](https://docs.cm.com/payments/online-payments/guides/webhooks) . | |
| returnUrl | String(2000) | Specifies the URL where your customers will be redirected to. | **Either `returnUrl` or `returnUrls` must be specified, but not both.** | ✅ See Constraints |
| returnUrls | [returnUrls](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#returnurls)     Object | Specifies a URL where your customers will be redirected to per transaction status. For example, your customers will be redirected to `returnUrls.success` when the status of the transaction changes to `SUCCESS`. | **Either `returnUrl` or `returnUrls` must be specified, but not both.** | ✅ See Constraints |

## error

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| id | String(36) | Unique identifier of the error. | | ✅ |
| message | String | A message indicating details of the error. | | ✅ |

## QRCodesInBulk

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| created | Boolean | Indicates if a QR code transaction has been created or not. | | ✅ |
| transaction | [QRTransaction](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#qrtransaction)  Object | QR transaction details. | **Either `transaction` or `error` must be present, but not both.** | ✅ See Constraints |
| error | [error](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#error)  Object | Error details. | **Either `transaction` or `error` must be present, but not both.** | ✅ See Constraints |

## QRTransaction

| Parameter | Type | Description | Constraints | Required |
| :- | :- | :- | :- | :- |
| id | String(36) | Transaction unique identifier. It can be used to retrieve the iDEAL QR code transaction details by using it in combination with other endpoints provided in this api. | | ✅ |
| action | [action](https://docs.cm.com/payments/online-payments/guides/ideal-qr/schemas#action)  Object | The next action to be performed by you for this transaction. This includes the URL of the iDEAL QR code image to be shown to your customer. | | ✅ |
