Search

Are you looking for test card numbers?

Would you like to contact support?

Marketpay icon

Configure notifications

Learn how to set up and test MarketPay notifications.

For each notification type that you want to receive from Adyen MarketPay, create a corresponding configuration. You can also get information on all notifications you already configured, update these configurations, test and delete them.

You also need to accept each notification, to confirm that you've received it.

Create a notification configuration

To configure a notification, make the /createNotificationConfiguration call and pass the URL to accept this notification and the event type(s). In addition, provide the message format, protocol, username, password, and other parameters, as shown in the example below.

Refer to Notification types for the list of event types you can enable.

Request

{
  "configurationDetails":{
    "apiVersion": 5,
    "active": true,
    "description":"Your unique description",
    "eventConfigs":[
      {
        "eventType":"ACCOUNT_HOLDER_VERIFICATION",
        "includeMode":"INCLUDE"
      },
      {
      "eventType":"ACCOUNT_HOLDER_CREATED",
      "includeMode":"INCLUDE"
      }
    ],
    "notifyURL":"https://www.merchant-domain.com/notification-handler",
    "notifyUsername":"yourUsername",
    "notifyPassword":"yourPassword",
    "sslProtocol":"SSL"
  }
}

Response

{
    "pspReference": "8515659468351668",
    "configurationDetails": {
        "active": true,
        "apiVersion": 5,
        "description": "Your unique description",
        "eventConfigs": [
            {
                "eventType": "ACCOUNT_HOLDER_VERIFICATION",
                "includeMode": "INCLUDE"
            },
            {
                "eventType": "ACCOUNT_HOLDER_CREATED",
                "includeMode": "INCLUDE"
            }
        ],
        "notificationId": 20272,
        "notifyURL": "https://www.merchant-domain.com/notification-handler",
        "sslProtocol": "SSLInsecureCiphers"
    }
}

Get a configuration

To get the details of a previously configured notification, make the /getNotificationConfiguration call and pass the notification ID as a parameter.

Request

{
   "notificationId":2
}

Response

{
   "pspReference":"9914734158490053",
   "configurationDetails":{
      "active":true,
      "apiVersion":5,
      "description":"Your unique description",
      "eventConfigs":[
         {
            "NotificationEventConfiguration":{
               "eventType":"ACCOUNT_HOLDER_VERIFICATION",
               "includeMode":"INCLUDE"
            }
         }
      ],
      "notificationId":2,
      "notifyURL":"https://www.merchant-domain.com/notification-handler",
      "sslProtocol":"SSL"
   }
}

Get a list of configurations

In addition, you can get a list of all configured notifications. For this, make the /getNotificationConfigurationList call and pass an empty request as a parameter.

Request

{ }

Response

{
    "pspReference": "8815658961765256",
    "configurations": [
        {
            "active": true,
            "description": "TestNotif11",
            "eventConfigs": [
                {
                    "eventType": "ACCOUNT_HOLDER_VERIFICATION",
                    "includeMode": "INCLUDE"
                }
            ],
            "notificationId": 20052,
            "notifyURL": "https://www.merchant-domain.com/notification-handler",
            "sslProtocol": "SSLInsecureCiphers"
        },
        {
            "active": false,
            "apiVersion": 5,
            "eventConfigs": [
                {
                    "eventType": "TRANSFER_FUNDS",
                    "includeMode": "INCLUDE"
                },
                {
                    "eventType": "BENEFICIARY_SETUP",
                    "includeMode": "INCLUDE"
                }
            ],
            "notificationId": 20008,
            "notifyURL": "https://www.merchant-domain.com/notification-handler",
            "sslProtocol": "SSLInsecureCiphers"
        }
    ]
}

Update notification configurations

To change notification settings, make the /updateNotificationConfiguration call and pass new settings as its parameters. The notification to be updated is specified by the notificationId value.

Request

{
   "configurationDetails":{
      "active":false,
      "apiVersion":5,
      "description":"new description799847",
      "eventConfigs":[
         {
               "eventType":"ACCOUNT_HOLDER_CREATED",
               "includeMode":"EXCLUDE"
         },
         {
           "eventType":"ACCOUNT_CREATED",
           "includeMode":"INCLUDE"
         }
      ],
      "notificationId":3,
      "notifyPassword":"testPassword2",
      "notifyURL":"https://www.merchant-domain.com/notification-handler",
      "notifyUsername":"testUserName2",
      "sendActionHeader":false,
      "sslProtocol":"SSL"
   }
}

Response

{
   "pspReference":"9914734160470077",
   "configurationDetails":{
      "active":false,
      "apiVersion":5,
      "description":"new description799847",
      "eventConfigs":[
         {
               "eventType":"ACCOUNT_CREATED",
               "includeMode":"INCLUDE"
         },
         {
               "eventType":"ACCOUNT_HOLDER_CREATED",
               "includeMode":"EXCLUDE"
         }
      ],
      "notificationId":3,
      "notifyURL":"https://www.merchant-domain.com/notification-handler",
      "sslProtocol":"SSLInsecureCiphers"
   }
}

Delete notification configurations

If you no longer need some of configured notifications, delete them by making the /deleteNotificationConfigurations call. Notifications to be deleted are specified by the IDs in the notificationIds array.

Request

{
   "notificationIds":[
      11,
      26
   ]
}

Response

{
   "pspReference":"9914713525761479"
}

Accept notifications

To confirm that you have received a notification, your server should acknowledge the notification with the response:

{
    "notificationResponse" : "[accepted]"
}

We use at-least-once delivery to ensure that your server has received a notification. If your server has not acknowledged a notification within 10 seconds we will queue all notifications to this endpoint. We'll then retry sending the notification until it is accepted. Once accepted, you'll receive all your queued notifications.

Retry attempts will happen regularly, at increasing time intervals:

  • 2 minutes
  • 5 minutes
  • 10 minutes
  • 15 minutes
  • 30 minutes
  • 1 hour
  • 2 hours
  • 4 hours

Retries then happen every 8 hours for the following 7 days.

Test a notification

To test a notification configuration, make the /testNotificationConfiguration call and pass a notificationId as a parameter.

Request

{
   "eventTypes":[

   ],
   "notificationId":10
}

Response in case of success

{
   "pspReference":"9914734161240289",
   "errorMessages":[

   ],
   "eventTypes":[
      "ACCOUNT_HOLDER_CREATED"
   ],
   "exchangeMessages":[
      {
         "ExchangeMessage":{
            "messageCode":"Number",
            "messageDescription":"1"
         }
      },
      {
         "ExchangeMessage":{
            "messageCode":"Title",
            "messageDescription":"Test 1: Test_ACCOUNT_HOLDER_CREATED"
         }
      }
   ],
   "notificationId":10,
   "okMessages":[
      "ResponseCode: 200",
      "ResponseTime_ms: 6",
      "Output: {\"name\":\"[accepted]\"}"
   ]
}

Response in case of failure

{
   "pspReference":"9914734162410311",
   "errorMessages":[
      "Failed to send message. Error description: Not equiped to send com.adyen.services.marketplace.notification.event.account.AccountHolderVerificationNotification"
   ],
   "eventTypes":[
      "ACCOUNT_HOLDER_VERIFICATION"
   ],
   "exchangeMessages":[
      {
         "ExchangeMessage":{
            "messageCode":"Number",
            "messageDescription":"1"
         }
      },
      {
         "ExchangeMessage":{
            "messageCode":"Title",
            "messageDescription":"Test 1: Test_ACCOUNT_HOLDER_VERIFICATION"
         }
      }
   ],
   "notificationId":10,
   "okMessages":[

   ]
}

Next steps