If you have your own platform you can use our Developer API to integrate your system with ours. 

The typical use case involves accepting gift cards as payment/discount against an online order, subscription, service or booking. You can achieve that and lots more with our API.


How to accept our gift cards in your custom online checkout/system

Please note: This requires that you have full developer access to your online checkout system. If you use an off the shelf system (like Shopify, WooCommerce etc...) we have specially built integrations for them, and more...

To accept gift cards balances on your custom e-commerce checkout all you need to do is have an input field (or use the existing typical "enter your promo code here..." field) that asks for our 5 character alpha-numeric, unique gift card code.

The process to accept our gift card balances against an order/booking in your system etc... is typically as follows: 

1. Ask us for the balance via our API

When you have that you will need to validate the gift card exists and determine the balance on it. To do that you call "Get a gift card by code".

2. Accept the balance in your system

We return a full JSON object defining 2 key parts of information, one is whether the gift card can be redeemed (true or false), the other is the remaining value on the gift card in your Gift Up! account's currency. 

Process the order as you normally would, but discounting by an amount up to the gift card remaining balance amount.

3. Instruct us to redeem some money off the gift card via our API

Once you've accepted the order in your system you will want to tell us to redeem an amount off of the gift card so that the customer cannot use it again straight away. To do this you can call either "Redeem a gift card in full" or "Redeem a gift card" for a partial or full redemption.

We have 2 ways to redeem an amount of a gift card which means that you can, if you choose, allow customers to use their balance over many transactions.


How to accept our gift cards against a subscription/customer account

You might have a different use in mind: one where you apply a gift a gift card balance against an account your customers hold, or against a subscription/plan somewhere. This follows the basic steps above still, and can be accommodated easily.


How to authorize against our API

To authorize against our API  you will first need an API key. Once you have this all you need to do is add a header in your HTTP request as follows:

Name: Authorization
Value: bearer {API Key}


httpClient.AddHeader("Authorization", "bearer eyJhbGciOiJIUzI1NiIsInR5cBI6IkpXVCJ9.eyJqdGkiOiJmMTdmOGNmOS0wMjliLTRhNzgtOGY2Ny04ZjZhNDg0MzExY2IiLCJzdWIiOiJsZWVAa29hbi5pcyIsImh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vd3MvMjAwOC8wMi9pZGVudGl0eS9jbGFpbXMvcm9sZSI6IlN5c3RlbUFkbWluaXN0cmF0b3IiLCJleHAiOjE4MjM0MjczMTQsImlzcyI6Imh0dHBzOi8vZGFzaGJvYXJkLmdpZnR1cGFwcC5jb206NDQzOTIvIiwiYXVkIjoiaHR0cHM6Ly9kYXNoYm9hcmQuZ2lmdHVwYXBwLmNvbTo0NDM5Mi8ifQ.tqtT9A4iDsYsXBBFYMg83U0YqdzfvEVbVZ5ndregRV")

Please note the above API key is invalid and will not work.

Testing your integration

Because you will want to develop and test your integration, you need a way to not affect your live Gift Up! account data. We have as fully featured test/sandbox mode for developing against our API. 

To enable test mode add a HTTP header to your request 

x-giftup-testmode: true

 Then whenever you do anything via our API (querying gift card balances, creating gift card orders) it will be in our test sandbox.

Subscribe to Webhooks to be notified about new gift card orders / redemption

If you need to be notified immediately to a new gift card order or a new redemption against an existing gift card, you can use our Webhooks system (or use Zapier below).

You can create a webhook endpoint that you own and subscribe that URL against specific events in your Gift Up! account:

 - Order created
 - Gift card created
 - Gift card updated
 - Gift card redeemed


Alternative to using our API

If the idea or writing code to achieve an integration with us is not palatable, you might be able to use our Zapier app to write some workflows that you need to happen, some examples of what our customers currently do with them:

  1. Send an email to your staff when you sell a gift card
  2. Create a gift card and email it to the recipient when you get sent a specific email
  3. Send a text message to yourself when a gift card gets redeemed
  4. Subscribe purchasers to a mailing list somewhere
  5. Trigger a marketing workflow when you sell a gift card

You can achieve almost everything that our API can do, but without writing a single line of code. Read about our Zapier app.

Did this answer your question?