
Gift Codes
Reward players with promotional codes that grant any in-game item or currency
Flexible Reward Payloads
Gift data is free-form JSON, so you can grant any combination of currencies, items, or flags your game understands.
Granular Limits
Set a global redemption cap, a per-user cap, and an expiry date independently for each code.
Revocation Control
Revoke a code instantly from the dashboard if it leaks or is abused, with no app update needed.
Quick Integration
Redeem Code
Enter Gift Code
Enter your promotional code below
WINTER2024
// Unity C#: Gift Codes (needs a signed in player)
using PM.horizOn.Cloud.Manager;
using UnityEngine;
// Validate without redeeming (true, false, or null when the request failed)
bool? valid = await GiftCodeManager.Instance.Validate("SUMMER2025");
// Redeem: giftData is the JSON payload you set in the dashboard
var result = await GiftCodeManager.Instance.Redeem("SUMMER2025");
if (result != null && result.success)
{
Debug.Log($"Rewards: {result.giftData}");
}# REST API: Gift Codes
# Validate a gift code (does not redeem)
curl -X POST https://horizon.pm/api/v1/app/gift-codes/validate \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"userId":"USER_ID","code":"SUMMER2025"}'
# Redeem a gift code (needs the player's session token)
curl -X POST https://horizon.pm/api/v1/app/gift-codes/redeem \
-H "X-API-Key: YOUR_API_KEY" \
-H "Authorization: Bearer SESSION_TOKEN" \
-H "Content-Type: application/json" \
-d '{"userId":"USER_ID","code":"SUMMER2025"}'These examples use the Unity SDK (C#) and the REST API. Godot and Unreal have the same calls in their own SDKs: see the quickstart
Frequently Asked Questions
Ready to Integrate?
Start building with horizOn today. Free tier included.
