Recurring payments

Last modified:

Walley Checkout is compatible with the WooCommerce Subscriptions extension for handling of recurring payments.

Requirements

To get started with recurring payments via Walley in your WooCommerce store, you will need the following:

  • Your Walley account needs to be configured to enable recurring payments. Get in touch with Walley to activate this feature.
  • Renewals requires webhooks that must be set up in the Walley Merchant Hub, otherwise your store won’t receive any callbacks.
  • The extension WooCommerce Subscriptions installed and configured.

Whitelisting your store for webhooks

  1. Sign in to your Walley Merchant Hub
  2. On the top-right, click on your account name, and click Manage Organization.
  3. Click on Create new, and then click Webhook.
  4. Webhook endpoint – Enter your store’s URL, followed by /wp-json/krokedil/walley/v1/callback.
  5. Events – You can pick multiple events at the same time. These are the required events:
    walley:order:created
    alley:authorization:failed
    walley:authorization:retrying
  6. Stores – Select your store(s).
  7. Authentication – Authentication is not needed, this needs be set to None.
  8. Click on Create to save the webhook.

The HMAC key is not used in the plugin, so you can ignore this info when it appears.

Get started with subscriptions

  1. Create a simple subscription product. Set it to a daily renewal so that we can test the renewal process as well.
  2. Make a test purchase (either with a real account or a test account).
  3. Make sure that:
    • The subscription order is created in both Walley and WooCommerce.
    • A Walley reservation number is added to the order notes in WooCommerce.
    • The subscription status is set to Active in WooCommerce.
  4. Wait 24 hours and check that the renewal order is created, a new reservation number from Walley is added to the order notes in the renewal order and the subscription is set to Active again.

Don’t have time to wait for the renewal to be triggered?

There are couple of options to avoid waiting 24 hours for a renewal to be triggered.

The fastest way is the Process renewal action

Please note that you can only renew an Active subscription and that the subscription must be authorized by Walley for a renewal to work. An order will remain in status On hold until an authorization is made.

  1. Navigate to the subscription (→ WooCommerce → Subscriptions) you want to test.
  2. In the right column you should see a box named Subscription actions.
    Choose Process renewal and click Apply.

You can also change the date and time for Next Payment in the subscription and set it to an earlier time than 24 hours if you don’t want to wait that long.

  1. Navigate to the subscription (→ WooCommerce → Subscriptions) you want to test.
  2. In the right column you should see a box named Billing Schedule.
  1. Click the date field of the Next Payment section. A calendar is now displayed where you can select todays date. The nearest time you can set the renewal to be triggered is 1 hour in the future.
  2. Wait 1 hour for the renewal to be triggered and then make sure the renewal and subscription behaves as explained in the Get started with subscriptions section.

Failed renewal orders

If a renewal order is denied in Walleys system, the subscription will be set to On hold. Information about the reason why the renewal failed will be added as an order note in the renewal order.

Failed payment flow

If a renewal payment fails, the customer will receive an email with the following subject line  Invoice for renewal order #…

By clicking the Pay now link in the mail, the customer is redirected to the checkout page to pay for the order and re-activate their subscription.

After the customer have finalized the purchase, the subscription is set to Active again.

In general failed renewal payments with a 4xx error code should be treated as a failed payment where the customer need to take action and click the Pay now link in the email to re-activate their subscription.

Automatic Payments

WooCommerce Subscriptions offers two methods for accepting recurring payments:

  • Automatic payments
  • Manual payments

To understand the difference between the two methods, read Subscription Renewal Process before continuing.

Walley supports automatic recurring payments.

Basic Features

Subscription Suspension
Subscription Cancellation
Subscription Reactivation

Advanced Features

Multiple Subscriptions
Recurring total changes
Payment date changes
Customer payment method changes
Store manager payment method changes

Troubleshooting

No subscription is being created. When a customer signs up there is only a regular order created.

This is usually happening because a new customer account wasn’t created.
The most common reason for this is that the account settings described in the Requirement section isn’t configured correctly.

No renewals are triggered at all

This is usually because you are working in a staging/test environment. WooCommerce Subscriptions have a built-in feature that determine if your installation is a production site or a staging site. From the staging site no renewals are being triggered. Read more about how WooCommerce Subscriptions handle staging sites and migrations here.

When is a pending subscription created?

A pending subscription is created at the same time as when a pending order is created.

Can I offer a free trial with subscriptions?

Yes, free trials are supported.
Orders that include a non-trial subscription with a total value of 0 are also supported – for example, when multiple coupons are applied that bring the order total to zero.