Configurations

Before tweaking your Adyen subscription settings in Magento, you need to configure the default Magento cronjob.

Configure the default Magento cronjob

To configure the default Magento cronjob, do the following:

  • In the Magento Admin Panel, go to the System menu, and select Configuration.
  • On the left-hand navigation sidebar In the Magento Admin Panel, browse to the Advanced category, then click System.
  • In the System area, click the Cron (Scheduled Tasks) section.
  • Set the Generate Schedules Every input field to 1.
  • Click Save Config.

This sets the cronjob generation time interval to 1 minute.

Adyen subscriptions

You can access the configuration area to adjust the default settings depending on your needs:

  • Log in to Magento with your credentials.
  • In the Magento Admin Panel, go to the System menu, and select Configuration.
  • On the left-hand navigation sidebar, browse to the Sales category, then click Adyen Subscriptions.

The Adyen Subscriptions area makes the following sections available:

  • General
  • Subscription
  • Order

This is where you can change and edit all the settings related to the Magento integration with the Adyen payments platform.

Configurations

In the Adyen Subscriptions area you can edit settings and options to customize the integration depending on your needs.
These are some typical action you can carry out in this area to adjust the configuration to satisfy your requirements:

  • Require a cancel reason before canceling a subscription.
  • Configure the allowed payment methods for subscriptions.
  • Allow shoppers to cancel payments.
  • Allow shoppers to pause and resume payments.
  • Define the maximum number of upcoming orders shoppers can see.
  • Allow shoppers to reorder subscriptions.
  • Enable retry for failed payments.
  • Edit and modify cronjob schedules.

Cancel reason

Require a cancel reason before canceling a subscription

Before canceling a subscription, you may want to obtain some additional information providing more context for the cancellation.
To do so, you can define a number of cancellation reasons that fit your business scenario and use cases.

  • In the Adyen Subscriptions area, go to the Subscription section.
  • The Cancel Reasons settings allow you to:
    • Add Reason: add a new cancel reason for a subscription cancellation.
    • Delete: remove an existing cancel reason for a subscription cancellation.
  • Add Reason: when you create a new cancel reason, specify the following values:
    • Code: the cancel reason code.
    • Label: a reference label with a short description of the cancel reason code.

The cancel reason code is saved with the subscription it belongs to.
It is displayed in the subscription history overview, and the label value is displayed to the user when they cancel a subscription.

Payment methods

Configure the allowed payment methods for subscriptions

By default, only credit cards are allowed.
To enable more payment methods, do the following:

  • In the Adyen Subscriptions area, go to the Subscription section.
  • Allowed payment methods offer a list of the available payment methods.
    The list is limited because not all payment methods support recurring payments.

iDEAL and Sofort recurring transactions are processed as SEPA Direct Debit payments in the background.

Cancel

Allow shoppers to cancel subscriptions

You can allow shoppers to cancel subscriptions.
To enable this feature, do the following:

  • In the Adyen Subscriptions area, go to the Subscription section.
  • Cancel Subscription offers a drop-down menu: select Yes to allow canceling subscriptions.

Pause resume

Allow shoppers to pause and resume subscriptions

You can allow shoppers to pause and resume subscriptions.
To enable this feature, do the following:

  • In the Adyen Subscriptions area, go to the Subscription section.
  • Pause/Resume Subscription offers a drop-down menu: select Yes to allow pausing and resuming subscriptions.

Upcoming orders

Allow shoppers to see their upcoming orders

You can allow shoppers to see dates referring to their upcoming orders.
To enable this feature, do the following: 

  • In the Adyen Subscriptions area, go to the Subscription section.
  • Show upcoming orders offers a drop-down menu: select Yes to allow showing upcoming orders.
    By default, this option is disabled.
  • Number of upcoming orders: sets the maximum number of orders displayed.
    The default setting is 5. You can change this value.

Reorder

Allow shoppers to reorder subscriptions

You can allow shoppers to include an existing subscription into a new subscription as a reorder.
To enable this feature, do the following:

  • In the Adyen Subscriptions area, go to the Order section.
  • Subscription at reorder offers a drop-down menu: select Yes to allow including the product subscriptions in a reorder.
    The default setting for this option is No.

Retry

Enable retrying failed payments

By default, when a payment request fails, the subscription returns a payment error.
You can change this behavior by enabling the retry feature for failed payments.
To enable this feature, do the following: 

  • In the Adyen Subscriptions area, go to the Subscription section.
  • Retry failed payment offers a drop-down menu: select Yes to allow enable the failed payment retry feature.
  • Number of retries for payment failure: sets the maximum number of retries for a failed payment
    If you leave this field empty, the system keeps retrying as long as a payment failure is received.
    The default setting is 3 retries. You can change this value.
  • Time (in hours) between retries payment failure: sets the time interval between a payment error response and the corresponding payment retry.
    This time check depends on the cronjob.
    The default setting is 24 hours between a payment failure and a payment retry. You can change this value.

Cronjobs

Schedule the cronjobs

Default  Subscription
cronjob expression
*/5 * * * *
The cronjob is executed every 5 minutes.
Default  Quote
cronjob expression
*/20 * * * *
The cronjob is executed every 20 minutes.
Default Order
cronjob expression
*/30 * * * *
The cronjob is executed every 30 minutes.

Cronjobs

Make sure you have the cronjobs enabled in Magento. A handy tool to see if your cronjob is running is AOE Scheduler.

The module comes with three cronjobs that need to run. We will explain them here.

Subscription

 If an order has a subscription product and the following requirements are true:

  • Invoice is created (pending, captured or offline)
  • Status is processing
  • Has Billing Agreement**

It will create a subscription profile based on the order that is created. This subscription profile is viewable in Sales => Adyen Subscriptions section.

It will create a subscription out of the created order. You can see this subscription in the Sales => Adyen Subscriptions section.

** Make sure you have Recurring_Contract notification turned on. Please contact magento@adyen.com to enable this for you

Quote

A quote for a subscription will be created as the follow requirements are true: 

  • Scheduled Order is in the upcoming 2 weeks
  • Subscription status is active or quote_error

It will create a Quote. This gives you the option to change the quote before it is created to an order. You can see this as an open shopping cart.

Order

A quote will be converted to an order when the following requirements are true: 

  • The Scheduled Order date is in the past
  • Subscription status is inactive, order_error or payment_error**
  • Has an active quote that is not yet converted to an order

** payment_error is by default it will not retry on a payment_error you can overrule this in subscription configuration