# Create Transaction

> 📘 iDEAL becomes Wero
>
> You’ll soon see a new logo: iDEAL | Wero.
>
> iDEAL is evolving into "Wero", a new pan-European payment solution by the European Payments Initiative (EPI). The first step is the introduction of the mandatory iDEAL-Wero co-branding on all existing iDEAL checkout pages.
>
> CM.com is handling all the technical updates required for iDEAL's transition to Wero, ensuring a seamless process for merchants. There will be no changes to the implementation of the current iDEAL payment method, so merchants can continue using it as usual without any disruptions.
>
> To comply with the new guidelines, you have between January 29, 2026 and March 31, 2026 to complete the following:
>
> * Change the payment method name from iDEAL to iDEAL | Wero
> * Update the iDEAL logo to the iDEAL Wero co-branded logo. For instructions and the graphic files: <https://ideal.nl/ideal-wero-branding>

You can use this call to create a new iDEAL transaction.

## Prerequisite

Get an `access_token` and use it as 'Bearer' token in your request. Find more details [here](authorization-3).

## Request

```text
POST https://api.pay.cm.com/api/v1/paymentmethods/ideal/v1/transactions
```

### Request body examples

These are only some examples of the request body to create a transaction:

```json Full Request with ReturnURLs
{
  "reference": "20210623130413",
  "amount": 1200,
  "currency": "EUR",
  "purchaseId": "order123",
  "description": "Order at yourdomain.tld",
  "expiresAt": "2006-01-02T15:04:05Z",
  "language": "nl",
  "webhooks": [
    {
      "url": "https://yourdomain.tld/order-webhooks?purchaseId=order123",
      "events": [
        "FINALSTATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "REFUND_STATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "STATUS_CHANGE"
      ]
    }
  ],
  "returnUrls": {
    "success": "https://yourdomain.tld/order/payment-success.html",
    "cancelled": "https://yourdomain.tld/order/payment-cancelled.html",
    "expired": "https://yourdomain.tld/order/payment-expired.html",
    "failed": "https://yourdomain.tld/order/payment-failed.html"
  }
}
```
```json Full Request with ReturnURL
{
  "reference": "20210623130413",
  "amount": 1200,
  "currency": "EUR",
  "purchaseId": "order123",
  "description": "Order at yourdomain.tld",
  "expiresAt": "2006-01-02T15:04:05Z",
  "language": "nl",
  "webhooks": [
    {
      "url": "https://yourdomain.tld/order-webhooks?purchaseId=order123",
      "events": [
        "FINALSTATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "REFUND_STATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "STATUS_CHANGE"
      ]
    }
  ],
  "returnUrl": "https://yourdomain.tld/order/payment-completed.html"
}
```
```json Minimal Request with ReturnURL
{
  "reference": "20210623130413",
  "amount": 1200,
  "purchaseId": "order123",
  "description": "Order at yourdomain.tld",
  "returnUrl": "https://yourdomain.tld/order/payment-completed.html"
}
```
```json Fast Checkout (Snel Bestellen)
{
  "reference": "20210623130413",
  "amount": 1200,
  "currency": "EUR",
  "purchaseId": "order123",
  "description": "Order at yourdomain.tld",
  "expiresAt": "2006-01-02T15:04:05Z",
  "language": "nl",
  "checkout": {
    "shippingCost": 100,
    "requestedDetails": {
      "debtorContactDetails": {
        "firstName": true,
        "lastName": false,
        "phoneNumber": false,
        "email": false
      },
      "shippingAddress": false,
      "invoiceAddress": false
    }
  },
  "webhooks": [
    {
      "url": "https://yourdomain.tld/order-webhooks?purchaseId=order123",
      "events": [
        "FINALSTATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "REFUND_STATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "STATUS_CHANGE"
      ]
    }
  ],
  "returnUrls": {
    "success": "https://yourdomain.tld/order/payment-success.html",
    "cancelled": "https://yourdomain.tld/order/payment-cancelled.html",
    "expired": "https://yourdomain.tld/order/payment-expired.html",
    "failed": "https://yourdomain.tld/order/payment-failed.html"
  }
}
```

"**Full Request with ReturnURLs**" and "**Full Request with ReturnURL**" are examples where all the request parameters are provided. If `returnUrls` is defined then customers will be redirected to a different URL depending on the status of the transaction when the payment process is completed. If `returnUrl` is defined then  customers will be redirected to the same URL no matter the status of the transaction when the payment process is completed.

"**Minimal Request with ReturnURLs**" is an example of the minimal request to create a transaction. This example, is using `returnUrls`, but you can replace it for `returnUrl` depending on what is better for your use case.

## Parameters

[block:parameters]
{
  "data": {
    "h-0": "Parameter",
    "h-1": "Type",
    "h-2": "Description",
    "h-3": "Constraints",
    "0-0": "reference",
    "0-1": "String(1...255)",
    "0-2": "An identifier specified by you. If webhooks were specified in the request this identifier is added to the webhook request payload.",
    "0-3": "",
    "1-0": "amount",
    "1-1": "Int(1...99999999)",
    "1-2": "Integer representing the amount of the transaction. Denomination in the smallest currency subunit (e.g. eurocents).",
    "1-3": "For test, the maximum amount is €999,99  \n  \nCertain payment methods require a minimum amount of 2 cents because of legacy. These include [creditcard, ideal*, bancontact, apple-pay, google-pay, paypal, klarna].\\*ideal -> depending our the configuration of your account 1 cent transactions are possible.",
    "2-0": "purchaseId",
    "2-1": "String(1...35)",
    "2-2": "Identification of the order within your system. Ultimately appears on the payment confirmation (statement and confirmation screen).",
    "2-3": "",
    "3-0": "description",
    "3-1": "String(1...255)",
    "3-2": "Description of the transaction.",
    "3-3": "",
    "4-0": "returnUrl",
    "4-1": "String(2000)",
    "4-2": "Specifies the URL where your customers will be redirected to when the payment process is completed.",
    "4-3": "Either `returnUrl` or `returnUrls` must be specified, but not both.",
    "5-0": "returnUrls",
    "5-1": "[returnUrls](schemas-1#returnurls)  Object",
    "5-2": "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`.",
    "5-3": "Either `returnUrl` or `returnUrls` must be specified, but not both."
  },
  "cols": 4,
  "rows": 6,
  "align": [
    "left",
    "left",
    "left",
    "left"
  ]
}
[/block]

## Optional parameters

| Parameter | Type              | Description                                                        | Constraints                                                                                                |
| :-------- | :---------------- | :----------------------------------------------------------------- | :--------------------------------------------------------------------------------------------------------- |
| expiresAt | String(RFC3339)   | Expiration time.                                                   | ISO 8601 date and time. If left empty, a default value will be set. Find more details [here](expiration) . |
| language  | String(ISO 639-1) | Preferred language of the user interface.                          | ISO 639-1 language.                                                                                        |
| currency  | String (ISO 4217) | Currency code.                                                     | ISO 4217 currency code.                                                                                    |
| webhooks  | Array of objects  | Webhooks enable receiving a web request once a given event occurs. | Find more details [here](webhooks-1).                                                                      |
| checkout  | Object            | Contains optional values used by Fast Checkout.                    | Find more details [here](fast-checkout-snel-bestellen)                                                     |

## Response

```json
{
  "id": "8db1e7fa-ba8a-4189-92fd-67a20217443d",
  "orderId": "8db1e7fa-ba8a-4189-92fd-67a20217443d",
  "reference": "20210623130413",
  "issuer": "RABONL2U",
  "amount": 1200,
  "currency": "EUR",
  "purchaseId": "order123",
  "description": "Order at yourdomain.tld",
  "expiresAt": "2006-01-02T15:04:05Z",
  "language": "nl",
  "webhooks": [
    {
      "url": "https://yourdomain.tld/order-webhooks?purchaseId=order123",
      "events": [
        "FINALSTATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "REFUND_STATUS"
      ]
    },
    {
      "url": "https://yourdomain.tld/payment-webhooks?purchaseId=order123",
      "events": [
        "STATUS_CHANGE"
      ]
    }
  ],
  "status": "OPEN",
  "action": {
    "redirect": {
      "url": "https://issuer.tld/ideal/start?trxid=213981209381209390821&random=wreq0dq90vgq0ew923123"
    }
  },
  "createdAt": "2006-01-02T15:04:05Z",
  "consumer": {
    "name": "John",
    "bic": "RABONL2U",
    "iban": "NL24RABO8487376045"
  },
  "refunds": {
    "refundedAmount": 300,
    "refundedPendingAmount": 100
  },
  "idealTransactionId": "1234567890123456",
  "returnUrls": {
    "success": "https://yourdomain.tld/order/payment-success.html",
    "cancelled": "https://yourdomain.tld/order/payment-cancelled.html",
    "expired": "https://yourdomain.tld/order/payment-expired.html",
    "failed": "https://yourdomain.tld/order/payment-failed.html"
  }
}
```

## Parameters

[block:parameters]
{
  "data": {
    "h-0": "Parameter",
    "h-1": "Type",
    "h-2": "Description",
    "h-3": "Constraints",
    "0-0": "id",
    "0-1": "String(36)",
    "0-2": "Transaction unique identifier.",
    "0-3": "",
    "1-0": "orderId",
    "1-1": "String(36)",
    "1-2": "Unique identifier.",
    "1-3": "",
    "2-0": "reference",
    "2-1": "String(1...255)",
    "2-2": "An identifier specified by you. If webhooks were specified in the request this identifier is added to the webhook request payload.",
    "2-3": "Specified in the request.",
    "3-0": "amount",
    "3-1": "Int(1...99999999)",
    "3-2": "Integer representing the amount of the checkout. Denomination in the smallest currency subunit (e.g. eurocents).",
    "3-3": "Specified in the request.",
    "4-0": "currency",
    "4-1": "String (ISO 4217)",
    "4-2": "Currency code.",
    "4-3": "Specified in the request.",
    "5-0": "purchaseId",
    "5-1": "String(1...35)",
    "5-2": "Identification of the order within your system. Ultimately appears on the payment confirmation (statement and confirmation screen).",
    "5-3": "Specified in the request.",
    "6-0": "description",
    "6-1": "String(1...255)",
    "6-2": "Description of the transaction.",
    "6-3": "Specified in the request.",
    "7-0": "expiresAt",
    "7-1": "String(RFC3339)",
    "7-2": "Expiration time.",
    "7-3": "",
    "8-0": "status",
    "8-1": "String",
    "8-2": "`OPEN` - Transaction has been created. This is the initial status.  \n`SUCCESS` - Transaction successfully paid.  \n`CANCELLED` - Transaction has been cancelled by your customers.  \n`EXPIRED` - Transaction has not succeeded; expired.  \n`FAILURE` - Transaction has not succeeded; unknown reason.",
    "8-3": "",
    "9-0": "action",
    "9-1": "[action](schemas-1#action)  Object",
    "9-2": "The next action to be performed by you for this transaction. This includes a URL where you should `redirect` your customer to perform the payment.",
    "9-3": "This parameter is nullable, and it is only available while the transaction is `OPEN`.",
    "10-0": "createdAt",
    "10-1": "String(RFC3339)",
    "10-2": "Creation time.",
    "10-3": "ISO 8601 date and time.",
    "11-0": "idealTransactionId",
    "11-1": "String(16)",
    "11-2": "The 16-digit transaction ID within the iDEAL scheme as known by the  issuing bank. The value can have leading zeros.",
    "11-3": "This value is null if the status is `OPEN` or `FAILURE`.",
    "12-0": "returnUrl",
    "12-1": "String(2000)",
    "12-2": "Specifies the URL where your customers will be redirected to when the payment process is completed.",
    "12-3": "Specified in the request.",
    "13-0": "returnUrls",
    "13-1": "Object",
    "13-2": "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`.",
    "13-3": "Specified in the request."
  },
  "cols": 4,
  "rows": 14,
  "align": [
    "left",
    "left",
    "left",
    "left"
  ]
}
[/block]

## Optional parameters

| Parameter | Type                                   | Description                                                                                            | Constraints                                          |
| :-------- | :------------------------------------- | :----------------------------------------------------------------------------------------------------- | :--------------------------------------------------- |
| issuer    | String(8...11)                         | Bank Identification Code.                                                                              |                                                      |
| language  | String(ISO 639-1)                      | Preferred language of the user interface.                                                              | Specified in the request.                            |
| webhooks  | Array of objects                       | Webhooks enable receiving a web request once a given event occurs.                                     | Specified in the request.                            |
| consumer  | [consumer](schemas-1#consumer)  Object | Contains the Name, Bank Identification Code, and IBAN used by the customer that completed the payment. | This field is `null` until the payment is completed. |
| refunds   | [refund](schemas-1#refund)  Object     | Indicates refundedAmount and refundedPendingAmount.                                                    |                                                      |

## Response codes

| HTTP status | Description                                                                                                                                                                                                                                      |
| :---------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 201         | Successful transaction.                                                                                                                                                                                                                          |
| 4XX         | Client error response (See message for details). This response is given when the user input was incorrect or something illegal was attempted (eg. using a service without having that service configured for the user, or not being authorized). |
| 5XX         | Server error response (See message for details).                                                                                                                                                                                                 |