DocsGetting Started

    Getting Started

    Get up and running with LoyalPro in minutes

    5 min readBeginner

    Overview

    LoyalPro provides a comprehensive REST API that enables you to build powerful loyalty programs for your business. This guide will walk you through the essential steps to integrate LoyalPro into your application.

    STEP 01

    Create Your Account

    Sign up for a free LoyalPro account to get your API credentials.

    STEP 02

    Get API Keys

    Generate your API keys from the developer dashboard.

    STEP 03

    Install SDK

    Install our SDK for your preferred programming language.

    STEP 04

    Make Your First Call

    Start integrating LoyalPro into your application.

    Prerequisites

    Before you begin, make sure you have:

    • A LoyalPro account (sign up for free at loyalpro.com)
    • Basic knowledge of REST APIs
    • A development environment with Node.js, Python, or PHP
    • An HTTP client like cURL, Postman, or Insomnia

    Authentication

    LoyalPro uses API keys to authenticate requests. You can manage your API keys from your dashboard. Your API keys carry many privileges, so be sure to keep them secure.

    Keep your API keys secure

    Never share your API keys in publicly accessible areas such as GitHub, client-side code, or in URLs.

    API Key Header
    Authorization: Bearer YOUR_API_KEY
    X-LoyalPro-Version: 2025-01-01

    Test Mode

    Use test API keys (starting with sk_test_) for development.

    Live Mode

    Use live API keys (starting with sk_live_) for production.

    Installation

    Install the LoyalPro SDK for your preferred programming language:

    Node.js
    npm install @loyalpro/node-sdk
    Python
    pip install loyalpro
    PHP
    composer require loyalpro/loyalpro-php

    Make Your First API Request

    Let's create your first customer in LoyalPro. Here's a simple example:

    Node.js Example
    const LoyalPro = require('@loyalpro/node-sdk');
    
    const loyalpro = new LoyalPro('sk_test_your_api_key');
    
    // Create a new customer
    const customer = await loyalpro.customers.create({
      email: 'customer@example.com',
      name: 'John Doe',
      phone: '+234 801 234 5678'
    });
    
    console.log(customer);

    Response

    {
      "id": "cus_abc123xyz",
      "email": "customer@example.com",
      "name": "John Doe",
      "phone": "+234 801 234 5678",
      "points_balance": 0,
      "tier": "Bronze",
      "created_at": "2025-01-15T10:30:00Z"
    }

    Next Steps

    Was this page helpful?

    Help us improve our documentation