Loyalty.lt
SDKsPython

Installation

Install the official Loyalty.lt Python SDK

Installation

The official Loyalty.lt Python SDK for Shop API integration.

pip

pip install loyaltylt-sdk

Requirements

  • Python 3.8+
  • requests library (installed automatically)

Quick Start

from loyalty_sdk import LoyaltySDK

sdk = LoyaltySDK(
    api_key='lty_your_api_key',
    api_secret='your_api_secret',
    environment='production',  # or 'staging'
    locale='lt'
)

# Test connection
shops = sdk.get_shops()
print(shops['data'])

Configuration Options

OptionTypeDefaultDescription
api_keystrrequiredAPI Key
api_secretstrrequiredAPI Secret
environmentstrproductionproduction or staging
localestrltAPI locale (lt, en)
timeoutint30Request timeout in seconds
retriesint3Number of retry attempts
debugboolFalseEnable debug logging

Getting API Credentials

Access Partners Portal

Go to partners.loyalty.lt and log in.

Navigate to API Credentials

Click API Credentials in the sidebar.

Generate Credentials

Click Generate New Credentials.

Copy Credentials

Copy API Key (lty_...) and API Secret. Store securely!

Never expose your API Secret in client-side code. Store credentials in environment variables.

Next Steps

Learn common SDK operations

QR Login and Card Scan

On this page