Live Support

Introduction

What is the Gift Card Suite?

The Gift Card Suite is an easy to use gift card system for Magento community edition. It features the ability to allow the customer to reload existing cards, buy mailed cards and printable cards. Everything is configurable such as SKUs for gift cards, email template for printable cards and allowable amounts to purchase.

How it Works

Gift Card Suite uses a new template for the user to buy and check balances of their gift cards. It is fully configured in the admin and all cards can be edited in the admin panel.

Installation

Before you Install

As with all our modules (and all modules in general), installing this module directly and solely in a live environment is strongly discouraged. It is recommended that it be installed in a development environment, configured, tested, and then deployed to your live environment through your deployment method of choice (i.e. - git, subversion, etc...). If this is not possible, then the next best thing would be to make a FULL backup before installation.

Compilation

As with all our modules (and all modules in general), installing this module while compilation is turned on is not recommended. Please turn off compilation before installing.

Pre-requisites

Code/Conflicts

  • NO EDITS OR MODIFICATIONS TO MAGENTO CORE (Typically, this includes all code inside the app/code/core folder)
  • No conflicting modules (or conflicting custom code) installed (Typically, if installed component/module affects same functionality as Gift Card Suite--gift cards/reward points, you should be wary of conflicts)

Magento Version

  • Community Edition 1.4 - 1.9.0.1

Installing the Basic Application

Navigate to the root of your application. You should see folders like (app, downloader, skin, etc...). You can either install this manually or via Magento Connect. To install Manually, unzip the module Tar and then copy/paste to the root of your folder.

To install using Magento Connect, go to System -> Magento Connect -> Magento Connect Manager. Click on Browse, then click on the module and install. This will automatically install the product for you.

That's it for installation! Now you just have to configure Gift Card Suite.

Configuration

Creating The Gift Cards

The suite uses three products that need will be created automatically for you from the configuration. A mailable card product, printable card product, and a re-loadable card product. You can create these from the System->Configuration->Sales->Sales->Gift Card section of your configuration. Below is a description of what each one is.

  1. Mailable card product : This should be a simple product. Visibility should be set to "Not Visible Individually". Set the price to 0(zero), as the module will set the price of the item. You should not manage stock on this product.
  2. Printable card product : This should be a virtual product as it is not shipped. This should not be visible individually, price set to zero, and do not manage stock.
  3. Re-loadable card product : This is also a virtual product, not visible individually, price set to zero, and do not manage stock.

The products will automatically be created when you click on the save button. Click System->Configuration, then in the left column click on Sales. There will be a 'Gift Card' section that looks like the following:

Here is what the created SKU's look like:

Settings

Set prices you will allow for gift cards. So in the 'Amounts' field make a comma separated list of prices. For example, if you allow cards to be bought for $15, $30, and $50, you would enter in this field 15,30,50.

The next three fields are for specifying the transactional email template to be used in sending printable gift cards. We create the transactional email automatically so you would just need to know the ID number of it. You can find this by going to System->Transactional Emails. Also specify the email address and name that the email will come from. The transactional email MUST contain the following variables for the new card number, gift message, and balance to be passed in the email: {{var number}}, {{var msg}}, and {{var amount}}.

Cron Job

Ensure you have a cron job set up as per default Magento's requirements. The recommended interval is 5 minutes.

Note

A cron job is required to clear out any authorizations to gift cards that are abandoned. Abandoned gift card authorizations are cleared out every hour.

Shipping (Optional)

The last optional setting is setting a new shipping method. This is available if you need a shipping method for carts that only contain mailable card(s). To enable this, select the Shipping Methods from the System->Configuration screen. Select the Gift Card section. You can then select to enable the method, set it's title and name, select the set price for shipping OR set a percent of the subtotal for a shipping price. You can also select the countries the method is available in and the order you would like it to show in the list of methods.

General Usage

Managing Gift Cards

There is a new menu item in the admin called 'Gift Cards'. Under it there is a sub-item called 'Manage Gift Cards'. When you enter this section there will be a grid listing gift cards with their number and remaining balance. You can click an item to edit the details of the card. Here is where you can edit the balance of a card. Here you can also create multiple giftcards at the same time:

If you navigate to http://yoursite.com/giftcard (replace yoursite with the domain you installed this module on), you will see the gift card interface.

It is split into three sections: Buying a new Gift Card, Adding to a Gift Card(Re-loading), and checking a balance:

  1. Buy a Gift Card : This section the customer can buy new cards. They can either choose a physical card to be mailed to them or choose to buy a gift card to be sent to their email. If an email card is chosen, they will be required to enter an email address where the card will go. This can be any email address, even if its not the customers email that is checking out. This can be useful in sending gift cards to others. They then select the amount of the card and add it to the cart.
  2. Adding to a Gift Card : This section is used for reloading a card. The user simply enters an existing card number with an amount to re-load with, then clicks add to cart. This keeps the number associated with the cart item. So on a successful checkout the items amount will be added to the card. This will also let the user know if the card they enter is invalid or not.
  3. Checking Your Balance : This section is used for customers wanting to check the balance of their card. They simply enter their card number and click Check Balance. This will also let the user know if the card they enter is invalid or not.

Running a Test

The module adds a test card automatically. The test card number is 12341234. The starting balance is $500 and can be changed in the admin panel. If that works, then you should be set.

That's the tour. Short and sweet. Enjoy selling and accepting gift cards!

Gift Card API

The Gift Card Suite includes an API for external interaction with creation, charging, querying, and re-loading gift cards. This API is an extension of the Magento API (SOAP web service) and users and API keys are managed in the administration section of Magento.

API Methods

The following are methods provided by the Gift Card Suite.

  1. balance This method requires a gift card number to be passed to it. It returns the giftcard balance. If the card is not valid it will throw a fault 'Invalid Card'.
  2. charge This method requires both a gift card number and an amount to be charged to the card. This will deduct funds from the cards balance and also create a payment record for that gift card that can be viewed in the magento administration panel. This will also throw a fault if the card is not valid. You should check the cards balance before charging to verify funds.
  3. validate This method requires a gift card number. It simply return if the card is valid or is not valid.
  4. add This method requires an amount. This creates a new gift card. This is for purchasing gift card externally to be used on the site. This method will return the new gift card number. A fault will also be thrown if a new card cannot be created.
  5. reload This method requires both a gift card number and an amount. This method is for reloading a gift card with more funds. If the call is successful then it will return the updated card details. If there is an error it will throw a fault.

Example PHP call:

PHP Making an API Call

$proxy = new SoapClient('http://www.yourstoreurl.com/api/soap/?wsdl');
$sessionId = $proxy->login('api_user', 'api_password');
$balance = $proxy->call($sessionId, 'giftcard.balance', array('12341234'));
echo $balance;

This is a simple SOAP service, and most languages support consuming these services. Please consult a developer or your language documentation for making calls to SOAP services to integrate with your particular system.