Gameball Developers Guide
v4.0
v4.0
  • Introduction
  • Installing Gameball
    • Web
      • Initialize Gameball Customer Widget
      • Track Customer Events
      • Track Orders & Cashback Reward
      • Integrate Redemption
      • Track Referrals
      • Go-Live Checklist
    • iOS
      • Getting Started
      • Initialize Gameball Customer Profile
      • Track Customer Events
      • Track Orders & Cashback Reward
      • Integrate Redemption
      • Push Notifications
      • Track Referrals
      • Go-Live Checklist
    • Android
      • Getting Started
      • Initialize Gameball Customer Profile
      • Track Customer Events
      • Track Orders & Cashback Reward
      • Integrate Redemption
      • Push Notifications
      • Go-Live Checklist
    • React Native
      • Getting Started
      • Initialize Gameball Customer Profile
      • Track Customer Events
      • Track Orders & Cashback Reward
      • Integrate Redemption
      • Track Referrals
      • Push Notifications
      • Go-Live Checklist
    • Flutter
      • Getting Started
      • Initialize Gameball Customer Profile
      • Track Customer Events
      • Track Orders & Cashback Reward
      • Integrate Redemption
      • Track Referrals
      • Go-Live Checklist
    • Generic Mobile App
      • Initialize Gameball Customer Profile
      • Track Customer Events
      • Track Orders & Cashback Reward
      • Integrate Redemption
      • Track Referrals
      • Push Notifications
  • REST API
    • Overview
      • What's New in V4.0
      • Authentication
      • Rate Limiting
      • Status and Error Codes
    • Customers
      • Customer Management
      • Customer Progress
      • Customer Tags
      • Customer Notifications
    • Events
    • Order
      • Order Tracking
      • Order Rewards & History
    • Payment
      • Payment Tracking
    • Transactions
      • Cashback & Redemptions
      • Hold Management
      • Transaction Management
      • Transaction Validation
    • Coupons
    • Configurations
      • Reward Configurations
      • Program Configurations
      • Widget Configuration
    • Leaderboard
    • Batches
      • Batch Creation
      • Batch Management
  • Webhooks
    • Overview
    • Subscribing to Webhooks
    • Webhook Topics
      • Customer's Notifications
      • Customer's Profile Updates
  • Tutorials
    • Tracking Customer Events
    • Redemption Integration
      • Direct debit redemption
      • Coupons Redemption
        • Use Your Own Couponing Engine
        • Gameball Couponing Engine
    • Checkout Integration
    • Build Custom UI Elements
      • Reward Campaigns
      • VIP Tiers
      • Customer Balance
      • Widget Configurations
      • Coupons Customer Experience
      • Customer Notifications
      • Customer Leaderboard
    • Build your Own Notification System
    • Channel Merging Guide
    • Previewing Potential Points Before Purchase
    • Refund
    • Retail & POS Integration with Gameball Loyalty Program
    • Referrals
    • Widget Deep Links
    • Batch APIs usage example
  • Branch.io Integration
  • Adjust Integration
Powered by GitBook
On this page
  • GET - Customer Notifications
  • Request
  • Response
  • GET - Customer Notifications Count
  • Request
  • Response
  • PUT - Mark Customer Notifications as Read
  • Request
  1. REST API
  2. Customers

Customer Notifications

Retrieve and manage customer notifications with these APIs. Use them to display notification lists and mark notifications as read, helping keep customers informed about their rewards and activity.

PreviousCustomer TagsNextEvents

Last updated 5 months ago

Available APIs


GET - Customer Notifications

https://api.gameball.co/api/v4/integrations/customers/{customerId}/notifications

This API retrieves a paged list of notifications for a specific customer in Gameball, identified by customerId. Each notification includes details such as title, message content, read status, and timestamp.

Security: Requires apikey headers.

Request

Path Parameters

customerId string Required Unique identifier for the customer that you can reference across the customer’s whole lifetime. Could be a database ID, random string, email, or anything that uniquely identifies the customer.

Query Parameters

startAfter long Optional Specifies the page will start after which notification id. Defaults to 0.


limit integer Optional Specifies the number of notifications to return per page. Defaults to 50, with a maximum limit of 200 transactions per page.


isRead boolean Optional Filter notifications based on their read status. Set to true for read notifications and false for unread ones


lang string Optional Specifies the the language in which notifications will be retrieved.

Response

application/json

notifications array This array contains the list of notifications sent to the customer. Each notification represents an event or update that happened, based on pre-configured settings from the Gameball dashboard. These notifications are typically used to inform the customer about specific actions such as cashback rewards, point adjustments, tier changes, or campaign achievement. Each object in the array provides details about the notification, such as its content, creation date, and read status.

Example : When a customer receives a cashback reward, the system sends a notification with details about the reward (if you have enabled the cashback reward notification on your dashboard). For example, the title could be "Cashback Reward!" and the body might include "You’ve received a cashback reward for your recent purchase."

Notification Object

notificationId string Unique identifier for the notification.


title string Title of the notification.


body string The content of the notification.


isRead boolean Indicates whether the notification has been read by the customer (true if read, false if unread).


createdAt datetime The timestamp when the notification was created.


lang string Language of the notification.


icon string URL to the icon associated with the notification.It can be displayed alongside the notification message in user interfaces like a mobile app or web dashboard.


count number Number of notifications on the current page.


hasMore boolean Indicating whether there are additional notifications to be fetched beyond the current page.


Sample Response

{
    "notifications": [
        {
            "notificationId": "139944",
            "title": "Points Added!",
            "body": "Your points have been adjusted, your current points balance is 89",
            "isRead": true,
            "createdAt": "0001-01-01T00:00:00",
            "lang": "en",
            "icon": "https://cdn.gameball.co/uploads/Notifications/cachback.webp"
        },
        {
            "notificationId": "152966",
            "title": "Congratulations!",
            "body": "First Order 🛍️ earned. Enjoy your rewards and keep earning more!",
            "isRead": false,
            "createdAt": "0001-01-01T00:00:00",
            "lang": "en",
            "icon": "https://s3.us-east-2.amazonaws.com/gameball.stg.uploads/uploads/gb-library/general/order-01.webp"
        }
    ],
    "count": 2,
    "hasMore": true
}

GET - Customer Notifications Count

https://api.gameball.co/api/v4/integrations/customers/{customerId}/notifications/count

This API retrieves the total count of notifications for a specific customer in Gameball, identified by customerId. It provides the number of notifications matching the specified criteria without returning detailed notification records.

Security: Requires apikey headers.

Request

Path Parameters

customerId string Required Unique identifier for the customer that you can reference across the customer’s whole lifetime. Could be a database ID, random string, email, or anything that uniquely identifies the customer.

Query Parameters

isRead boolean Optional Filter notifications based on their read status. Set to true for read notifications and false for unread ones


lang string Optional Specifies the the language in which notifications will be retrieved.

Response

application/json

count number The total number of notifications available for the customer in Gameball system.


Sample Response

{
    "count": 20
}

PUT - Mark Customer Notifications as Read

https://api.gameball.co/api/v4/integrations/customers/{customerId}/notifications

This API allows you to mark specific notifications as read for a customer in Gameball, identified by customerId. By providing notification IDs, you can update the read status of individual notifications.

Security: Requires apikey and secretkey headers.

Request

Body

application/json


Sample Request

{
  "notificationsIds": [          
    139944                       
  ]
}

notificationsIds array Required An array of notification IDs that you want to mark as read. These notification IDs are retrieved through the endpoint, which returns a list of all notifications sent to the customer. By marking specific notifications as read, you acknowledge that the customer has seen them. This is useful for keeping track of which notifications have been addressed and ensuring a clear customer communication experience.

Get Customer Notifications
Get Customer Notifications Count
Mark Notifications as Read
Get Notifications