How to check your wallet balance with Reloadly’s Gift Card API

Raphael Ugwu

Raphael Ugwu

< 1 read

Table of Contents

    When building an application with Reloadly’s Gift Card API, your application makes gift card orders from your wallet balance. This creates the need to keep an eye on your balance in real time.

    This guide shows you how to how to embed an API request in any of your gift card applications that shows you the data of your wallet’s balance in real time. With this, you can avoid running low when making multiple gift card orders

    The objective of this guide can be achieved with the following steps:

    • Getting your access token from the Gift Card authentication service
    • Make the request for the wallet balance

    You can get your access token by following the steps in this quickstart. The cURL code sample below specifies how you can then use your access token to make a request to check your wallet balance.

    curl -i -X GET \  https://giftcards.reloadly.com/accounts/balance \  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'?

    If your request is successful, you should receive a response similar to the following

    {  "balance": 5000,  "currencyCode": "USD",  "currencyName": "US Dollar",  "updatedAt": "2021-12-04 08:45:51"}?

    This response can be made functional in a number of ways. For instance, you can create an alert to occur when a particular threshold is crossed in the value of the balance property.

    Resources

    Reloadly Gift Cards API

    Reloadly Developer Documentation

    This might also interest you

    Three layers of suppliers behind an employee recognition catalog, from merchant to reward infrastructure provider to recognition platform
    Product & Platform
    Caio Carnieri

    Where the Rewards in a Recognition Catalog Come From

    A determined platform publishes 200 million reward options across 100 countries and 130 currencies. It does not own them. Employee recognition platforms source almost none