Child pages
  • Subscriptions and Recurring Payments 2.X
Skip to end of metadata
Go to start of metadata


Having hard time finding an answer to your question?

Check out our Knowledge Base.

Extension page:

The Subscriptions and Recurring Payments extension by aheadWorks extends Magento abilities further – now you are able to create subscription products using flexible settings and sell them on a recurring basis.


Importrant note for Subscriptions And Recurring Payments 1.X users


Due to significant changes in the extension's design, versions 1.X and 2.X are not compatible. This means that 2.X versions can not use the settings and data from 1.X.

However, the 1.X and the 2.X versions can work at the same store simultaneously. Thus, during migrating to 2.X version, you can still leave the 1.X version active, so that it could handle your existent subscriptions.



1. Backup your web directory and store database.

 Click to view details

You can make backup copies with any tool you find appropriate

If you are going to use the native Magento backup function, navigate to System -> Tools -> Backups and perform System and Database backups

 2. Log in to the Magento backend

 3. Disable compilation

 Click to view details

Navigate to System -> Tools -> Compilation.

If Compiler status is Disabled, you can skip to the next step

If Compiler is enabled, disable it.

IMPORTANT: after the extension is installed, you can enable the compilation again; IT IS CRUCIAL that you use "Run Compilation Process" function, not just "Enable button"


Installing an extension with the Compilation enabled will result in store downtime.

 4. Flush store cache

 Click to view details

You can flush the store cache in 2 ways:

  • via the backend:

Navigate to System -> Cache Management menu, and click Flush Magento Cache button

  • via filesystem:

On your server, navigate to Magento root folder, then proceed to /var/cache/; delete all the content there.

 5. Download the extension package from your account and extract the downloaded archive

 6. Copy the content of /Step_1/ folder to your store's root directory

If you are using a custom theme,

 read the instructions here.

In case you are using a custom theme, it is recommended to copy the design files to your current theme's folders. In case there are several themes in use at the same store, the design files must be copied to each of them.

  • Find this folder in the package: /step_1/app/design/frontend/base/default/ ; copy its content to /app/design/frontend/[your_package]/[your_theme]/
  • Find this folder in the package: /step_1/skin/frontend/base/default/ ; copy its content to /skin/frontend/[your_package]/[your_theme]/

 7. Copy the content of /Step_2/ folder to your store's root directory

 8. Flush store cache again; log out from the backend and log in again.


Set up cron (for eWAY)

The extension requires cron daemon set up. If you have already configured cron jobs for your Magento installation then you can skip this step. Read the following instructions on setting cron job for your Magento store: Magento user guide 

Generally it would be enough to run in SSH console of your server: 



crontab -e


And insert the following line:  



*/3 * * * * wget -O - -q ''


Don't forget to confirm saving request when exit.

Once cronjob is set up and running, the extension will be saving every action in the log, which can be viewed in System->Configuration->aheadWorks Extensions->Info->aheadWorks Extensions logging->View log. If you think that the extension does not work as expected, it is recommended to check the log first. If it is empty or contains very few records, it may indicate that your cronjob is not set or set improperly. Normally, every cron launch should add 1 or more entries. Actual quantity of the entries depends on the number of processed events per given cronjob.



General Configuration


The extension general configuration screen is accessible via Subscriptions-> Configuration (or System-> Configuration-> aheadWorks Extensions-> Subscription)

General Settings:

  • Enabled = yes/no
  • Subscription Engine* = PayPal / Authorize.Net / eWAY

*NOTE: the Subscription Engine option is defined per-website. A given website can only have 1 subscription engine active at a time.

Depending on the selected Subscription Engine, the set of available subscription options varies slightly (see Setting Up Subscription Types section for further info)

  • Notifications sender - allows selecting notification emails sender from the store contact emails;
  • Apply tax on trial amount - defines if the tax should be applied for the subscription's trial period;
  • Apply tax on shipping - defines if tax should also be applied to the shipping amount of the subscription.

Frontend Settings:

  • Subscription period selector style - defines the style of displaying subscription period selector on the frontend.


Advanced Settings:

  • Flush all Recurring profiles - this is an irrecoverable action, which clears all the current subscription data.

This function removes all the subscription details on Magento side only, the Payment Gateway-side profiles remain in their current state.

Before using this option, make sure to Suspend or Cancel all the active subscriptions in your Magento, to avoid unexpected charges.



Setting Up Subscription Types

You can create a new subscription type (and manage the existent ones) via Subscriptions-> Subscription Types grid


Adding new Subscription Type:

After clicking Add New button, 1st step is to specify the Website the subscription type will be available at. The Subscription Engine will be picked up automatically, depending on the module’s general settings for this website. The “Configure” link leads to the extension’s General settings screen for a correspondent website

Subscription Type Information screen

General tab:

  • Engine - this field is informative only, the Subscription Engine cannot be changed from this screen. 
  • Title - the Title of a Subscription Type (visible to both admin and to the customer)
  • Status = Visible/Invisible defines whether this Subscription Type will be available [for purchasing] from frontend 
  • Linked Store IDs - the list of the storeviews (within the current website) where the subscription type is available



Schedule tab 

General section:

    • Period Unit - this option defines the minimal time interval (unit) within a period. The Period Unit value is not the actual period duration, technically, it is just a multiplier (see Number of Units in Period)
      • For PayPal, available units are:  Day, Week, SemiMonth*, Month, Year
      • For Authorize.Net**: Days, Months
      • For eWAY: Day, Week, Month, Year
    • Number of Units in Period - defines the period duration. I.e., Your Period = Period Unit * Number of Units in Period 
    • Is Infinite ( Yes / No )*** - this option defines whether the subscription will have limited duration, or will be infinite.
    • Number of Occurrences - this option defines the general duration of a subscription (in case Is Infinite option=”No”). Thus, Subscription Duration = Number of Occurrences * (Number of Units in Period * Period Unit)



*PayPal SemiMonth period unit has fixed payment dates: 1st and 15th of a month

**Authorize.Net engine has certain period config limitations. The interval length cannot exceed 365 days or 12 months. The interval length must be 7 to 365 days or 1 to 12 months

*** The eWAY Payments engine does not support "Infinite" subscription

Trial Period section:

    • Is Trial Period Enabled = yes/no
    • Number Of Occurrences for Trial Period - defines the duration of the trial period. 
Trial Period option is available for PayPal and Autorize.Net systems. It allows to set separate price on first X periods. The options in this section define the length of a trial period. See here for the details on subscription pricing.

Initial Fee section:

    • Is Initial Fee Enabled - enables / disables the Initial Fee
Initial Fee option is available for PayPal and eWAY systems. If enabled, it adds a one-time fixed amount payment, which is taken upfront on subscribing to a product.


 Associated Profiles tab (appears after a new Subscription Type is saved ):

This grid will show all the payment profiles related to this particular Subscription Type



Setting Up Subscriptions

You can manage existent and create new Subscriptions through Subscriptions-> Manage Subscriptions grid.

After clicking "Add New" button, you will be prompted to choose an existing item from your catalog. After that, you will be redirected to the Subscription Information screen.

General Tab:

  • Product Name - this field is informative only, the Subscription Product cannot be changed from this screen.
  • Is Subscription Only - this option defines whether a product will remain available for one-off ordering (the option value = “No”), or only via subscription (the option value=”yes”)
  • Move Customer To Group - this option defines what customer group a subscriber will be moved to after subscribing to the product (if the option is set to“Not Selected”, the customers will remain in their current group)
  • Start Date* - this option defines how the Subscription start will be handled. There are several supported scenarios:
    • Defined By Customer - the customer selects the subscription start date from a calendar.
    • Moment Of Purchase - the subscription will start immediately after order is placed
    • Last Day Of Current Month
    • Exact Day of Month (works in conjunction with “Day of Month” option ) - the subscription will start on the specified day

*The eWAY payment engine has certain subscription start peculiarities:

  • The Moment Of Purchase Start Date is not supported by eWAY engine.
  • Start Date cannot be earlier than on the next day after subscribing to a product.
  • Initial Payment date is always the next day to the subscriptions start.




Subscription Types tab:

From this tab, you can select the available subscription periods (you can add multiple types via “Add” button) and set the subscription pricing for each of the allowed periods.

  • Subscription Type - select from the existent types
  •  Price Per Iteration* - the amount of 1 regular payment within the subscription
  •  Trial Period Price* (for PayPal and Authorize.Net) - the amount of 1 payment within the duration of a Trial Period
  •  Initial Fee (for PayPal and eWAY) - the Initial Fee amount
  •  Sort Order - allows to arrange the subscription types list on the frontend

*Note: the price values (Price Per Iteration and Trial Period Price) set the basic price for a product subscription. For items with custom options and Configurable products, price modifiers are applied as per usual.

E.g., product option A adds extra $10 to the item price. If this option is selected for a subscription, the regular payment amount will be Price Per Iteration + $10 (option A).





Managing payment profiles

You can manage the payment profiles through Subscriptions-> Recurring Profiles -> All grid. From the Profile Information screen, you can view the details of a given profile, check the list or related orders and Suspend* /Activate/ Cancel a subscription.

The Refresh Data button allows you to request a payment status update from the PayPal or Authorize.Net payment gateway side in case it hasn’t arrived automatically.

*NOTE: "Suspend" action is not available for Authorize.Net and eWAY engines. This results from certain technical limitations of these 2 payment gateways.


Email Notifications

Since version 2.2.0 Email Notifications has been introduced to Subscriptions and Recurring Payment extension.

Notifications can be sent to both store administrator and customers upon triggering any of the events available.

  • Name - notification's name for internal identification's purposes;
  • Status - allows enabling/disabling the notification;
  • Event Type - defines on what event the notification should be sent:
    • New profile created;
    • Profile status changed;
    • New order created;
    • Profile expired;
    • Next payment;
  • Recipient - allows defining the notification's recipient either customer or one of the store's contact emails;
  • Store - allows specifying the store view the notifications should be sent for;
  • Template - defines the notification's template (the templates can be created and managed under System > Transactional Emails).



Payment Gateways Configuration configuration

Authorize.Net Account configuration:

  • Create MD5 Hash in Account->Settings-> Security Settings-> (General Security Settings->) MD5-Hash


    Make sure that the MD5 Hash value generated here and the correspondent value in Magento backend settings match.



Magento Payment Method configuration:

  • Configure at System > Configuration > Sales > Payment Methods> Authorize.Net

  • Specify correct API Login ID and Transaction Key (can be retrieved at account)

  • Fill in MD5 Hash value option (this option appears after the extension is installed) 

If you are using test API with, then:

Icon processes recurring payments once a day at 2 AM.

E.g. If the order has been placed at 6 PM, payment will only be charged after a midnight.

PayPal configuration

The extension works via Express Checkout only.

Therefore, the module will only work with PayPal products that include the Express Checkout option.

 Click to check the reference table.


 Payments Advanced (Includes Express Checkout)Payments Pro (Includes Express Checkout)Payments StandardPayflow Pro (Includes Express Checkout)Payflow Link (Includes Express Checkout)Express Checkout


 Website Payments Pro (Includes Express Checkout)Website Payments StandardPayflow ProPayflow Link (Includes Express Checkout)Express Checkout


 Website Payments StandardExpress Checkout


 Website Payments StandardPayflow ProWebsite Payments Pro Hosted SolutionExpress Checkout

United Kingdom

 Website Payments StandardWebsite Payments Pro (Includes Express Checkout)Website Payments Pro Hosted Solution (Includes Express Checkout)Website Payments Pro Payflow Edition (Includes Express Checkout)Express Checkout


 Website Payments StandardExpress Checkout


The extension relies on IPN (Instant Payment Notifications) function of PayPal. Make sure that this function is configured properly for your Magento.

Other than this, the extension does not require any specific PayPal setup.


eWAY Configuration

The extension adds a dedicated eWAY Recurring tab to System -> Configuration -> Sales -> Payment Methods

  • Enabled
  • Title
  • CustomerID - (a numerical value) the unique ID of your eWAY account, can be retrieved from the eWAY side
  • Username - the username of your eWAY account
  • Password - the password to your eWAY account
  • Accepted currency - must match the base currency selected in your eWAY account
  • Credit Card Types - the CC types you are accepting
  • Payment from applicable countries (/ Payment from Specific Countries) - define the countries the payments will be accepted from
  • Sandbox Mode (Yes / No) - enable if you are using a sandbox eWAY account




If you just need to temporary disable the extension, you can just do the steps 1-5, without deleting the files of the extension.

  1. Disable compilation, in case it is enabled.
  2. Login to your FTP, navigate to app/etc/modules/
  3. Open the file AW_Sarp2.xml and change the following line:








    Now your Magento is unaware of the existence of this module.

  4. Clear the cache under var/cache
  5. Make sure that the site is working properly, otherwise roll back the changes and apply to our technical support.
  6. If everything works fine, it is safe to delete the files of the extension.
  7. In case you need to clean the database, backup your database and then run the following queries in MySQL: 


    DROP TABLE IF EXISTS `aw_sarp2_customer_group`;
    DROP TABLE IF EXISTS `aw_sarp2_subscription_item`;
    DROP TABLE IF EXISTS `aw_sarp2_subscription`;
    DROP TABLE IF EXISTS `aw_sarp2_profile_order`;
    DROP TABLE IF EXISTS `aw_sarp2_profile`;
    DROP TABLE IF EXISTS `aw_sarp2_subscription_type`;



    delete from `core_resource` where `code` = 'aw_sarp2_setup'


    Note, if you are using the table with prefixes, you must specify them in all table names. 

    If you are not sure how to do that or expect any troubles with it, please contact your server administrator regarding the matter.
    If you remove the tables as it is described above, you will need to re-configure the extension when it is reinstalled. All subscriptions history will be lost as well.


After the extension installation the store gives an error, or blank page, or suggests to start Magento installation procedure.

Change the owner of the extracted extension files to the web server user and set 775 permissions on them. Clear the store cache and try again.

There is no aheadWorks extensions under my configuration section, or having the extension tab clicked I get a blank page, or Access Denied error.

Clear the store cache, browser cookies, logout and login again.

I've set up everything correctly, inserted the HTML code but there is nothing on that page.

Clear the store cache, clear your browser cache and domain cookies and refresh the page.

My configuration changes do not appear on the store.

Clear the store cache, clear your browser cache and domain cookies and refresh the page.


You can always find the latest version of the software, full documentation, demos, screenshots and reviews at
License agreement:
Contact us:
Copyright © 2019 aheadWorks

  • No labels