Skip to main content
GET
/
{locale}
/
shop
/
games
/
{id}
Get Game
curl --request GET \
  --url https://api.example.com/{locale}/shop/games/{id}
{
  "success": true,
  "message": "Game retrieved successfully",
  "data": {
    "id": 1,
    "name": {
      "lt": "Kavos kortelė",
      "en": "Coffee Card"
    },
    "description": {
      "lt": "Surink 8 antspaudus ir gauk kavą nemokamai!",
      "en": "Collect 8 stamps and get a free coffee!"
    },
    "game_type": "stamps",
    "is_active": true,
    "start_date": null,
    "end_date": null,
    "stamps_required": 8,
    "stamp_settings": {
      "stamps_required": 8,
      "reward_type": "free_product",
      "product_name": "Cappuccino",
      "discount_amount": null,
      "points_amount": null,
      "expiration_days": 30,
      "reset_on_complete": true,
      "layout": "grid",
      "rows": 2,
      "columns": 4,
      "background_color": "#f0f9ff",
      "text_color": "#0369a1",
      "item_name_singular": {
        "lt": "antspaudas",
        "en": "stamp"
      },
      "item_name_plural": {
        "lt": "antspaudai",
        "en": "stamps"
      },
      "punch_text": {
        "lt": "Perkite kavą ir gaukite antspaudą!",
        "en": "Buy coffee and get a stamp!"
      },
      "reward_text": {
        "lt": "Nemokama kava!",
        "en": "Free coffee!"
      },
      "stamp_icon": "coffee",
      "stamp_icon_type": "icon"
    },
    "partner_name": "Coffee Shop",
    "partner_info": {
      "id": 1,
      "name": "Coffee Shop",
      "description": "Best coffee in town",
      "logo": "https://example.com/logo.png"
    }
  }
}

Overview

Get detailed information about a specific game, including its configuration and stamp settings.

Authentication

This endpoint requires Partner API authentication with X-API-Key and X-API-Secret headers.

Parameters

id
integer
required
The game ID

Response

success
boolean
Indicates if the request was successful
data
object
Game details
data.id
integer
Game ID
data.name
object
Localized game name
data.description
object
Localized game description
data.game_type
string
Type of game: stamps, wheel, quiz, collection
data.is_active
boolean
Whether the game is active
data.start_date
string
ISO 8601 timestamp when game starts (optional)
data.end_date
string
ISO 8601 timestamp when game ends (optional)
data.stamps_required
integer
Number of stamps required to complete (for stamp games)
data.stamp_settings
object
Full stamp settings including layout, colors, and images
{
  "success": true,
  "message": "Game retrieved successfully",
  "data": {
    "id": 1,
    "name": {
      "lt": "Kavos kortelė",
      "en": "Coffee Card"
    },
    "description": {
      "lt": "Surink 8 antspaudus ir gauk kavą nemokamai!",
      "en": "Collect 8 stamps and get a free coffee!"
    },
    "game_type": "stamps",
    "is_active": true,
    "start_date": null,
    "end_date": null,
    "stamps_required": 8,
    "stamp_settings": {
      "stamps_required": 8,
      "reward_type": "free_product",
      "product_name": "Cappuccino",
      "discount_amount": null,
      "points_amount": null,
      "expiration_days": 30,
      "reset_on_complete": true,
      "layout": "grid",
      "rows": 2,
      "columns": 4,
      "background_color": "#f0f9ff",
      "text_color": "#0369a1",
      "item_name_singular": {
        "lt": "antspaudas",
        "en": "stamp"
      },
      "item_name_plural": {
        "lt": "antspaudai",
        "en": "stamps"
      },
      "punch_text": {
        "lt": "Perkite kavą ir gaukite antspaudą!",
        "en": "Buy coffee and get a stamp!"
      },
      "reward_text": {
        "lt": "Nemokama kava!",
        "en": "Free coffee!"
      },
      "stamp_icon": "coffee",
      "stamp_icon_type": "icon"
    },
    "partner_name": "Coffee Shop",
    "partner_info": {
      "id": 1,
      "name": "Coffee Shop",
      "description": "Best coffee in town",
      "logo": "https://example.com/logo.png"
    }
  }
}

Example Request

curl -X GET "https://staging-api.loyalty.lt/en/shop/games/1" \
  -H "X-API-Key: your_api_key" \
  -H "X-API-Secret: your_api_secret" \
  -H "Accept: application/json"

SDK Example

import { LoyaltySDK } from '@loyaltylt/sdk';

const sdk = new LoyaltySDK({
  apiKey: 'your_api_key',
  apiSecret: 'your_api_secret',
});

// Get game details
const game = await sdk.getGame(1);
console.log('Game:', game.name);
console.log('Stamps required:', game.stamps_required);