# AMBSuperAPI — Seamless Wallet Integration Guide

> Everything needed to integrate the Seamless Wallet: the APIs you call on AMBSuperAPI, and every Product Callback your system must expose.
>
> Generated from the AMBSuperAPI documentation on 2026-12-01. Links starting with `/` are pages of the documentation site.

---

## How the Seamless Wallet works

1. **You call AMBSuperAPI** (Basic Authentication with your agent credentials) to list products/games and to log a player in. See *Part 2*.
2. **AMBSuperAPI calls your system** whenever the player's balance must be read or changed. These are the **Product Callbacks** in *Part 3*. Your server keeps the player's wallet, so it must implement **all** of them.

## Product Callbacks your system must implement

11 callback endpoints, all `POST` with `application/json`, sent to the callback URL configured for your agent (`{YOUR_API_URL}`):

| Callback | Endpoint | Details |
| -------- | -------- | ------- |
| Check Balance | `POST {YOUR_API_URL}/checkBalance` | [/productCallback/gbl.md](/productCallback/gbl.md) |
| Place Bets | `POST {YOUR_API_URL}/placeBets` | [/productCallback/placeBet.md](/productCallback/placeBet.md) |
| Settle Bets | `POST {YOUR_API_URL}/settleBets` | [/productCallback/settlement.md](/productCallback/settlement.md) |
| Cancel Bets | `POST {YOUR_API_URL}/cancelBets` | [/productCallback/refund.md](/productCallback/refund.md) |
| Adjust Bets | `POST {YOUR_API_URL}/adjustBets` | [/productCallback/adjustBets.md](/productCallback/adjustBets.md) |
| Rollback | `POST {YOUR_API_URL}/rollback` | [/productCallback/rollback.md](/productCallback/rollback.md) |
| Win Rewards | `POST {YOUR_API_URL}/winRewards` | [/productCallback/winreward.md](/productCallback/winreward.md) |
| Pay Tips | `POST {YOUR_API_URL}/placeTips` | [/productCallback/tips.md](/productCallback/tips.md) |
| Cancel Tips | `POST {YOUR_API_URL}/cancelTips` | [/productCallback/canceltips.md](/productCallback/canceltips.md) |
| Void Settle | `POST {YOUR_API_URL}/voidSettled` | [/productCallback/voidSettled.md](/productCallback/voidSettled.md) |
| Adjust balance | `POST {YOUR_API_URL}/adjustBalance` | [/productCallback/ajb.md](/productCallback/ajb.md) |

Verifying the request signature is optional but recommended. See [API Signature Verification](/productCallback/signature.md).

## Test with Seamless Testing before going live

Use **Seamless Testing**: https://seamlesstesting.ambsuperapi.com

We recommend going through it before going live. It shows example cases for the callback flows above (place bet, settle, cancel, void settle and the others), so you can compare them with what your callback endpoint receives and returns.

---

# Part 1 — Getting started

---

<!-- source: /introduction.md -->

# Introduction

**AMBSuperAPI** is designed around RESTFUL API. Our API is made for everyone to be able to read and predictable oriented URLs.The AMBSuperAPI allows you to integrate with the various game providers around the world without handling every risk during the integration of the game provider by yourself and **super simple to use**..

**After Start**

When you request the API endpoint these need to use a valid API Key. You can get your API key from the [AMBSuperAPI Agent Profile Page](https://ambsuperapi.com/account/profile)

---

<!-- source: /authentication.md -->

# Authentication

An **API Key** is required to be sent as a part of every request, In the form of [Basic Authentication](https://swagger.io/docs/specification/authentication/basic-authentication/#:~:text=Basic%20authentication%20is%20a%20simple,55w0rd%20the%20client%20would%20send)
in the request header,

## API Server

### Production

```
https://api.hentory.io
```

### Staging

```
https://test.ambsuperapi.com
```

## How Authentication Works

AMBSuperAPI uses Basic Authentication with your agent credentials. You need to:

1. Get your API key from the [AMBSuperAPI Agent Profile Page](https://ambsuperapi.com/account/profile)
2. Encode your credentials using Base64 format: `Base64(agent_username:x-api-key)`
3. Include the encoded credentials in the Authorization header.

## Authorization Header Format

```
Authorization: Basic Base64({{ agent_username }}:{{ x-api-key }})
```

## Example

If your agent username is `agent001` and your API key is `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx`, you would:

1. Create the string: `agent001:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx`
2. Encode it with Base64: `YWdlbnQwMDE6eHh4eHh4eHgteHh4eC14eHh4LXh4eHgteHh4eHh4eHh4eHh4`
3. Use it in the header: `Authorization: Basic YWdlbnQwMDE6eHh4eHh4eHgteHh4eC14eHh4LXh4eHgteHh4eHh4eHh4eHh4`

**API Key related error response**

If an API Key is missing, malformed, or invalid, you will receive a `401 Unauthorised response code` and the following JSON response:

```json
{
  "reqId": "edba5aca-d6d8-4e10-a55e-971cc3facb0b",
  "code": 401,
  "exception": {
    "response": {
      "statusCode": 401,
      "message": "Unauthorized. Invalid API key: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "error": "Unauthorized"
    },
    "status": 401,
    "message": "Unauthorized. Invalid API key: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
  },
  "message": {
    "statusCode": 401,
    "message": "Unauthorized. Invalid API key: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "error": "Unauthorized"
  }
}
```

---

# Part 2 — Seamless APIs (you call AMBSuperAPI)

---

<!-- source: /seamless/introduction.md -->

**Let's play**

1. First, Create a member/gambler on the product that you want in the above [Product List](/api-reference.md#product-lists))
2. Login and get a URL to play the game and turn into a millionire

---

<!-- source: /seamless/getProducts.md -->

## Get Products `GET`

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/products
```

### Content Type

Type: `application/json`

### Response Description

| Property  | Type     | Required | Description                               |
| --------- | -------- | -------- | ----------------------------------------- |
| `reqId`   | string   | Required | Unique reference for each request         |
| `code`    | number   | Required | Response status                           |
| `message` | string   | Required | Additional information on response status |
| `data`    | string\[] | Required | Query products data                       |

> JSON response example:

```json
{
  "reqId": "4aad4623-a7ff-4757-828b-d396b84f7bb5",
  "code": 0,
  "message": "Success",
  "data": [
    "SPADE",
    "PRETTY",
    "CG",
    "MANNA",
    "JILI",
    ...
  ]
}
```

---

<!-- source: /seamless/listGames.md -->

## List Games `GET`

This api is use for get game lists.
**Please use field `code` to login in field `gameCode`**

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/games?productId={{ productId }}
```

### Content Type

Type: `application/json`

### Parameter Description

| Property    | Type   | Required | Description                                                                             |
| ----------- | ------ | -------- | --------------------------------------------------------------------------------------- |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `SEXY`) |

### Response Description

| Property  | Type                          | Required | Description                               |
| --------- | ----------------------------- | -------- | ----------------------------------------- |
| `reqId`   | string                        | Required | Unique reference for each request         |
| `code`    | number                        | Required | Response status                           |
| `message` | string                        | Required | Additional information on response status |
| `data`    | [GameData](/seamless/listGames.md#query-games-data) | Required | Query games data                          |

### Query Games Data

| Property       | Type                              | Required | Description           |
| -------------- | --------------------------------- | -------- | --------------------- |
| `name`         | string                            | Optional | Game Name             |
| `category`     | string                            | Required | Game Category         |
| `type`         | string                            | Required | Game Type             |
| `code`         | string                            | Required | Game Id               |
| `img`          | string                            | Required | Game Image            |
| `rank`         | number                            | Required | Rank of game          |
| `providerCode` | string                            | Optional | Game Code of Provider |
| `locale`       | [Language Lists](/seamless/listGames.md#language-lists) | Optional | language of names     |

### Language Lists

| Property | Type   | Required | Description       |
| -------- | ------ | -------- | ----------------- |
| `TH`     | string | Optional | Thai Game name    |
| `EN`     | string | Optional | English Game name |
| `CN`     | string | Optional | Chinese Game name |

> JSON response example:

```json
{
  "reqId": "bcf4a1d9-2374-460d-bf02-94ae8547851a",
  "code": 0,
  "message": "Success",
  "data": {
    "games": [
      {
        "name": "Candy’s Bonanza",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_candysbonanza",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_candysbonanza.png",
        "rank": 1,
        "locale": {
          "en": "Candy’s Bonanza",
          "th": "Candy’s Bonanza",
          "cn": "糖果盛宴"
        }
      },
      {
        "name": "Wild West Spirit",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_wildwestspirit",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_wildwestspirit.png",
        "rank": 2,
        "locale": {
          "en": "Wild West Spirit",
          "th": "Wild West Spirit",
          "cn": "西部狂野精神"
        }
      },
      {
        "name": "Rich Panda",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_richpanda",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_richpanda.png",
        "rank": 3,
        "locale": {
          "en": "Rich Panda",
          "th": "Rich Panda",
          "cn": "财富熊猫"
        }
      },
      {
        "name": "Beach Penalties",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_beachpenalties",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_beachpenalties.png",
        "rank": 4,
        "locale": {
          "en": "Beach Penalties",
          "th": "Beach Penalties",
          "cn": "Beach Penalties"
        }
      },
      {
        "name": "Maya‘s Treasure",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_mayastreasure",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_mayastreasure.png",
        "rank": 5,
        "locale": {
          "en": "Maya‘s Treasure",
          "th": "Maya‘s Treasure",
          "cn": "玛雅的宝藏"
        }
      },
      {
        "name": "Lucky‘s Betting Shop",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_luckysbettingshop",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_luckysbettingshop.png",
        "rank": 6,
        "locale": {
          "en": "Lucky‘s Betting Shop",
          "th": "Lucky‘s Betting Shop",
          "cn": "幸运的博彩店"
        }
      },
      {
        "name": "Super Heli",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_superheli",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_superheli.png",
        "rank": 7,
        "locale": {
          "en": "Super Heli",
          "th": "Super Heli",
          "cn": "超级直升机"
        }
      },
      {
        "name": "Win & Go",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_wingo",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_wingo.png",
        "rank": 8,
        "locale": {
          "en": "Win & Go",
          "th": "Win & Go",
          "cn": "赢并走"
        }
      },
      {
        "name": "Shaolin Crew",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_shaolincrew",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_shaolincrew.png",
        "rank": 9,
        "locale": {
          "en": "Shaolin Crew",
          "th": "Shaolin Crew",
          "cn": "少林团队"
        }
      },
      {
        "name": "Zombie Apocalypse",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_zombieapocalypse",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_zombieapocalypse.png",
        "rank": 10,
        "locale": {
          "en": "Zombie Apocalypse",
          "th": "Zombie Apocalypse",
          "cn": "僵尸启示录"
        }
      },
      {
        "name": "Veni Vidi Vici",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_venividivici",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_venividivici.png",
        "rank": 11,
        "locale": {
          "en": "Veni Vidi Vici",
          "th": "Veni Vidi Vici",
          "cn": "我来了，我看见了，我征服了"
        }
      },
      {
        "name": "Joker Poker",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_jokerpoker",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_jokerpoker.png",
        "rank": 12,
        "locale": {
          "en": "Joker Poker",
          "th": "Joker Poker",
          "cn": "小丑扑克"
        }
      },
      {
        "name": "Leprechaun Wish",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_leprechaunwish",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_leprechaunwish.png",
        "rank": 13,
        "locale": {
          "en": "Leprechaun Wish",
          "th": "Leprechaun Wish",
          "cn": "精灵的愿望"
        }
      },
      {
        "name": "Bounty Hunters",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_bountyhunters",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_bountyhunters.png",
        "rank": 14,
        "locale": {
          "en": "Bounty Hunters",
          "th": "Bounty Hunters",
          "cn": "赏金猎人"
        }
      },
      {
        "name": "Sticky777",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_sticky777",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_sticky777.png",
        "rank": 15,
        "locale": {
          "en": "Sticky777",
          "th": "Sticky777",
          "cn": "粘粘777"
        }
      },
      {
        "name": "Pia",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_pia",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_pia.png",
        "rank": 16,
        "locale": {
          "en": "Pia",
          "th": "Pia",
          "cn": "皮娅"
        }
      },
      {
        "name": "Wild White Whale",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_wildwhitewhale",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_wildwhitewhale.png",
        "rank": 17,
        "locale": {
          "en": "Wild White Whale",
          "th": "Wild White Whale",
          "cn": "野性白鲸"
        }
      },
      {
        "name": "God of Coins",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_godofcoins",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_godofcoins.png",
        "rank": 18,
        "locale": {
          "en": "God of Coins",
          "th": "God of Coins",
          "cn": "硬币之神"
        }
      },
      {
        "name": "Spinning Buddha",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_spinningbuddha",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_spinningbuddha.png",
        "rank": 19,
        "locale": {
          "en": "Spinning Buddha",
          "th": "Spinning Buddha",
          "cn": "旋转佛陀"
        }
      },
      {
        "name": "Planets Power",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_planetspower",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_planetspower.png",
        "rank": 20,
        "locale": {
          "en": "Planets Power",
          "th": "Planets Power",
          "cn": "行星之力"
        }
      },
      {
        "name": "Fortune Farm",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_fortunefarm",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_fortunefarm.png",
        "rank": 21,
        "locale": {
          "en": "Fortune Farm",
          "th": "Fortune Farm",
          "cn": "幸运农场"
        }
      },
      {
        "name": "Pirates Power",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_piratespower",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_piratespower.png",
        "rank": 22,
        "locale": {
          "en": "Pirates Power",
          "th": "Pirates Power",
          "cn": "海盗之力"
        }
      },
      {
        "name": "Capital City Derby",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_capitalcityderby",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_capitalcityderby.png",
        "rank": 23,
        "locale": {
          "en": "Capital City Derby",
          "th": "Capital City Derby",
          "cn": "首都城市德比"
        }
      },
      {
        "name": "Book of Egypt",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_bookofegypt",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_bookofegypt.png",
        "rank": 24,
        "locale": {
          "en": "Book of Egypt",
          "th": "Book of Egypt",
          "cn": "埃及之书"
        }
      },
      {
        "name": "Wild Icy Fruits",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_wildicyfruits",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_wildicyfruits.png",
        "rank": 25,
        "locale": {
          "en": "Wild Icy Fruits",
          "th": "Wild Icy Fruits",
          "cn": "冰冷水果"
        }
      },
      {
        "name": "The Book of Eskimo",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_thebookofeskimo",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_thebookofeskimo.png",
        "rank": 26,
        "locale": {
          "en": "The Book of Eskimo",
          "th": "The Book of Eskimo",
          "cn": "爱斯基摩之书"
        }
      },
      {
        "name": "Battle For The Throne",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_battleforthethrone",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_battleforthethrone.png",
        "rank": 27,
        "locale": {
          "en": "Battle For The Throne",
          "th": "Battle For The Throne",
          "cn": "王座之战"
        }
      },
      {
        "name": "Odd One Out",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_oddoneout",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_oddoneout.png",
        "rank": 28,
        "locale": {
          "en": "Odd One Out",
          "th": "Odd One Out",
          "cn": "异类"
        }
      },
      {
        "name": "Forest Rock",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_forestrock",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_forestrock.png",
        "rank": 29,
        "locale": {
          "en": "Forest Rock",
          "th": "Forest Rock",
          "cn": "森林摇滚"
        }
      },
      {
        "name": "Wild Corrida",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_wildcorrida",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_wildcorrida.png",
        "rank": 30,
        "locale": {
          "en": "Wild Corrida",
          "th": "Wild Corrida",
          "cn": "野牛竞技"
        }
      },
      {
        "name": "Piggy Party",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_piggyparty",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_piggyparty.png",
        "rank": 31,
        "locale": {
          "en": "Piggy Party",
          "th": "Piggy Party",
          "cn": "小猪派对"
        }
      },
      {
        "name": "Fairy in Wonderland",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_fairyinwonderland",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_fairyinwonderland.png",
        "rank": 32,
        "locale": {
          "en": "Fairy in Wonderland",
          "th": "Fairy in Wonderland",
          "cn": "仙境中的仙女"
        }
      },
      {
        "name": "Clown Fever",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_circusfever",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_circusfever.png",
        "rank": 33,
        "locale": {
          "en": "Clown Fever",
          "th": "Clown Fever",
          "cn": "小丑热潮"
        }
      },
      {
        "name": "Casino Heist",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_casinoheist",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_casinoheist.png",
        "rank": 34,
        "locale": {
          "en": "Casino Heist",
          "th": "Casino Heist",
          "cn": "赌场抢劫"
        }
      },
      {
        "name": "Crazy Horses",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_crazyhorses",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_crazyhorses.png",
        "rank": 35,
        "locale": {
          "en": "Crazy Horses",
          "th": "Crazy Horses",
          "cn": "疯狂的马"
        }
      },
      {
        "name": "Swipe",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_swipe",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_swipe.png",
        "rank": 36,
        "locale": {
          "en": "Swipe",
          "th": "Swipe",
          "cn": "滑动"
        }
      },
      {
        "name": "Evoji",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_evoji",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_evoji.png",
        "rank": 37,
        "locale": {
          "en": "Evoji",
          "th": "Evoji",
          "cn": "表情符号"
        }
      },
      {
        "name": "Digits",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_digits",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_digits.png",
        "rank": 38,
        "locale": {
          "en": "Digits",
          "th": "Digits",
          "cn": "数字"
        }
      },
      {
        "name": "Dice Mini",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_dicemini",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_dicemini.png",
        "rank": 39,
        "locale": {
          "en": "Dice Mini",
          "th": "Dice Mini",
          "cn": "迷你骰子"
        }
      },
      {
        "name": "Dots Racing",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_dotsracing",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_dotsracing.png",
        "rank": 40,
        "locale": {
          "en": "Dots Racing",
          "th": "Dots Racing",
          "cn": "圆点赛跑"
        }
      },
      {
        "name": "Wheel",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_wheel",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_wheel.png",
        "rank": 41,
        "locale": {
          "en": "Wheel",
          "th": "Wheel",
          "cn": "轮盘"
        }
      },
      {
        "name": "Keno",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_keno",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_keno.png",
        "rank": 42,
        "locale": {
          "en": "Keno",
          "th": "Keno",
          "cn": "基诺"
        }
      },
      {
        "name": "Gem Miner",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_gemminer",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_gemminer.png",
        "rank": 43,
        "locale": {
          "en": "Gem Miner",
          "th": "Gem Miner",
          "cn": "宝石矿工"
        }
      },
      {
        "name": "Clown Fever Deluxe",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_circusfeverdeluxe",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_circusfeverdeluxe.png",
        "rank": 44,
        "locale": {
          "en": "Clown Fever Deluxe",
          "th": "Clown Fever Deluxe",
          "cn": "小丑热潮豪华版"
        }
      },
      {
        "name": "Magic Wheel",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_magicwheel",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_magicwheel.png",
        "rank": 45,
        "locale": {
          "en": "Magic Wheel",
          "th": "Magic Wheel",
          "cn": "魔法轮盘"
        }
      },
      {
        "name": "Sic Bo",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_sicbo",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_sicbo.png",
        "rank": 46,
        "locale": {
          "en": "Sic Bo",
          "th": "Sic Bo",
          "cn": "骰宝"
        }
      },
      {
        "name": "HiLo",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_hilo",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_hilo.png",
        "rank": 47,
        "locale": {
          "en": "HiLo",
          "th": "HiLo",
          "cn": "高低"
        }
      },
      {
        "name": "Titan Dice",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_titandice",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_titandice.png",
        "rank": 48,
        "locale": {
          "en": "Titan Dice",
          "th": "Titan Dice",
          "cn": "泰坦骰子"
        }
      },
      {
        "name": "Diamond Blackjack",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_diamondblackjack",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_diamondblackjack.png",
        "rank": 49,
        "locale": {
          "en": "Diamond Blackjack",
          "th": "Diamond Blackjack",
          "cn": "钻石二十一点"
        }
      },
      {
        "name": "Titan Roulette",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_titanroulette",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_titanroulette.png",
        "rank": 50,
        "locale": {
          "en": "Titan Roulette",
          "th": "Titan Roulette",
          "cn": "泰坦轮盘"
        }
      },
      {
        "name": "Mini Roulette",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_miniroulette",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_miniroulette.png",
        "rank": 51,
        "locale": {
          "en": "Mini Roulette",
          "th": "Mini Roulette",
          "cn": "迷你轮盘"
        }
      },
      {
        "name": "Titan Roulette Deluxe",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_titanroulettedeluxe",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_titanroulettedeluxe.png",
        "rank": 52,
        "locale": {
          "en": "Titan Roulette Deluxe",
          "th": "Titan Roulette Deluxe",
          "cn": "泰坦轮盘豪华版"
        }
      },
      {
        "name": "Pixel Poker",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_pixelpoker",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_pixelpoker.png",
        "rank": 53,
        "locale": {
          "en": "Pixel Poker",
          "th": "Pixel Poker",
          "cn": "像素扑克"
        }
      },
      {
        "name": "Deuces Wild",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_deuceswild",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_deuceswild.png",
        "rank": 54,
        "locale": {
          "en": "Deuces Wild",
          "th": "Deuces Wild",
          "cn": "两张狂野"
        }
      },
      {
        "name": "Pinata Loca",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "expanse_pinataloca",
        "img": "https://superapi-products.s3-ap-southeast-1.amazonaws.com/EXPANSE/expanse_pinataloca.png",
        "rank": 55,
        "locale": {
          "en": "Pinata Loca",
          "th": "Pinata Loca",
          "cn": "疯狂皮纳塔"
        }
      }
    ]
  }
}
```

---

<!-- source: /seamless/listFreegames.md -->

## List Freegames `GET`

This api is use for get free game lists.
**Please use field `code` to login in field `gameCode`**

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/freeGameList?productId={{ productId }}
```

### Content Type

Type: `application/json`

### Parameter Description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response Description

| Property  | Type                          | Required | Description                               |
| --------- | ----------------------------- | -------- | ----------------------------------------- |
| `reqId`   | string                        | Required | Unique reference for each request         |
| `code`    | number                        | Required | Response status                           |
| `message` | string                        | Required | Additional information on response status |
| `data`    | [GameData](/seamless/listFreegames.md#query-games-data) | Required | Query games data                          |

### Query Games Data

| Property       | Type   | Required | Description           |
| -------------- | ------ | -------- | --------------------- |
| `name`         | string | Optional | Game Name             |
| `category`     | string | Required | Game Category         |
| `type`         | string | Required | Game Type             |
| `code`         | string | Required | Game Id               |
| `img`          | string | Required | Game Image            |
| `rank`         | number | Required | Rank of game          |
| `providerCode` | string | Optional | Game Code of Provider |

> JSON response example:

```json
{
  "reqId": "91ffb817-1f8e-4608-a86d-472dddc2eed7",
  "code": 0,
  "message": "Success",
  "data": {
    "games": [
      {
        "name": "games",
        "category": "EGAMES",
        "type": "SLOT",
        "code": "games",
        "img": "https://img",
        "rank": 1,
        "providerCode": "1"
      }
    ]
  }
}
```

---

<!-- source: /seamless/login.md -->

## Login `POST`

This api is use for enter to the game.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
POST {{ API_URL }}/seamless/logIn
```

### Content Type

Type: `application/json`

### Parameter Description

| Property        | Type    | Required | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| --------------- | ------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `username`      | string  | Required | Member username                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| `productId`     | string  | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `SEXY`)                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `gameCode`      | string  | Required | Game code of product (Example : BAC)                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `isMobileLogin` | boolean | Required | Mobile Mode (Example : true)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `limit`         | number  | Optional | Player's bet limits [Betlimit List](/seamless/getBetLimits.md)                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `sessionToken`  | string  | Required | SessionToken generate by Operator. Note: In some products, provider didn't support the same token when player had login many times. So, please try to change the `sessionToken` regulary, if you found an error abnormally. <br/><span style="color:red">**Note:** Some products has a maximum length of `sessionToken` if you found some callback remove your `sessionToken` length or sent to your system with some part of your provided `sessionToken`, please try to reduce `sessionToken` length.</span> |
| `currency`      | string  | Optional | Login currency, please specify if you need to select the currency (Default value based on agent)                                                                                                                                                                                                                                                                                                                                                                                                               |
| `language`      | string  | Optional | Language Code default `th` [Language List](/seamless/login.md#language-lists) (Example : th)                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `callbackUrl`   | string  | Optional | Exit url, url that you need to redirect if player quit the game from Game GUI.                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `betLimit`      | any\[]   | Optional | Values are depended on productId, please refer to each product in callbacks section for more details                                                                                                                                                                                                                                                                                                                                                                                                           |

> Request Body

```json
{
  "username": "test00001",
  "productId": "PRETTY",
  "gameCode": "BAC",
  "isMobileLogin": true,
  "limit": 1,
  "sessionToken": "d4be70d1-349f-4fc1-a955-35d2a4bff244",
  "betLimit": []
}
```

> JSON response example:

```json
{
  "reqId": "5557191a-4421-4753-a757-8ca7b45828dc",
  "code": 0,
  "message": "Success",
  "data": {
    "url": "https://test.ambsuperapi.com/seamless/directLogin?token={{ LOGIN_TOKEN }}"
  }
}
```

---

<!-- source: /seamless/customBetLimit.md -->

## Custom bet-limit config

`Optional`: If you need to custom bet-limit (mostly for Sport-type products), please following this setup parameters.
Due to the complexity of setup parameters in some products, we have to separates the custom parameters for your login's parameters request.

The following products supports these custom setup:

| ProductID      | Product name  |
| -------------- | ------------- |
| `AMBSPORTBOOK` | AMB Sportbook |
| `LALIKA`       | Lalika        |
| `AFB1188`      | AFB1188 Sport |
| `SABASPORTS`   | Saba Sport    |
| `SBO`          | Sbobet        |
| `GA28`         | GA28          |
| `MUAYPAKYOK`   | Muaypakyok    |
| `UFABET`       | Ufabet+       |
| `UMBET`        | Umbet         |

The description and example for each products:

### Product: LALIKA, AFB1188, SABASPORTS

```json
{
  "betLimit": [
    {
      "sport_type": 0,
      "market_type": 0,
      "min_bet": 5,
      "max_bet": 500,
      "max_bet_per_match": 100000
    }
  ]
}
```

### Request parameter description

| Property            | Type   | Required | Description                           |
| ------------------- | ------ | -------- | ------------------------------------- |
| `sport_type`        | number | Required | [Sport type code.](/seamless/customBetLimit.md#amb-sport-type)   |
| `market_type`       | number | Required | [Market type code.](/seamless/customBetLimit.md#amb-market-type) |
| `min_bet`           | number | Required | Minimum bet amount daily.             |
| `max_bet`           | number | Required | Maximum bet amount daily.             |
| `max_bet_per_match` | number | Required | Maximum bet amount per match.         |

### Product: GA28

```json
{
  "betLimit": [
    {
      "max_bet": 500,
      "draw_max_bet": 500,
      "limit_num_ticket": null
    }
  ]
}
```

### Request parameter description

| Property           | Type   | Required | Description                    |
| ------------------ | ------ | -------- | ------------------------------ |
| `max_bet`          | number | Required | Maximum bet amount daily.      |
| `draw_max_bet`     | number | Required | Maximum draw bet amount daily. |
| `limit_num_ticket` | number | Required | Maximum bet amount per match.  |

### Product: SBO

```json
{
  "betLimit": [
    {
      "sport_type": 0,
      "market_type": 0,
      "min_bet": 5,
      "max_bet": 500,
      "max_bet_per_match": 100000
    }
  ]
}
```

### Request parameter description

| Property            | Type   | Required | Description                           |
| ------------------- | ------ | -------- | ------------------------------------- |
| `sport_type`        | number | Required | [Sport type code.](/seamless/customBetLimit.md#sbo-sport-type)   |
| `market_type`       | number | Required | [Market type code.](/seamless/customBetLimit.md#sbo-market-type) |
| `min_bet`           | number | Required | Minimum bet amount daily.             |
| `max_bet`           | number | Required | Maximum bet amount daily.             |
| `max_bet_per_match` | number | Required | Maximum bet amount per match.         |

### Sport Type {#sbo-sport-type}

| SportType | Description        |
| --------- | ------------------ |
| `0`       | ALL                |
| `1`       | Soccer             |
| `2`       | Basketball         |
| `3`       | Football           |
| `4`       | Ice Hockey         |
| `5`       | Badminton          |
| `6`       | Pool               |
| `7`       | Motor Sport        |
| `8`       | Tennis             |
| `9`       | Baseball           |
| `10`      | Volleyball         |
| `11`      | Others             |
| `12`      | Golf               |
| `13`      | Boxing             |
| `14`      | Cricket            |
| `15`      | Table Tennis       |
| `16`      | Rugby              |
| `17`      | Handball           |
| `18`      | Cycling            |
| `19`      | Athletics          |
| `20`      | Beach_Soccer       |
| `21`      | Futsal             |
| `22`      | Entertainment      |
| `23`      | Financial          |
| `24`      | Darts              |
| `25`      | Olympic            |
| `26`      | Lacrosse           |
| `27`      | Water Polo         |
| `28`      | Winter Sports      |
| `29`      | Squash             |
| `30`      | Field_Hockey       |
| `31`      | Mixed_Martial_Arts |
| `32`      | E_Sports           |
| `33`      | Gaelic_Football    |
| `34`      | Hurling            |
| `35`      | Muay_Thai          |
| `36`      | Bandy              |
| `37`      | Winter_Olympics    |

### Market Type {#sbo-market-type}

| SportTypeId | Description           |
| ----------- | --------------------- |
| `0`         | ALL                   |
| `1`         | Handicap              |
| `2`         | Odd/Even              |
| `3`         | Over/Under            |
| `4`         | Correct Score         |
| `5`         | 1X2                   |
| `6`         | Total Goal            |
| `7`         | First Half Hdp        |
| `8`         | First Half 1x2        |
| `9`         | First Half O/U        |
| `10`        | HT/FT                 |
| `11`        | Money Line            |
| `12`        | First Half O/E        |
| `13`        | First Goal/Last Goal  |
| `14`        | First Half CS         |
| `15`        | Double Chance         |
| `16`        | Live Score            |
| `17`        | First Half Live Score |
| `39`        | Outright              |
| `40`        | Mix Parlay            |
| `666`       | In Between            |
| `800000`    | First Half 1X2 & O/U  |
| `800001`    | D/C & First Half O/U  |
| `900000`    | 1X2 & O/U             |
| `900001`    | D/C & O/U             |
| `800002`    | First Half RCS        |
| `900002`    | Reverse Correct Score |

### Product: AMBSPORTBOOK

```json
{
  "betLimit": [
    {
      "sport_type": 0,
      "market_type": 1,
      "min_bet": 5,
      "max_bet": 500,
      "max_bet_per_match": 100000
    }
  ]
}
```

### Request parameter description

| Property            | Type   | Required | Description                           |
| ------------------- | ------ | -------- | ------------------------------------- |
| `sport_type`        | number | Required | [Sport type code.](/seamless/customBetLimit.md#amb-sport-type)   |
| `market_type`       | number | Required | [Market type code.](/seamless/customBetLimit.md#amb-market-type) |
| `min_bet`           | number | Required | Minimum bet amount daily.             |
| `max_bet`           | number | Required | Maximum bet amount daily.             |
| `max_bet_per_match` | number | Required | Maximum bet amount per match.         |

### Sport Type {#amb-sport-type}

| SportType | Description |
| --------- | ----------- |
| `0`       | ALL         |

### Market Type {#amb-market-type}

| SportTypeId | Description           |
| ----------- | --------------------- |
| `1`         | Handicap              |
| `2`         | Odd/Even              |
| `3`         | Over/Under            |
| `5`         | 1X2                   |
| `7`         | First Half Hdp        |
| `8`         | First Half 1x2        |
| `9`         | First Half O/U        |
| `10`        | Money Line            |
| `11`        | First half Money Line |

### Product: MUAYPAKYOK

```json
{
  "betLimit": [
    {
      "sport_type": 0,
      "market_type": 0,
      "min_bet": 5,
      "max_bet": 500,
      "max_bet_per_match": 100000,
      "min_bet_step": 5,
      "max_bet_step": 500,
      "max_bet_per_match_step": 100000
    }
  ]
}
```

| Property                 | Type   | Required | Description                                             |
| ------------------------ | ------ | -------- | ------------------------------------------------------- |
| `sport_type`             | number | Required | [Sport type code.](/seamless/customBetLimit.md#amb-sport-type)                     |
| `market_type`            | number | Required | [Market type code.](/seamless/customBetLimit.md#amb-market-type)                   |
| `min_bet`                | number | Required | Minimum bet amount. (value: 10)                         |
| `max_bet`                | number | Required | Maximum bet amount. (value: up to 1,000)                |
| `max_bet_per_match`      | number | Required | Maximum bet amount per match. (value: up to 1,000)      |
| `min_bet_step`           | number | Required | Minimum bet step amount per times. (value: 10)          |
| `max_bet_step`           | number | Required | Maximum bet step amount per times. (value: up to 1,000) |
| `max_bet_per_match_step` | number | Required | Maximum bet step amount per bill. (value: up to 1,000)  |

### Product: UFABET

```json
{
  "betLimit": [
    {
      "min_bet": 30,
      "max_bet": 10000
    }
  ]
}
```

### Request parameter description

The min/max bet limit settings has to be within the range of product system

| Property  | Type   | Required | Description                                   |
| --------- | ------ | -------- | --------------------------------------------- |
| `min_bet` | number | Required | Minimum bet of transaction, by default is 30. |
| `max_bet` | number | Required | Maximum bet of transaction.                   |

### Product: UMBET

```json
{
  "betLimit": [
    {
      "max_bet": 10,
      "max_bet_per_match": 10
    }
  ]
}
```

### Request parameter description

The min/max bet limit settings has to be within the range of product system

| Property            | Type   | Required | Description                                          |
| ------------------- | ------ | -------- | ---------------------------------------------------- |
| `max_bet`           | number | Required | Maximum bet of transaction. (value: up to 850,000)   |
| `max_bet_per_match` | number | Required | Maximum bet amount per match. (value: up to 944,440) |

---

<!-- source: /seamless/queryBetRecords.md -->

## Query Bet Records `GET`

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/betTransactionsV2?productId={{ productId }}&date={{ date }}&nextId={{ nextId }}
```

<span style="color:red">**Note:** there's a high chance of request timeout when using this variant. If there's a request timeout, please consider querying by range instead.</span><br>

OR

### HTTP Request

```
GET {{ API_URL }}/seamless/betTransactionsV2?productId={{ productId }}&startTime={{ startTime }}&endTime={{ endTime }}&nextId={{ nextId }}
```

<span style="color:red">**Note:** query range should not be greater than 1 hour. If there's a request timeout, please reduce query range.</span><br>

### Parameter Description

| Property    | Type   | Required | Description                                                                             |
| ----------- | ------ | -------- | --------------------------------------------------------------------------------------- |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `SEXY`) |
| `date`      | string | Optional | Date in format yyyy-MM-dd                                                               |
| `startTime` | string | Optional | Date-time in ISO 8601 format eg 2013-07-16T19:23:51Z                                    |
| `endTime`   | string | Optional | Date-time in ISO 8601 format eg 2013-07-16T19:23:51Z                                    |
| `nextId`    | string | Optional | Taken from previous chunk response, indicating the start of requesting chunk            |

### Response Description

| Property  | Type                                 | Required | Description                               |
| --------- | ------------------------------------ | -------- | ----------------------------------------- |
| `reqId`   | string                               | Required | Unique reference for each request         |
| `code`    | number                               | Required | Response status                           |
| `message` | string                               | Required | Additional information on response status |
| `data`    | [QueryBetDataV2](/seamless/queryBetRecords.md#query-bet-data-v2) | Required | Query bet data                            |

### Query Bet Data V2

| Property | Type          | Required | Description                                                                           |
| -------- | ------------- | -------- | ------------------------------------------------------------------------------------- |
| `nextId` | string        | Optional | Id indicating the start of next chunk (If not present it means there's no next chunk) |
| `txns`   | [Txn\[\]](/seamless/queryBetRecords.md#txn) | Required | Payout status (LOSE, WIN, DRAW, UNKNOWN)                                              |

***

### Txn

| Property         | Type   | Required | Description                                 |
| ---------------- | ------ | -------- | ------------------------------------------- |
| `id`             | string | Required | Transaction id                              |
| `betId`          | string | Required | Unique bet id on each user                  |
| `username`       | string | Required | Username                                    |
| `currency`       | string | Required | ISO 4217 currency code                      |
| `accountingDate` | string | Required | Settlement time                             |
| `updatedDate`    | string | Required | Latest update time                          |
| `stake`          | number | Required | Stake amount                                |
| `payout`         | number | Required | Payout amount (including stake)             |
| `productId`      | string | Required | Product id                                  |
| `gameCode`       | string | Required | Game code                                   |
| `gameName`       | string | Required | Game name                                   |
| `roundId`        | string | Required | Round id                                    |
| `betStatus`      | string | Required | Bet status (OPEN, SETTLED, UNSETTLED, VOID) |
| `payoutStatus`   | string | Required | Payout status (LOSE, WIN, DRAW, UNKNOWN)    |

> JSON response example:

```json
{
  "reqId": "afd71177-960f-4669-90ed-8a34eed3d7d3",
  "code": 0,
  "message": "Success",
  "data": {
    "nextId": "613af94ce2d30c10be22dc6b",
    "txns": [
      {
        "id": "613af94ce2d30c10be22dc06",
        "betId": "21352670",
        "username": "tor0002",
        "currency": "THB",
        "accountingDate": "2021-09-10T06:20:06.000+00:00",
        "updatedDate": "2021-09-10T06:20:06.000+00:00",
        "stake": 40,
        "payout": 30,
        "productId": "SIMPLEPLAY",
        "gameCode": "EG-SLOT-A044",
        "gameName": "Bomber Squad",
        "roundId": "4500052193296",
        "betStatus": "SETTLED",
        "payoutStatus": "LOSE"
      },
      {
        "id": "613af94ce2d30c10be22dc34",
        "betId": "21352676",
        "username": "tor0002",
        "currency": "THB",
        "accountingDate": "2021-09-10T06:20:20.000+00:00",
        "updatedDate": "2021-09-10T06:20:20.000+00:00",
        "stake": 40,
        "payout": 15,
        "productId": "SIMPLEPLAY",
        "gameCode": "EG-SLOT-A044",
        "gameName": "Bomber Squad",
        "roundId": "4500085747728",
        "betStatus": "SETTLED",
        "payoutStatus": "LOSE"
      }
    ]
  }
}
```

---

<!-- source: /seamless/queryReplay.md -->

## Query Replay `GET`

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/betTransactionReplay?productId={{ productId }}&username={{ username }}&betId={{ betId }}&parentBetId={{ parentBetId }}&gameCode={{ gameCode }}
```

### Parameter Description

| Property      | Type   | Required | Description                                                                                                             |
| ------------- | ------ | -------- | ----------------------------------------------------------------------------------------------------------------------- |
| `productId`   | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `SEXY`)                                 |
| `betId`       | string | Required | Bet ID                                                                                                                  |
| `username`    | string | Required | Member username                                                                                                         |
| `parentBetId` | string | Optional | Parent bet ID, if productId: `PGSOFT` this field is required and you need to send `roundId` (in format xxxx-xxxx-106-0) |
| `gameCode`    | string | Optional | Parent bet ID, if productId: `PGSOFT` this field is required and you need to send `gameCode` (in format `lucky-neko`)   |

### Response Description

| Property  | Type                         | Required | Description                               |
| --------- | ---------------------------- | -------- | ----------------------------------------- |
| `reqId`   | string                       | Required | Unique reference for each request         |
| `code`    | number                       | Required | Response status                           |
| `message` | string                       | Required | Additional information on response status |
| `data`    | [QueryReplay](/seamless/queryReplay.md#query-replay) | Required | Query replay data                         |

### Query Replay

| Property | Type   | Required | Description |
| -------- | ------ | -------- | ----------- |
| `url`    | string | Required | Replay url  |

### `Note` Products not have Replay

| Product ID   | Product Name   |
| ------------ | -------------- |
| `SIMPLEPLAY` | Simple Play    |
| `AGGAME`     | Asia Gaming AG |
| `EVOPLAY`    | Evoplay        |
| `ALLBET`     | Allbet         |
| `GOLDY`      | Goldy          |

> JSON response example:

```json
{
  "reqId": "7ba79e9c-ebaf-4f06-bd73-d8648ec7f8d3",
  "code": 0,
  "message": "Success",
  "data": {
    "url": "https://ttt.worldcdn-mega.com/page/wallet/replay.jsp?platform=SEXYBCRT&gameType=LIVE&roundId=Mexico-705-GA25440063&path=https%3A%2F%2Fbfsiz6.bikimex.net%2Ftoken%2Fresult%2Freplay.jsp%3Ftoken%3D4i9oFD7dThHHWUNgOxt4BdyvpOsmfZg3vdQmJ0yvDxAYJsQHk%252BABwgJF1rezSA6dnjOsNoqMf9LA3G%252FEMkXUsWQmedAoq7iLO%252F1yrsQbTd%252Fntj4j8ZM2Sk8CHB0u8ME4sHewbWzt5C4D281OlohjBw%253D%253D%26lang%3Den%26reverseBPColor%3Dfalse"
  }
}
```

---

<!-- source: /seamless/getBetLimits.md -->

## Get BetLimits `GET`

`GET` `Optional` Get bet limit (Live casino only).

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/betLimitsV2?productId={{ productId }}
```

### Content Type

Type: `application/json`

### Parameter Description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PRETTY`) |

### Remark

**Product:** SAGAME

During the login process, the client can set any bet limit value. However, once entering the game lobby, there are <span style="color:red;">2 games where the bet limit will revert to the default value set by the game provider</span> due to provider limitations.

**Affected Games:**

* <span style="color:red;">Carnival Treasure</span>
* <span style="color:red;">Deluxe Blackjack</span>

> JSON response example:

```json
{
  "reqId": "395e9c4d-be1f-403d-b58a-e3e1ce4b7251",
  "code": 0,
  "message": "Success",
  "data": [
    {
      "productId": "PRETTY",
      "BetLimit": [
        {
          "limit": 1,
          "Min": 5,
          "Max": 2000
        },
        {
          "limit": 2,
          "Min": 50,
          "Max": 5000
        },
        {
          "limit": 3,
          "Min": 100,
          "Max": 20000
        }
      ]
    }
  ]
}
```

---

<!-- source: /seamless/verifyFishing.md -->

## Verify Deposit/Withdraw Fishing game type transaction `POST`

`Optional` For product `SLOTXO` or `JOKER` only.<br><span style="color:red">This API is neccessary if you need to verify the transaction when user playing Fishing game type.</span>

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request (For `SLOTXO` product)

```
POST {{ API_URL }}/xo_seamless/verify-topup
```

### HTTP Request (For `JOKER` product)

```
POST {{ API_URL }}/joker_seamless/verify-topup
```

### Content Type

Type: `application/json`

### Request parameter description

| Property        | Type   | Required | Description                                                                                             |
| --------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------- |
| `username`      | string | Required | Player username                                                                                         |
| `transactionId` | string | Required | Transaction id that your system got from callback `/deposit` or `/withdraw` on product `SLOTXO`/`JOKER` |

### Response parameter description

| Property  | Type                 | Required | Description                                                                                                |
| --------- | -------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |
| `code`    | number               | Required | Code status<br>`0`: success<br>`1`: failed.                                                                |
| `message` | string               | Required | Message description                                                                                        |
| `data`    | \[ object ] or `null` | Required | An array of transaction data description (See more below). `null` value if verify failed or an error occur |

### Response `data` parameter description

| Property   | Type   | Required | Description                                                                                                                |
| ---------- | ------ | -------- | -------------------------------------------------------------------------------------------------------------------------- |
| `id`       | string | Required | Transaction id (This should be the same id with your input)                                                                |
| `time`     | string | Required | Time when transaction generated (ISO format)                                                                               |
| `amount`   | number | Required | Transaction amount (This amount can be negative number when the `type` is `Withdraw`)                                      |
| `type`     | string | Required | Type of transaction<br>`TopUp`: Deposit credit to `SLOTXO` or `JOKER` system<br>`Withdraw`: Withdraw credit back to player |
| `username` | string | Required | Player username                                                                                                            |

> JSON example request:

```json
{
  "username": "foobar",
  "transactionId": "xe6ns1mycwwwh_xe6gxumgykk3e_795913499644948991"
}
```

> JSON example response:

```json
/* Verified success transaction */
{
  "code": 0,
  "message": "Success",
  "data": [
    {
      "id": "xe6ns1mycwwwh_xe6gxumgykk3e_795913499644948991",
      "time": "2021-08-05T15:16:03.982",
      "amount": 500,
      "type": "TopUp",
      "username": "foobar"
    }
  ]
}

/* Verified failed transaction */
{
  "code": 1,
  "message": "Can't verify transaction id: xe6ns1mycwwwh_xe6gxumgykk3e_795913499644948991",
  "data": null
}
```

---

<!-- source: /seamless/checkPlayerStatus.md -->

## Check player status

`Optional` This APIs use to check `ACTIVE`/`INACTIVE` status of player.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/checkPlayerStatus?productId={{ productId }}&username={{ username }}
```

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Request parameter description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `username`  | string | Required | Player username                                                                           |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property   | Type   | Required | Description                               |
| ---------- | ------ | -------- | ----------------------------------------- |
| `status`   | string | Required | status description, for example: `ACTIVE` |
| `username` | string | Required | Player username                           |

> JSON example request:

```json
{
  "productId": "PGSOFT",
  "username": "foobar"
}
```

> JSON example response:

```json
{
  "reqId": "05e287a6-00a9-4558-9bb2-2e422494ef22",
  "code": 0,
  "message": "Success",
  "data": {
    "status": "ACTIVE",
    "username": "foobar"
  }
}
```

---

<!-- source: /seamless/checkPlayerOnlineStatus.md -->

## Check player online status

`Optional` This APIs use to check `ONLINE`/`OFFLINE` status of player.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/checkOnlineStatus?productId={{ productId }}&username={{ username }}
```

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Request parameter description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `username`  | string | Required | Player username                                                                           |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property   | Type   | Required | Description                                              |
| ---------- | ------ | -------- | -------------------------------------------------------- |
| `status`   | string | Required | online/offline status description, for example: `ACTIVE` |
| `username` | string | Required | Player username                                          |

> JSON example request:

```json
{
  "productId": "PGSOFT",
  "username": "foobar"
}
```

> JSON example response:

```json
{
  "reqId": "05e287a6-00a9-4558-9bb2-2e422494ef22",
  "code": 0,
  "message": "Success",
  "data": {
    "status": "ACTIVE",
    "username": "foobar"
  }
}
```

---

<!-- source: /seamless/getPlayersOnlineList.md -->

## Get players online list

`Optional` This APIs use to check `ONLINE` (playing) players under your agent.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/checkOnlinePlayerList?productId={{ productId }}
```

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Request parameter description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property | Type     | Required | Description         |
| -------- | -------- | -------- | ------------------- |
| `users`  | string\[] | Required | Online players list |

> JSON example request:

```json
{
  "productId": "PGSOFT"
}
```

> JSON example response:

```json
{
  "reqId": "d3921d76-0488-4ca1-b65d-0093f410ea63",
  "code": 0,
  "message": "Success",
  "data": {
    "users": ["foobar", "barfoo"]
  }
}
```

---

<!-- source: /seamless/kickOutPlayer.md -->

## Kick out player

`Optional` This APIs use to kick an `ONLINE` player under your agent. If you use this API, the player were kicked out from game temporary.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
POST {{ API_URL }}/seamless/kickOutPlayer
```

### Content Type

Type: `application/json`

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Request parameter description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `username`  | string | Required | Player username                                                                           |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property   | Type   | Required | Description                                        |
| ---------- | ------ | -------- | -------------------------------------------------- |
| `status`   | string | Required | Success status description, for example: `SUCCESS` |
| `username` | string | Required | Player username                                    |

> JSON example request:

```json
{
  "productId": "PGSOFT",
  "username": "foobar"
}
```

> JSON example response:

```json
{
  "reqId": "05e287a6-00a9-4558-9bb2-2e422494ef22",
  "code": 0,
  "message": "Success",
  "data": {
    "status": "SUCCESS",
    "username": "foobar"
  }
}
```

---

<!-- source: /seamless/suspendPlayer.md -->

## Suspend out player

`Optional` This APIs use to suspend player under your agent. If you use this API, the player were suspended from provider system.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
POST {{ API_URL }}/seamless/suspendPlayer
```

### Content Type

Type: `application/json`

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Request parameter description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `username`  | string | Required | Player username                                                                           |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property   | Type   | Required | Description                                        |
| ---------- | ------ | -------- | -------------------------------------------------- |
| `status`   | string | Required | Success status description, for example: `SUCCESS` |
| `username` | string | Required | Player username                                    |

> JSON example request:

```json
{
  "productId": "PGSOFT",
  "username": "foobar"
}
```

> JSON example response:

```json
{
  "reqId": "05e287a6-00a9-4558-9bb2-2e422494ef22",
  "code": 0,
  "message": "Success",
  "data": {
    "status": "SUCCESS",
    "username": "foobar"
  }
}
```

---

<!-- source: /seamless/resumePlayer.md -->

## Resume out player

`Optional` This APIs use to resume suspended status for player under your agent. If you use this API, the player's status will back to `ACTIVE` and can access the provider system.

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
POST {{ API_URL }}/seamless/resumePlayer
```

### Content Type

Type: `application/json`

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Request parameter description

| Property    | Type   | Required | Description                                                                               |
| ----------- | ------ | -------- | ----------------------------------------------------------------------------------------- |
| `username`  | string | Required | Player username                                                                           |
| `productId` | string | Required | Product ID (Ref. [Product List](/api-reference.md#product-lists))) (Example : `PGSOFT`) |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property   | Type   | Required | Description                                        |
| ---------- | ------ | -------- | -------------------------------------------------- |
| `status`   | string | Required | Success status description, for example: `SUCCESS` |
| `username` | string | Required | Player username                                    |

> JSON example request:

```json
{
  "productId": "PGSOFT",
  "username": "foobar"
}
```

> JSON example response:

```json
{
  "reqId": "05e287a6-00a9-4558-9bb2-2e422494ef22",
  "code": 0,
  "message": "Success",
  "data": {
    "status": "SUCCESS",
    "username": "foobar"
  }
}
```

---

<!-- source: /seamless/freegame.md -->

## Freegame

`Optional` This APIs use give a freegame to player under operator. <br/>
<span style="color:red">**Note:** The operator must take full responsibility for this bet themselves.</span><br>

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
POST {{ API_URL }}/seamless/free-game
```

### Supported products

| Product ID | Product Name |
| ---------- | ------------ |
| `PGSOFT`   | PG Soft      |

### Content Type

Type: `application/json`

### Request parameter description

| Property         | Type   | Required | Description                                     |
| ---------------- | ------ | -------- | ----------------------------------------------- |
| `player_name`    | string | Required | Player username                                 |
| `free_game_name` | string | Required | Freegame name                                   |
| `expired_date`   | int    | Required | number of expire date for freegame unit is hour |
| `bet_amount`     | int    | Required | amount of freegame                              |
| `game_count`     | int    | Required | count of freegame                               |
| `game_ids`       | string | Required | gameid of freegame                              |
| `productId`      | string | Required | Product ID (Example : `PGSOFT`)                 |

### Response parameter description

| Property  | Type   | Required | Description                                                |
| --------- | ------ | -------- | ---------------------------------------------------------- |
| `reqId`   | string | Required | Request ID for each request.                               |
| `code`    | number | Required | Code status<br>`0`: success<br>`1`: failed.                |
| `message` | string | Required | Message description                                        |
| `data`    | object | Required | An array of transaction data description (See more below). |

### Response `data` parameter description

| Property     | Type   | Required | Description              |
| ------------ | ------ | -------- | ------------------------ |
| `freeGameId` | number | Required | freegameId from provider |

> JSON example request:

```json
{
  "player_name": "foobar",
  "free_game_name": "happy day",
  "expired_date": 24,
  "game_count": 30,
  "bet_amount": 100,
  "game_ids": "87",
  "productId": "PGSOFT"
}
```

> JSON example response:

```json
{
  "reqId": "05e287a6-00a9-4558-9bb2-2e422494ef22",
  "code": 0,
  "message": "Success",
  "data": {
    "freeGameId": 888
  }
}
```

### Free game result callback

When the player plays the free game, SuperAPI sends the result to your system through [/settleBets](/productCallback/settlement.md). See [Request Example (Free Game)](/productCallback/settlement.md#request-example-free-game) for the request your system will receive and the expected response.

---

<!-- source: /seamless/getAgentCredit.md -->

## Get Agent Credit `GET`

### Authorization

Seamless uses **Basic Authentication** with your agent credentials. ([Authentication](/authentication.md#authorization-header-format))

### HTTP Request

```
GET {{ API_URL }}/seamless/getAgentCredit
```

### Response Description

| Property  | Type                            | Required | Description                               |
| --------- | ------------------------------- | -------- | ----------------------------------------- |
| `reqId`   | string                          | Required | Unique reference for each request         |
| `code`    | number                          | Required | Response status                           |
| `message` | string                          | Required | Additional information on response status |
| `data`    | [GetAgentCredit](/seamless/getAgentCredit.md#agent-credit) | Required | Agent credit data                         |

### Agent Credit

| Property   | Type   | Required | Description   |
| ---------- | ------ | -------- | ------------- |
| `currency` | string | Required | Currency      |
| `credit`   | number | Required | Credit Amount |
| `type`     | string | Required | Wallet Type   |

> JSON response example:

```json
{
  "reqId": "7ba79e9c-ebaf-4f06-bd73-d8aa221d3",
  "code": 0,
  "message": "Success",
  "data": {
      "currency": "THB",
      "credit": 10000.31,
      "type": "seamless"
  }
}
```

---

# Part 3 — Product Callbacks (AMBSuperAPI calls you)

---

<!-- source: /productCallback/introduction.md -->

# Product Callbacks

<img src="https://superapi-products.s3.ap-southeast-1.amazonaws.com/thumbnail/new-workflow-sapi.jpg" alt="New workflow diagram" style="cursor: zoom-in;" onclick="window.open(this.src, '_blank')">

This new callback common flow, we simplifies callbacks from provider and standardize it to our own understandable.
Please check the following support products.

### Headers Request Signature (Optional)

Some callback requests may include the following headers for signature verification:

| Header           | Description                                                                    |
| ---------------- | ------------------------------------------------------------------------------ |
| `sapi-timestamp` | Unix timestamp in milliseconds sent by the system at request time.             |
| `sapi-signature` | HMAC-SHA256 signature of the request, using your `signatureKey` as the secret. |

Verifying the signature is **optional** but recommended. If you choose to verify it, refer to the [API Signature Verification](/productCallback/signature.md) page for the full method and code examples.

### Products to support

See all products in the [Product Lists](/api-reference.md#product-lists) section.

### API LIST

| Property      | Path             | Description                                     |
| ------------- | ---------------- | ----------------------------------------------- |
| GetBalance    | `/checkBalance`  | [Get Balance](/productCallback/gbl.md#check-balance-post)        |
| PlaceBets     | `/placeBets`     | [PlaceBet](/productCallback/placeBet.md#place-bets-post)         |
| Settle Bets   | `/settleBets`    | [Settlement](/productCallback/settlement.md#settle-bets-post)    |
| CancelBets    | `/cancelBets`    | [CancelBets](/productCallback/refund.md#cancel-bets-post)        |
| AdjustBets    | `/adjustBets`    | [AdjustBets](/productCallback/adjustBets.md#adjust-bets-post)    |
| Rollback      | `/rollback`      | [Rollback](/productCallback/rollback.md#rollback-post)           |
| WinRewards    | `/winRewards`    | [WinRewards](/productCallback/winreward.md#win-rewards-post)     |
| Tips          | `/placeTips`     | [Tips](/productCallback/tips.md#pay-tips-post)                   |
| CancelTips    | `/cancelTips`    | [CancelTips](/productCallback/canceltips.md#cancel-tips-post)    |
| VoidSettle    | `/voidSettled`   | [VoidSettle](/productCallback/voidSettled.md#void-settle-post)   |
| AdjustBalance | `/adjustBalance` | [AdjustBalance](/productCallback/ajb.md#adjust-balance-post)     |

### Common Status Code

> JSON response fail example:

| Code  | Description                              |
| ----- | ---------------------------------------- |
| 0     | Success                                  |
| 10001 | User not found                           |
| 10002 | User has insufficient balance to proceed |
| 20001 | Transaction not found                    |
| 20002 | Transaction duplicate                    |
| 30001 | Invalid token                            |
| 30002 | Invalid Signature                        |
| 40003 | Forbidden request                        |
| 50001 | Internal server error                    |

---

<!-- source: /productCallback/signature.md -->

# API Signature Verification

When our system sends a callback request to your endpoint, the request will include a signature header so you can verify the request is authentic and has not been tampered with.

## 3.1 Integration Information

The system provides the following information to the integrated partner:

| Property       | Type   | Description                                                                            |
| -------------- | ------ | -------------------------------------------------------------------------------------- |
| `signatureKey` | string | A secret key (UUID format) used for HMAC-SHA256 signature generation from Back Office. |

## 3.2 Request Headers

Each callback request includes the following headers. Use both values to verify the signature on your server:

| Header           | Type   | Description                                                                       |
| ---------------- | ------ | --------------------------------------------------------------------------------- |
| `sapi-timestamp` | string | Unix timestamp in **milliseconds** sent by the system at request time.            |
| `sapi-signature` | string | HMAC-SHA256 hex digest of the signing string, using `signatureKey` as the secret. |

## 3.3 Signature Generation

The signature is generated using **HMAC-SHA256**.

### Signing String

Build the signing string by concatenating the `sapi-timestamp` header value and the raw JSON body string:

```
signingString = rawBodyString + "." + sapi-timestamp
```

| Part             | Type   | Description                                                    |
| ---------------- | ------ | -------------------------------------------------------------- |
| `rawBodyString`  | string | The raw JSON-serialized request body (before any parsing).     |
| `sapi-timestamp` | string | Value taken directly from the `sapi-timestamp` request header. |

### HMAC-SHA256

```
signature = HMAC-SHA256(secret=signatureKey, data=signingString).hex()
```

## 3.4 Examples

### Raw Data

| Property            | Value                                                                                                                                            |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ |
| `signatureKey`      | `xxxxxxxxx-xxxx-xxxx-xxxx-xxxxx`                                                                                                                 |
| `sapi-timestamp`    | `1776929280534`                                                                                                                                  |
| Request Body (JSON) | `{"id":"1db0f513-a31f-4afa-9def-fdd6d2398c22","currency":"THB","productId":"5G_GAMES","timestampMillis":1776929280534,"username":"testaoo0012"}` |

### Step 1 — Serialize the request body

```
rawBodyString = '{"id":"1db0f513-a31f-4afa-9def-fdd6d2398c22","currency":"THB","productId":"5G_GAMES","timestampMillis":1776929280534,"username":"testaoo0012"}'
```

### Step 2 — Build the signing string

```
signingString = rawBodyString + "." + "1776929280534"
             = "{"id":"1db0f513-a31f-4afa-9def-fdd6d2398c22","currency":"THB","productId":"5G_GAMES","timestampMillis":1776929280534,"username":"testaoo0012"}.1776929280534"
```

### Step 3 — Compute HMAC-SHA256

```
signature = HMAC-SHA256(
  secret = "xxxxxxxxx-xxxx-xxxx-xxxx-xxxxx",
  data   = signingString
).hex()
```

## 3.5 Signature Example Code

### JavaScript / Node.js

```javascript
const crypto = require("crypto");

const buildSigningString = (timestamp, rawBody) => {
  return `${rawBody}.${timestamp}`;
};

const generate = (secret, timestamp, rawBody) => {
  const data = buildSigningString(timestamp, rawBody);
  return crypto.createHmac("sha256", secret).update(data).digest("hex");
};

// --- Example usage ---
const signatureKey = "xxxxxxxxx-xxxx-xxxx-xxxx-xxxxx";
const timestamp = "1776929280534";

const requestBody = {
  id: "1db0f513-a31f-4afa-9def-fdd6d2398c22",
  currency: "THB",
  productId: "5G_GAMES",
  timestampMillis: 1776929280534,
  username: "testaoo0012",
};

const rawBody = JSON.stringify(requestBody);
const signature = generate(signatureKey, timestamp, rawBody);
return signature;
```

### PHP

```php
<?php

function buildSigningString(string $timestamp, string $rawBody): string {
    return $rawBody . '.' . $timestamp;
}

function generateSignature(string $signatureKey, string $timestamp, string $rawBody): string {
    $signingString = buildSigningString($timestamp, $rawBody);
    return hash_hmac('sha256', $signingString, $signatureKey);
}

// --- Example usage ---
$signatureKey   = 'xxxxxxxxx-xxxx-xxxx-xxxx-xxxxx';
$timestamp = '1776929280534';

$requestBody = [
    'id'              => '1db0f513-a31f-4afa-9def-fdd6d2398c22',
    'currency'        => 'THB',
    'productId'       => '5G_GAMES',
    'timestampMillis' => 1776929280534,
    'username'        => 'testaoo0012',
];

// Verification: read timestamp from header
$timestamp = $_SERVER['HTTP_SAPI_TIMESTAMP'];
$received  = $_SERVER['HTTP_SAPI_SIGNATURE'];
$rawBody   = file_get_contents('php://input');

$expected  = generateSignature($signatureKey, $timestamp, $rawBody);
$valid     = hash_equals($expected, $received);

if (!$valid) {
    http_response_code(401);
    echo json_encode(['message' => 'Invalid signature']);
    exit;
}
```

## 3.6 Verification Flow

When receiving a callback request, follow these steps:

1. Read `sapi-timestamp` and `sapi-signature` from the **request headers**.
2. Get the **raw** (unparsed) request body string.
3. Build the signing string: `rawBody + "." + sapi-timestamp`.
4. Re-compute HMAC-SHA256 using your `signatureKey`.
5. Compare with `sapi-signature` using **constant-time comparison** to prevent timing attacks.
6. If the signatures do not match, respond with `statusCode: 30002` (Invalid Signature).

```
Headers received:
  sapi-timestamp: 1776929280534
  sapi-signature: <hex string>

Verification:
  signingString = rawBody + ".1776929280534"
  expected      = HMAC-SHA256(signatureKey, signingString).hex()
  valid         = timingSafeEqual(expected, sapi-signature)

If not valid → respond with statusCode 30002
```

> See [Common Status Code](/productCallback/introduction.md#common-status-code) for the full list of status codes.

---

<!-- source: /productCallback/gbl.md -->

# Check Balance `POST`

Get latest balance from member.

## HTTP Request

```
POST {{ YOUR_API_URL }}/checkBalance
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type   | Required | Description                                                                                                                         |
| ----------------- | ------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id (Unique value)                                                                                                           |
| `timestampMillis` | number | Required | Requesting time                                                                                                                     |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists)                                                 |
| `currency`        | string | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                                                                               |
| `username`        | string | Required | User id on agent system                                                                                                             |
| `gameCode`        | string | Optional | Game code that input from `/logIn` API (Depend on provider, sometimes this property didn't sent from provider site).                |
| `sessionToken`    | string | Optional | Session token that your system sent when call `/logIn` (Depend on provider, sometimes this property didn't sent from provider site) |

## Response Description

| Property          | Type   | Required | Description                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------ |
| `id`              | string | Required | Response ID (No need to response the same request ID)                                |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                       |
| `timestampMillis` | number | Required | Responding time                                                                      |
| `productId`       | string | Required | Product id associated with the response [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                 |
| `balance`         | number | Required | Player's current balance                                                             |
| `username`        | string | Required | User id on agent system                                                              |

## Request Example

> Request Body

```json
{
  "id": "2989ccc8-aae3-4ff4-803c-47de52f7c4d5",
  "currency": "THB",
  "productId": "{{ ProductID }}",
  "timestampMillis": 1712641926000,
  "username": "foobar",
  "gameCode": "3300",
  "sessionToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c"
}
```

> JSON response Success example:

```json
{
  "id": "2989ccc8-aae3-4ff4-803c-47de52f7c4d5",
  "statusCode": 0,
  "timestampMillis": 1712641927000,
  "productId": "{{ ProductID }}",
  "currency": "THB",
  "balance": 10000,
  "username": "foobar"
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/placeBet.md -->

# Place Bets `POST`

When player play or place bet on the Game GUI, system will sent this request to your system callback url (That you set on the Backoffice site)
You have to check player's balance. If they have enough balance, please deduct their balance and response success to our system to continue the game flow.

## HTTP Request

```
POST {{ YOUR_API_URL }}/placeBets
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                           | Required | Description                                                                         |
| ----------------- | ------------------------------ | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                         | Required | Request id                                                                          |
| `timestampMillis` | number                         | Required | Requesting time                                                                     |
| `productId`       | string                         | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                         | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                         | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/placeBet.md#common-place-bet-txn)\[] | Required | Transaction id on agent system                                                      |

#### Place Bet transaction parameters (`txns`)

| Property            | Type    | Required | Description                                                                                                                                                                                                                                                                                                                          |
| ------------------- | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`                | string  | Required | Transaction ID                                                                                                                                                                                                                                                                                                                       |
| `status`            | string  | Required | Bet status (Usually `OPEN` or `WAITING` (if game is `SPORT` type))                                                                                                                                                                                                                                                                   |
| `roundId`           | string  | Required | Round id                                                                                                                                                                                                                                                                                                                             |
| `betAmount`         | number  | Required | Stake amount                                                                                                                                                                                                                                                                                                                         |
| `gameCode`          | string  | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`          | string  | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `isFeature`         | boolean | Optional | The value indicates request is feature spin/game from provider.                                                                                                                                                                                                                                                                      |
|                     |         |          | If `isFeature: true` **possibly coming with `betAmount: 0`** (default value: `false`)                                                                                                                                                                                                                                                |
| `isFeatureBuy`      | boolean | Optional | The value indicates request is **"buying"** feature spin/game from provider. (default value: `false`)                                                                                                                                                                                                                                |
| `skipBalanceUpdate` | boolean | Optional | Flag indicating whether a round is this transaction need to update user's balance or not <br>`true`: Don't update user's balance<br>`false`: Update user's balance with `betAmount` or `payoutAmount`.                                                                                                                               |
|                     |         |          | Usually occur in `SPORT` game type, when provider considering the player's wagering on the game.                                                                                                                                                                                                                                     |
|                     |         |          | (default value: `false`)                                                                                                                                                                                                                                                                                                             |

## Response Description

| Property          | Type   | Required | Description                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------ |
| `id`              | string | Required | Response ID (No need to response the same request ID)                                |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                       |
| `timestampMillis` | number | Required | Responding time                                                                      |
| `productId`       | string | Required | Product id associated with the response [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                 |
| `balanceBefore`   | number | Required | Player's balance before bet                                                          |
| `balanceAfter`    | number | Required | Player's balance after bet                                                           |
| `username`        | string | Required | User id on agent system                                                              |

## Request Example

> Request Body

```json
{
  "id": "6849b62b-2b52-472a-88a4-c26c3371a62a",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1712760660000,
  "txns": [
    {
      "id": "T-001",
      "gameCode": "10300",
      "status": "OPEN",
      "roundId": "R-0001",
      "betAmount": 200,
      "playInfo": "Golden Coyote",
      "isFeature": false,
      "isFeatureBuy": false
    }
  ]
}
```

> JSON response Success example:

```json
{
  "id": "279478c1-c870-407e-91be-b70bf6a623f9",
  "statusCode": 0,
  "timestampMillis": 1712760660100,
  "productId": "{{ ProductID }}",
  "currency": "THB",
  "balanceBefore": 10000,
  "balanceAfter": 9800,
  "username": "foobar"
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/settlement.md -->

# Settle Bets `POST`

This request usually sent to your system after `/placeBets` was called and response success. SuperAPI sent the round result.
You can check the `payoutAmount` and increase the player's balance after that please response success to our system to allow player play in a next round.

Some product (e.g. `PGSOFT`, etc) has only this request to complete the round, the round do not start by `/placeBets` we will sent
both `betAmount` and `payoutAmount` to your system. You have to check player's balance by `betAmount` first. If they have enough balance to player, check the `payoutAmount`
to identified is player win or lose (normally, if `betAmount` > 0 and `payoutAmount` > `betAmount`, the player is win)

## Product Single State

| Product ID     | Product Name   |
| -------------- | -------------- |
| `PGSOFT`       | PG Soft        |
| `BOOMING`      | Booming        |
| `I8`           | I8             |
| `AFB1188_SLOT` | AFB1188 (Slot) |
| `FACHAI`       | Fachai         |
| `759GAMING`    | 759 Gaming     |
| `ASKMEBET`     | Askmebet       |
| `MINILUCK`     | Miniluck       |
| `BOOONGO`      | Booongo        |
| `KAGAME`       | KA Gaming      |
| `HECTICPLAY`   | Hectic Play    |

***

## HTTP Request

```
POST {{ YOUR_API_URL }}/settleBets
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                            | Required | Description                                                                         |
| ----------------- | ------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                          | Required | Request id                                                                          |
| `timestampMillis` | number                          | Required | Requesting time                                                                     |
| `productId`       | string                          | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                          | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                          | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/settlement.md#common-settle-bet-txn)\[] | Required | Transaction Id on agent system                                                      |

#### Settle Bet transaction parameters (`txns`)

| Property            | Type    | Required | Description                                                                                                                                                                                                                                                                                                                          |
| ------------------- | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`                | string  | Required | Transaction ID                                                                                                                                                                                                                                                                                                                       |
| `status`            | string  | Required | Bet status (Always `SETTLED`)                                                                                                                                                                                                                                                                                                        |
| `roundId`           | string  | Required | Round ID                                                                                                                                                                                                                                                                                                                             |
| `betAmount`         | number  | Required | Stake amount (Sometimes this value equal to `0` because we can't identify the `betAmount` from `/placeBets` request)                                                                                                                                                                                                                 |
| `payoutAmount`      | number  | Required | Payout amount (stake + win amount)                                                                                                                                                                                                                                                                                                   |
| `gameCode`          | string  | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`          | string  | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `turnOver`          | number  | Required | Turn over (some product call valid stake, valid bet, etc.) for each round.                                                                                                                                                                                                                                                           |
|                     |         |          | If system can identify turn-over from provider, this value should not be `0` (Default value is `0`).                                                                                                                                                                                                                                 |
|                     |         |          | <span style="color:red">**Note:** Please test each product to check the real turn-over value before use this value.</span>                                                                                                                                                                                                           |
| `isSingleState`     | boolean | Required | Value indicates whether the round for this request is end in single `/settleBets` request (No `/placeBets`, it's mean the round has no `OPEN` status) [Product](/productCallback/settlement.md#product-single-state)                                                                                                                                               |
| `transactionType`   | string  | Required | The value that indicate transaction action, have 2 values:                                                                                                                                                                                                                                                                           |
|                     |         |          | 1. `BY_TRANSACTION`: This type, you have to consider the action is a transaction-level.[Example](/productCallback/settlement.md#request-example-by-transaction)                                                                                                                                                                                                    |
|                     |         |          | Find the transaction inside your data storage using `id` and action only found transaction.                                                                                                                                                                                                                                          |
|                     |         |          | 2. `BY_ROUND`: This type, you have to consider the action is a round-level.[Example](/productCallback/settlement.md#request-example-by-round)                                                                                                                                                                                                                      |
|                     |         |          | Find entire transactions that belongs to `roundId` and actions all transactions at once.                                                                                                                                                                                                                                             |
| `isEndRound`        | boolean | Optional | Value indicates whether a round is end round or not (The default value is `false`)                                                                                                                                                                                                                                                   |
| `isFeature`         | boolean | Optional | The value indicates request is feature spin/game from provider.                                                                                                                                                                                                                                                                      |
|                     |         |          | If `isFeature: true` **possibly coming with `betAmount: 0`** (default value: `false`)                                                                                                                                                                                                                                                |
| `isFeatureBuy`      | boolean | Optional | The value indicates request is **"buying"** feature spin/game from provider. (default value: `false`)                                                                                                                                                                                                                                |
| `skipBalanceUpdate` | boolean | Optional | Flag indicating whether a round is this transaction need to update user's balance or not <br>`true`: Don't update user's balance<br>`false`: Update user's balance with `betAmount` or `payoutAmount`.                                                                                                                               |
|                     |         |          | Usually occur in `SPORT` game type, when provider considering the player's wagering on the game.                                                                                                                                                                                                                                     |
|                     |         |          | (default value: `false`)                                                                                                                                                                                                                                                                                                             |

## Response Description

| Property          | Type   | Required | Description                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------ |
| `id`              | string | Required | Request ID                                                                           |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                       |
| `timestampMillis` | number | Required | Responding time                                                                      |
| `productId`       | string | Required | Product ID associated with the response [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                 |
| `balanceBefore`   | number | Required | Player's balance before settle                                                       |
| `balanceAfter`    | number | Required | Player's balance after settle                                                        |
| `username`        | string | Required | User id on agent system                                                              |

***

## Request Example

> Request Body

```json
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1712767012000,
  "txns": [
    {
      "id": "T-002",
      "status": "SETTLED",
      "roundId": "R-0001",
      "betAmount": 0,
      "turnOver": 0,
      "payoutAmount": 5000,
      "gameCode": "10300",
      "playInfo": "Golden Coyote",
      "isEndRound": false,
      "isSingleState": false,
      "skipBalanceUpdate": false,
      "transactionType": "BY_ROUND"
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "37e10565-ca3f-4367-b3ad-c6aa2f01ffd0",
  "statusCode": 0,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1712767012100,
  "username": "foobar",
  "currency": "THB",
  "balanceBefore": 9800,
  "balanceAfter": 14800
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

## Request Example (BY_TRANSACTION)

> Request Body

```json
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564361,
  "username": "testuser1",
  "txns": [
    {
      "id": "x425atj33k8psk",
      "status": "OPEN",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 10,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "skipBalanceUpdate": false
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564453,
  "username": "testuser1",
  "txns": [
    {
      "id": "z2l8kx8zzjxrm3",
      "status": "OPEN",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 5,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "skipBalanceUpdate": false
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564453,
  "username": "testuser1",
  "txns": [
    {
      "id": "7f1e0i1lesr9yv",
      "status": "OPEN",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 20,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "skipBalanceUpdate": false
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564735,
  "username": "testuser1",
  "txns": [
    {
      "id": "x425atj33k8psk",
      "status": "SETTLED",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 0,
      "payoutAmount": 20,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "isSingleState": false,
      "transactionType": "BY_TRANSACTION",
      "turnOver": 0
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564820,
  "username": "testuser1",
  "txns": [
    {
      "id": "z2l8kx8zzjxrm3",
      "status": "SETTLED",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 0,
      "payoutAmount": 0,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "isSingleState": false,
      "transactionType": "BY_TRANSACTION",
      "turnOver": 0
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564820,
  "username": "testuser1",
  "txns": [
    {
      "id": "7f1e0i1lesr9yv",
      "status": "SETTLED",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 0,
      "payoutAmount": 10,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "isSingleState": false,
      "transactionType": "BY_TRANSACTION",
      "turnOver": 0
    }
  ]
}
```

## Request Example (BY_ROUND)

> Request Body

```json
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564361,
  "username": "testuser1",
  "txns": [
    {
      "id": "x425atj33k8psk",
      "status": "OPEN",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 10,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "skipBalanceUpdate": false
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564453,
  "username": "testuser1",
  "txns": [
    {
      "id": "z2l8kx8zzjxrm3",
      "status": "OPEN",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 5,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "skipBalanceUpdate": false
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114564453,
  "username": "testuser1",
  "txns": [
    {
      "id": "7f1e0i1lesr9yv",
      "status": "OPEN",
      "roundId": "j6nfiubzcer1c8",
      "betAmount": 20,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "skipBalanceUpdate": false
    }
  ]
}
------------------------------------------------
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "timestampMillis": 1756114565578,
  "username": "testuser1",
  "txns": [
    {
      "id": "zkudwpstubzc3f",
      "status": "SETTLED",
      "roundId": "uskpir866lcc6l",
      "betAmount": 0,
      "payoutAmount": 50,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania",
      "isSingleState": false,
      "transactionType": "BY_ROUND",
      "turnOver": 0
    }
  ]
}
```

## Request Example (Free Game)

When the player plays a free game given by [Freegame API](/seamless/freegame.md), SuperAPI sends the result to your system with this `/settleBets` request. No `/placeBets` is sent for a free game round.

* `txns[].id` starts with `freegame-` followed by the free game ID (`freeGameId` from [Freegame API](/seamless/freegame.md)), e.g. `freegame-{freeGameId}-{betId}`.
* `betAmount` is `0` because the player does not pay a stake for a free game. Do not deduct the player's balance.
* `payoutAmount` is the amount the player wins from the free game. Increase the player's balance by this value.
* `isSingleState` is `true`, so the round ends in this single request.
* `isFeature` can be `true` or `false`.

> Request Body (`PGSOFT`)

```json
{
  "id": "80873949-97f3-43fa-ab57-64f346001372",
  "productId": "PGSOFT",
  "username": "testuser1",
  "currency": "THB",
  "timestampMillis": 1795677905806,
  "txns": [
    {
      "id": "freegame-58305209-2125853332810502657",
      "status": "SETTLED",
      "roundId": "2125853332810502657-2125853318239490048-403-0",
      "betAmount": 0,
      "payoutAmount": 13.4,
      "gameCode": "mahjong-ways2",
      "playInfo": "Mahjong Ways 2",
      "turnOver": 0,
      "isEndRound": true,
      "isSingleState": true,
      "isFeature": true,
      "transactionType": "BY_ROUND"
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "80873949-97f3-43fa-ab57-64f346001372",
  "statusCode": 0,
  "timestampMillis": 1795677905866,
  "productId": "PGSOFT",
  "currency": "THB",
  "balanceBefore": 0.19,
  "balanceAfter": 13.59,
  "username": "testuser1"
}
```

---

<!-- source: /productCallback/refund.md -->

# Cancel Bets `POST`

Provider will send the user's cancel information when bet have a problem or timeout.

## HTTP Request

```
POST {{ YOUR_API_URL }}/cancelBets
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                            | Required | Description                                                                         |
| ----------------- | ------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                          | Required | Request ID                                                                          |
| `timestampMillis` | number                          | Required | Requesting time                                                                     |
| `productId`       | string                          | Required | Product ID associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                          | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                          | Required | User ID on agent system                                                             |
| `txns`            | [Txn](/productCallback/refund.md#common-cancel-bet-txn)\[] | Required | Transaction Id                                                                      |

#### Cancel Bet transaction parameters (`txns`)

| Property          | Type   | Required | Description                                                                                                                                                                                                                                                                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`              | string | Required | Transaction ID                                                                                                                                                                                                                                                                                                                       |
| `status`          | string | Required | Adjust status, have 2 values:                                                                                                                                                                                                                                                                                                        |
|                   |        |          | 1. `REFUND`: The cancel status, this status come after the `OPEN` status. When your system got this status, you need to cancel the OPEN transaction and refund the balance to the user.                                                                                                                                              |
|                   |        |          | 2. `REJECT`: The reject status, this status come after the `WAITING` status. This status mean the sport's provider reject the bet.The causes of this status are:                                                                                                                                                                     |
|                   |        |          | 2.1. Odds changing before your bet was confirmed.                                                                                                                                                                                                                                                                                    |
|                   |        |          | 2.2. Market already closed.                                                                                                                                                                                                                                                                                                          |
|                   |        |          | 2.3. System or risk control rejecting the wager.                                                                                                                                                                                                                                                                                     |
| `roundId`         | string | Required | Round id                                                                                                                                                                                                                                                                                                                             |
| `betAmount`       | number | Required | Stake amount, you can use this value to refund to your player's balance.                                                                                                                                                                                                                                                             |
| `gameCode`        | string | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`        | string | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `transactionType` | string | Required | The value that indicate transaction action, have 2 values:                                                                                                                                                                                                                                                                           |
|                   |        |          | 1. `BY_TRANSACTION`: This type, you have to consider the action is a transaction-level.                                                                                                                                                                                                                                              |
|                   |        |          | 2. `BY_ROUND`: This type, you have to consider the action is a round-level.                                                                                                                                                                                                                                                          |
|                   |        |          | Find entire transactions that belongs to `roundId` and actions all transactions at once.                                                                                                                                                                                                                                             |

## Response Description

| Property          | Type   | Required | Description                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------ |
| `id`              | string | Required | Request id                                                                           |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                       |
| `timestampMillis` | number | Required | Responding time                                                                      |
| `productId`       | string | Required | Product id associated with the response [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                 |
| `balanceBefore`   | number | Required | Player's balance before cancel                                                       |
| `balanceAfter`    | number | Required | Player's balance after cancel                                                        |
| `username`        | string | Required | User id on agent system                                                              |

## Request Example

> Request Body

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4v",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1712767745000,
  "txns": [
    {
      "id": "R-0001",
      "status": "REFUND",
      "roundId": "R-0001",
      "betAmount": 200,
      "gameCode": "10300",
      "playInfo": "Golden Coyote",
      "transactionType": "BY_ROUND"
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 0,
  "timestampMillis": 1712767745100,
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "balanceBefore": 14800,
  "balanceAfter": 10000,
  "username": "foobar"
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/adjustBets.md -->

# Adjust Bets `POST`

Sometimes the provider need to adjust the wagered amount. If you got this request, you can use the value inside the body to adjust player's balance. <br>
**Adjust bet = (Member Balance + Old Bet Amount) - New Bet Amount<br>Start Balance = 10000<br>Bet Amount = 10<br>Balance = 9990<br>Adjust Bet = 20<br>Balance = 9980<br>calculate Balance = 9990 + 10 - 20**

## HTTP Request

```
POST {{ YOUR_API_URL }}/adjustBets
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                            | Required | Description                                                                         |
| ----------------- | ------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                          | Required | Request id                                                                          |
| `timestampMillis` | number                          | Required | Requesting time                                                                     |
| `productId`       | string                          | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                          | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                          | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/adjustBets.md#allbet-adjust-bet-txn)\[] | Required | Transaction Id on agent system                                                      |

#### Adjust Bet transaction parameters (`txns`)

| Property    | Type   | Required | Description                                                                                                                                                                                                                                                                                                                          |
| ----------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`        | string | Required | Transaction ID                                                                                                                                                                                                                                                                                                                       |
| `status`    | string | Required | Bet status (Always `OPEN`)                                                                                                                                                                                                                                                                                                           |
| `roundId`   | string | Required | Round id                                                                                                                                                                                                                                                                                                                             |
| `gameCode`  | string | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`  | string | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `betAmount` | number | Required | The value that system need to adjust the wagering amount.                                                                                                                                                                                                                                                                            |
| `txnId`     | string | Optional | Transaction ID (Usually send the same value as `id`)                                                                                                                                                                                                                                                                                 |

## Response Description

| Property          | Type   | Required | Description                                                                         |
| ----------------- | ------ | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                          |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                      |
| `timestampMillis` | number | Required | Responding time                                                                     |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                |
| `balanceBefore`   | number | Required | Player's balance before unsettle                                                    |
| `balanceAfter`    | number | Required | Player's balance after unsettle                                                     |
| `username`        | string | Required | User id on agent system                                                             |

## Request Example

> Request Body

```json
{
  "id": "2a561272-df13-4c1e-99d4-06eb7f061fe2",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1724047571704,
  "txns": [
    {
      "id": "285110bjm7rjvo",
      "status": "OPEN",
      "roundId": "2rj3byk76ks4yn",
      "betAmount": 20,
      "gameCode": "d5qfgs4amfxf6",
      "playInfo": "Respin Mania"
    }
  ]
}
```

> JSON Response Body

```json
{
  "id": "eb62c4bf-32e4-402e-8dc0-a714456bb904",
  "statusCode": 0,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1712768088100,
  "username": "foobar",
  "currency": "THB",
  "balanceBefore": 10000,
  "balanceAfter": 9980
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/rollback.md -->

# Rollback `POST`

This request will be sent if the provider need to change the result of the ended round.
You have to roll the state of the round status to running again. However, this can action both `REFUND` and `SETTLED` status.
When the previous status is `REFUND` you have to roll the canceled round to running again by reduced the balance that refunded.
When the previous status is `SETTLED` you have to roll the ended round to running again by reduced the balance that already win/lose.

## HTTP Request

```
POST {{ YOUR_API_URL }}/rollback
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                              | Required | Description                                                                         |
| ----------------- | --------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                            | Required | Request id                                                                          |
| `timestampMillis` | number                            | Required | Requesting time                                                                     |
| `productId`       | string                            | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                            | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                            | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/rollback.md#common-unsettle-bet-txn)\[] | Required | Transaction Id on agent system                                                      |

#### Rollback transaction parameters (`txns`)

| Property          | Type   | Required | Description                                                                                                                                                                                                                                                                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`              | string | Required | Bet ID                                                                                                                                                                                                                                                                                                                               |
| `status`          | string | Required | Bet status (Will be ROLLBACK)                                                                                                                                                                                                                                                                                                        |
| `roundId`         | string | Required | Round id                                                                                                                                                                                                                                                                                                                             |
| `gameCode`        | string | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`        | string | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `payoutAmount`    | number | Required | The amount that round need to rollback, use this value to update balance if previous status is `SETTLED`, player's balance will be reduced.                                                                                                                                                                                          |
| `betAmount`       | number | Required | The amount that round need to rollback, use this value to update balance if previous status is `REFUND`, player's balance will be reduced.                                                                                                                                                                                           |
| `transactionType` | string | Required | The value that indicate transaction action, have 2 values:                                                                                                                                                                                                                                                                           |
|                   |        |          | 1. `BY_TRANSACTION`: This type, you have to consider the action is a transaction-level.                                                                                                                                                                                                                                              |
|                   |        |          | Find the transaction inside your data storage using `id` and action only found transaction.                                                                                                                                                                                                                                          |
|                   |        |          | 2. `BY_ROUND`: This type, you have to consider the action is a round-level.                                                                                                                                                                                                                                                          |
|                   |        |          | Find entire transactions that belongs to `roundId` and actions all transactions at once.                                                                                                                                                                                                                                             |

## Response Description

| Property          | Type   | Required | Description                                                                                       |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                                        |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                                    |
| `timestampMillis` | number | Required | Responding time                                                                                   |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists)               |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                              |
| `balanceBefore`   | number | Required | Player's balance before unsettle                                                                  |
| `balanceAfter`    | number | Required | Player's balance after unsettle (deduct from payoutAmount - betAmount of previous settle request) |
| `username`        | string | Required | User id on agent system                                                                           |

## Request Example

> Request Body

```json
{
  "id": "e75db240-d519-44dd-8e37-d68ec1c6f9b2",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1645775403311,
  "txns": [
    {
      "id": "9621055643135717",
      "status": "ROLLBACK",
      "roundId": "962105564",
      "gameCode": "BB001",
      "playInfo": "Player 1 Double",
      "payoutAmount": 100,
      "betAmount": 0,
      "transactionType": "BY_ROUND"
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "e75db240-d519-44dd-8e37-d68ec1c6f9b2",
  "statusCode": 0,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1645775403663,
  "username": "foobar",
  "currency": "THB",
  "balanceBefore": 9997.5,
  "balanceAfter": 9897.5
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/winreward.md -->

# Win Rewards `POST`

When provider has some event and their need to sent the reward (Jackpot or Bonus) this request will be called.

## HTTP Request

```
POST {{ YOUR_API_URL }}/winRewards
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                             | Required | Description                                                                         |
| ----------------- | -------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                           | Required | Request id                                                                          |
| `timestampMillis` | number                           | Required | Requesting time                                                                     |
| `productId`       | string                           | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                           | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                           | Required | User id on agent system                                                             |
| `txns`            | [Txn\[\]](/productCallback/winreward.md#common-win-rewards-txn) | Required | Transactions                                                                        |

#### Win Rewards transaction parameters (`txns`)

| Property       | Type   | Required | Description                                                                                                                                                                                                                                                                                                                          |
| -------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`           | string | Required | Bet id                                                                                                                                                                                                                                                                                                                               |
| `status`       | string | Required | Bet status (Should always be SETTLED)                                                                                                                                                                                                                                                                                                |
| `roundId`      | string | Required | Round id                                                                                                                                                                                                                                                                                                                             |
| `payoutAmount` | number | Required | Win amount                                                                                                                                                                                                                                                                                                                           |
| `gameCode`     | string | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`     | string | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `betAmount`    | number | Optional | Stake amount.                                                                                                                                                                                                                                                                                                                        |

## Response Description

| Property          | Type   | Required | Description                                                                         |
| ----------------- | ------ | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                          |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                      |
| `timestampMillis` | number | Required | Responding time                                                                     |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                |
| `balanceBefore`   | number | Required | Player's balance before get rewards                                                 |
| `balanceAfter`    | number | Required | Player's balance after get rewards                                                  |
| `username`        | string | Required | User id on agent system                                                             |

## Request Example

> Request Body

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1631599542778,
  "txns": [
    {
      "id": "e723b240-d519-44dd-8e37-d6823c6f9b2",
      "status": "SETTLED",
      "roundId": "R-0909",
      "payoutAmount": 1000,
      "gameCode": "MX-LIVE-001",
      "playInfo": "Banker"
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 0,
  "timestampMillis": 1631599542821,
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "balanceBefore": 8600,
  "balanceAfter": 9600,
  "username": "foobar"
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/tips.md -->

# Pay Tips `POST`

This request will be sent if player tips game provider (usually tips dealer in live-casino game).
This callback is an optional callbacks, some product has this callback. Ex. Pretty gaming.

## HTTP Request

```
POST {{ YOUR_API_URL }}/placeTips
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                          | Required | Description                                                                         |
| ----------------- | ----------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                        | Required | Request id                                                                          |
| `timestampMillis` | number                        | Required | Requesting time                                                                     |
| `productId`       | string                        | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                        | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                        | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/tips.md#common-pay-tips-txn)\[] | Required | Transaction Id                                                                      |

#### Pay Tips transaction parameters (`txns`)

| Property    | Type   | Required | Description                                                                    |
| ----------- | ------ | -------- | ------------------------------------------------------------------------------ |
| `id`        | string | Required | Transaction ID                                                                 |
| `status`    | string | Required | Bet status (Always `TIPS`)                                                     |
| `roundId`   | string | Required | Round ID                                                                       |
| `betAmount` | number | Required | Stake amount (Sometimes this value is `0` due to no information from provider) |

## Response Description

| Property          | Type   | Required | Description                                                                         |
| ----------------- | ------ | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                          |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                      |
| `timestampMillis` | number | Required | Responding time                                                                     |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                |
| `balanceBefore`   | number | Required | Player's balance before cancel                                                      |
| `balanceAfter`    | number | Required | Player's balance after cancel                                                       |
| `username`        | string | Required | User id on agent system                                                             |

## Request Example

> Request Body

```json
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1712767012000,
  "txns": [
    {
      "id": "Tip-001",
      "status": "TIPS",
      "roundId": "Tip-R-0001",
      "betAmount": 1000
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 0,
  "timestampMillis": 1631599542878,
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "balanceBefore": 10000,
  "balanceAfter": 9000,
  "username": "foobar"
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/canceltips.md -->

# Cancel Tips `POST`

## HTTP Request

```
POST {{ YOUR_API_URL }}/cancelTips
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                                 | Required | Description                                                                         |
| ----------------- | ------------------------------------ | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                               | Required | Request id                                                                          |
| `timestampMillis` | number                               | Required | Requesting time                                                                     |
| `productId`       | string                               | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                               | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                               | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/canceltips.md#common-pay-tips-cancel-txn)\[] | Required | Transaction Id                                                                      |

#### Cancel Tips transaction parameters (`txns`)

| Property    | Type   | Required | Description                          |
| ----------- | ------ | -------- | ------------------------------------ |
| `id`        | string | Required | Bet id                               |
| `status`    | string | Required | Bet status (Should always be REFUND) |
| `roundId`   | string | Required | Round id                             |
| `betAmount` | number | Required | Stake amount                         |

## Response Description

| Property          | Type   | Required | Description                                                                         |
| ----------------- | ------ | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                          |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                      |
| `timestampMillis` | number | Required | Responding time                                                                     |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                |
| `balanceBefore`   | number | Required | Player's balance before cancel                                                      |
| `balanceAfter`    | number | Required | Player's balance after cancel                                                       |
| `username`        | string | Required | User id on agent system                                                             |

## Request Example

> Request Body

```json
{
  "id": "26cf1ce1-8ee1-4bbf-9d42-872631054bcf",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1712767012000,
  "txns": [
    {
      "id": "Tip-001",
      "status": "REFUND",
      "roundId": "Tip-R-0001",
      "betAmount": 1000
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 0,
  "timestampMillis": 1631599542878,
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "balanceBefore": 8600,
  "balanceAfter": 8700,
  "username": "testProduct1"
}
```

> JSON response Fail example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 10001,
  "productId": "{{ Product ID }}",
  "timestampMillis": 1631599542878
}
```

---

<!-- source: /productCallback/voidSettled.md -->

# Void Settle `POST`

Instead of cancel, sometimes provider use `VOID` as a cancel. This mean the round will be completely canceled, usually not revoke the round again.
For this request, you have to increase player's balance with `betAmount` - `payoutAmount`.<br/>
**For example:** <br>
If player's initial balance is `1000.00` <br>

1. Player bet `100.00` into the game. So, balance equal `900.00`<br>
2. Player win `500.00` into the game. So, balance equal `1400.00`<br>
3. Game provider need to void the above round, our system will send `betAmount: 100.00` and `payoutAmount: 500.00`<br>
4. Your system have to update balance `1400.00 + (100.00 - 500.00)` (Player balance + (betAmount - payoutAmount)), So final balance must equal `1000.00`<br>
   In the end of the `/voidSettled`, player's balance must equal `1000.00` like the initial balance.

## HTTP Request

```
POST {{ YOUR_API_URL }}/voidSettled
```

## Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                              | Required | Description                                                                         |
| ----------------- | --------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                            | Required | Request id                                                                          |
| `timestampMillis` | number                            | Required | Requesting time                                                                     |
| `productId`       | string                            | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                            | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                            | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/voidSettled.md#common-unsettle-bet-txn)\[] | Required | Transaction Id on agent system                                                      |

#### Void settle transaction parameters (`txns`)

| Property          | Type   | Required | Description                                                                                                                                                                                                                                                                                                                          |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`              | string | Required | Bet ID                                                                                                                                                                                                                                                                                                                               |
| `status`          | string | Required | Bet status (always `VOID`)                                                                                                                                                                                                                                                                                                           |
| `roundId`         | string | Required | Round ID                                                                                                                                                                                                                                                                                                                             |
| `betAmount`       | number | Required | Stake amount (Use this value to increase player's balance)                                                                                                                                                                                                                                                                           |
| `payoutAmount`    | number | Required | Payout amount (Use this value to decrease player's balance)                                                                                                                                                                                                                                                                          |
| `gameCode`        | string | Required | Game code                                                                                                                                                                                                                                                                                                                            |
| `playInfo`        | string | Required | Information regarding the player was chosen. If Live-casino game this should be the position that player wager on that round if system can identified the position (e.g. `player`, `banker`). Other games, the value should be the game name, if we can't identified game name or game code, we will send 'UNKNOWN' into this value. |
| `transactionType` | string | Required | The value that indicate transaction action, have 2 values:                                                                                                                                                                                                                                                                           |
|                   |        |          | 1. `BY_TRANSACTION`: This type, you have to consider the action is a transaction-level.                                                                                                                                                                                                                                              |
|                   |        |          | Find the transaction inside your data storage using `id` and action only found transaction.                                                                                                                                                                                                                                          |
|                   |        |          | 2. `BY_ROUND`: This type, you have to consider the action is a round-level.                                                                                                                                                                                                                                                          |
|                   |        |          | Find entire transactions that belongs to `roundId` and actions all transactions at once.                                                                                                                                                                                                                                             |

## Response Description

| Property          | Type   | Required | Description                                                                                       |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                                        |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                                    |
| `timestampMillis` | number | Required | Responding time                                                                                   |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists)               |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                              |
| `balanceBefore`   | number | Required | Player's balance before unsettle                                                                  |
| `balanceAfter`    | number | Required | Player's balance after unsettle (deduct from payoutAmount - betAmount of previous settle request) |
| `username`        | string | Required | User id on agent system                                                                           |

## Request Example

> Request Body

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1631599542778,
  "txns": [
    {
      "id": "VB-T-001",
      "status": "VOID",
      "roundId": "R-001",
      "betAmount": 100,
      "payoutAmount": 1000,
      "gameCode": "108",
      "playInfo": "Magic Lamp",
      "transactionType": "BY_ROUND"
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 0,
  "timestampMillis": 1631599542821,
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "balanceBefore": 10000,
  "balanceAfter": 9100,
  "username": "foobar"
}
```

---

<!-- source: /productCallback/ajb.md -->

# Adjust balance `POST`

In a game that have to deposit/withdraw credit before play the game (e.g. Fishing type). We uses this callback to operates an action.
Please carefully check the `refId` as a duplicates reference. Sometimes this callback can call to your side concurrenry, you have to check player's balance before send the success to our system.

## HTTP Request

```
POST {{ YOUR_API_URL }}/adjustBalance
```

#### Content Type

Type: `application/json`

## Parameter Description

| Property          | Type                                | Required | Description                                                                         |
| ----------------- | ----------------------------------- | -------- | ----------------------------------------------------------------------------------- |
| `id`              | string                              | Required | Request id                                                                          |
| `timestampMillis` | number                              | Required | Requesting time                                                                     |
| `productId`       | string                              | Required | Product id associated with the request [Product](/api-reference.md#product-lists) |
| `currency`        | string                              | Required | Player's currency code in ISO 4217 (Example: `"THB"`)                               |
| `username`        | string                              | Required | User id on agent system                                                             |
| `txns`            | [Txn](/productCallback/ajb.md#common-adjust-balance-txn)\[] | Required | Transaction Id on agent system                                                      |

#### Adjust balance transaction parameters (`txns`)

| Property | Type   | Required | Description                                         |
| -------- | ------ | -------- | --------------------------------------------------- |
| `refId`  | string | Required | Transaction reference ID                            |
| `status` | string | Required | Adjust status, have 2 values:                       |
|          |        |          | 1. `DEBIT`: You have to deduct player's balance.    |
|          |        |          | 2. `CREDIT`: You have to increase player's balance. |
| `amount` | number | Required | Balance amount to calculate the player's balance.   |

## Response Description

| Property          | Type   | Required | Description                                                                                       |
| ----------------- | ------ | -------- | ------------------------------------------------------------------------------------------------- |
| `id`              | string | Required | Request id                                                                                        |
| `statusCode`      | number | Required | Status from [StatusCode](/productCallback/introduction.md#common-status-code)                                    |
| `timestampMillis` | number | Required | Responding time                                                                                   |
| `productId`       | string | Required | Product id associated with the request [Product](/api-reference.md#product-lists)               |
| `currency`        | string | Required | Player's currency codein ISO 4217 (Example: `"THB"`)                                              |
| `balanceBefore`   | number | Required | Player's balance before unsettle                                                                  |
| `balanceAfter`    | number | Required | Player's balance after unsettle (deduct from payoutAmount - betAmount of previous settle request) |
| `username`        | string | Required | User id on agent system                                                                           |

## Request Example

> Request Body

```json
{
  "id": "46a0a0da-22c9-4016-94bd-d80ab6d97026",
  "productId": "{{ Product ID }}",
  "username": "foobar",
  "currency": "THB",
  "timestampMillis": 1631599542778,
  "txns": [
    {
      "refId": "e7de2c76-f534-473d-b8fb-f5c901a3c582",
      "status": "DEBIT",
      "amount": 1500
    }
  ]
}
```

> JSON response example:

```json
{
  "id": "c7197ce4-5a50-4397-a903-d78b135ade4c",
  "statusCode": 0,
  "timestampMillis": 1631599542821,
  "productId": "{{ Product ID }}",
  "currency": "THB",
  "balanceBefore": 10000,
  "balanceAfter": 8500,
  "username": "foobar"
}
```

---

# Part 4 — Reference (products, currencies, languages)

---

<!-- source: /api-reference.md -->

# API Referance

## Category Lists

| Value      | Description |
| ---------- | ----------- |
| EGAMES     | Games Slot  |
| LIVECASINO | Live Casino |
| SPORT      | Sportbook   |
| POKER      | Poker       |
| TRADING    | Trading     |

## Product Lists

### Games Slot

| Product ID         | Product Name               | Description                | Seamless | Transfer | Release  |
| ------------------ | -------------------------- | -------------------------- | -------- | -------- | -------- |
| 1UP_SPIN           | 1Up Spin                   | 1Up Spin                   | ✔        | -        |          |
| 5G_GAMES           | 5G Games                   | 5G Games                   | ✔        | -        |          |
| 759GAMING          | 759 Gaming                 | 759 Gaming                 | ✔        | -        |          |
| 918KISS            | 918Kiss                    | 918Kiss                    | ✔        | -        |          |
| ACE333             | Ace333                     | Ace333                     | ✔        | -        |          |
| ADVANT             | Advant Play                | Advant Play                | ✔        | -        |          |
| AFB1188_SLOT       | AFB1188 Slot               | AFB1188 (Slot)             | ✔        | -        |          |
| AMBGAMING          | SpinGo                     | SpinGo                     | ✔        | -        |          |
| AMEBA              | Ameba                      | Ameba                      | ✔        | -        |          |
| ASKMEBET           | Askmebet                   | Askmebet                   | ✔        | ✔        |          |
| ASKMESLOT          | Askmeslot                  | Askmeslot                  | ✔        | -        |          |
| BIGPOT             | Bigpot                     | Bigpot                     | ✔        | -        |          |
| BIGTIME            | BigTime Gaming             | BigTime Gaming             | ✔        | -        |          |
| BOOMING            | Booming                    | Booming                    | ✔        | -        |          |
| BOOONGO            | Booongo                    | Booongo                    | ✔        | -        |          |
| CG                 | Creative Gaming            | Creative Gaming            | ✔        | -        |          |
| CLOTPLAY           | ClotPlay                   | ClotPlay                   | ✔        | -        |          |
| CQ9                | CQ9                        | CQ9 (Slot)                 | ✔        | ✔        |          |
| DRAGONGAMING       | Dragon Gaming              | Dragon Gaming              | ✔        | -        |          |
| EAZYGAMING         | Eazy Gaming                | Eazy Gaming                | ✔        | -        |          |
| ENDORPHINA         | Endorphina                 | Endorphina                 | ✔        | -        |          |
| EVOPLAY            | Evoplay                    | Evoplay                    | ✔        | ✔        |          |
| EXPANSE            | Expanse                    | Expanse                    | ✔        | -        |          |
| FACHAI             | Fachai                     | Fachai                     | ✔        | -        |          |
| FUNKY              | Funky Games                | Funky Games                | ✔        | -        |          |
| FUNTA              | Funta                      | Funta                      | ✔        | -        |          |
| GOLDY              | Goldy                      | Goldy                      | ✔        | -        |          |
| HABANERO           | Habanero                   | Habanero                   | ✔        | ✔        |          |
| HACKSAW            | Hacksaw                    | Hacksaw                    | ✔        | -        |          |
| HECTICPLAY         | Hectic Play                | Hectic Play                | ✔        | -        |          |
| HOTDOG             | Hotdog                     | Hotdog                     | ✔        | ✔        |          |
| I8                 | I8                         | I8                         | ✔        | -        |          |
| JILI               | Jili                       | Jili                       | ✔        | -        |          |
| JIMI               | Jimi Gaming                | Jimi Gaming                | ✔        | -        |          |
| JOKER              | Joker123                   | Joker123                   | ✔        | ✔        |          |
| KAGAME             | KA Gaming                  | KA Gaming                  | ✔        | -        |          |
| LIVE22             | Live22                     | Live22                     | ✔        | -        |          |
| MANCALA            | Mancala Gaming             | Mancala Gaming             | ✔        | -        |          |
| MANNA              | Mannaplay                  | Mannaplay                  | ✔        | ✔        |          |
| MICRO              | Micro Gaming               | Micro Gaming               | ✔        | ✔        |          |
| MIMI               | Mimi gaming                | Mimi gaming                | ✔        | -        |          |
| NETENT             | Netent                     | Netent                     | ✔        | -        |          |
| NEXTSPIN           | Nextspin                   | Nextspin                   | ✔        | -        |          |
| NINESGAME          | Nines Game                 | Nines Game                 | ✔        | -        |          |
| NINJA              | Ninja slot                 | Ninja slot                 | ✔        | -        |          |
| NOLIMIT            | Nolimit city               | Nolimit city               | ✔        | -        |          |
| OCTOPLAY           | Penguin King               | Penguin King               | ✔        | -        |          |
| PETERNSONS         | Peter & Sons               | Peter & Sons               | ✔        | -        |          |
| PGSOFT             | PG Soft                    | PG Soft                    | ✔        | ✔        |          |
| PRAGMATICPLAY_SLOT | Pragmatic Play Slot        | Pragmatic Play Slot        | ✔        | -        |          |
| PRAGMATIC_SLOT     | Pragmatic Play Slot Global | Pragmatic Play Slot Global | ✔        | ✔        |          |
| REDTIGER           | Red Tiger                  | Red Tiger                  | ✔        | -        |          |
| RELAX              | Relax Gaming               | Relax Gaming               | ✔        | -        |          |
| RICH88             | Rich88                     | Rich88                     | ✔        | -        |          |
| ROYAL              | Royal Slot Gaming          | Royal Slot Gaming          | ✔        | ✔        |          |
| SEXY_SLOT          | Sexy Slot                  | Sexy Slot                  | ✔        | -        |          |
| SIMPLEPLAY         | Simple Play                | Simple Play                | ✔        | ✔        |          |
| SLOTOPIA           | Slotopia                   | Slotopia                   | ✔        | -        |          |
| SLOTXO             | Slotxo                     | Slotxo                     | ✔        | ✔        |          |
| SPADE              | Spade Gaming               | Spade Gaming               | ✔        | ✔        |          |
| SUNNI              | Sunni Games                | Sunni Games                | ✔        | -        |          |
| WAZDAN             | Wazdan                     | Wazdan                     | ✔        | -        |          |
| WMSLOT             | WMSlot                     | Wmslot                     | ✔        | -        |          |
| YGGDRASIL          | Yggdrasil Gaming           | Yggdrasil Gaming           | ✔        | -        |          |
| YGR                | Ygr                        | Ygr                        | ✔        | -        |          |

### Live Casino

| Product ID           | Product Name              | Description                  | Seamless | Transfer | Release |
| -------------------- | ------------------------- | ---------------------------- | -------- | -------- | ------- |
| AFB1188_LIVECASINO   | AFB1188 Livecasino        | AFB1188 (Live Casino)        | ✔        | -        |         |
| AGGAME               | Choice                    | Choice                       | ✔        | -        |         |
| ALLBET               | AllBet                    | AllBet                       | ✔        | ✔        |         |
| BETGAME              | BetgamesTV                | BetgamesTV                   | ✔        | -        |         |
| BIGGAME              | Big Gaming                | Big Gaming                   | ✔        | ✔        |         |
| CQ9_LIVECASINO       | Motivation Gaming         | Motivation Gaming            | ✔        | -        |         |
| DREAM                | Dream Gaming              | Dream Gaming                 | ✔        | ✔        |         |
| EVOLUTION            | Evolution                 | Evolution                    | ✔        | ✔        |         |
| MICRO_LIVECASINO     | Micro Gaming LiveCasino   | Micro Gaming (Live Casino)   | ✔        | -        |         |
| OFALIVE              | MT Live                   | MT Live                      | ✔        | -        |         |
| ONCASINO             | ONLive                    | ONLive                       | ✔        | -        |         |
| ONEPOWER             | One Power                 | One Power                    | ✔        | -        |         |
| PRAGMATIC_LIVECASINO | Pragmatic Play LiveCasino | Pragmatic Play (Live Casino) | ✔        | ✔        |         |
| PRETTY               | Pretty Gaming             | Pretty Gaming                | ✔        | ✔        |         |
| SAGAME               | SA Gaming                 | SA Gaming                    | ✔        | ✔        |         |
| SEXY                 | Sexy Gaming               | Sexy Gaming                  | ✔        | ✔        |         |
| VIVO                 | Vivo Gaming               | Vivo Gaming                  | ✔        | -        |         |
| WECASINO             | WE Casino                 | WE Casino                    | ✔        | -        |         |
| WINFINITY            | Winfinity                 | Winfinity                    | ✔        | -        |         |
| WM                   | WM Casino                 | WM Casino                    | ✔        | -        |         |
| YEEBET               | Yeebet                    | Yeebet                       | ✔        | -        |         |

### Sportbook

| Product ID   | Product Name | Description  | Seamless | Transfer | Release |
| ------------ | ------------ | ------------ | -------- | -------- | ------- |
| AFB1188      | AFB1188      | AFB1188      | ✔        | -        |         |
| AMBSPORTBOOK | AmbSportbook | AmbSportbook | ✔        | -        |         |
| AOG          | AOG          | AOG          | ✔        | -        |         |
| COCKFIGHT    | Cockfight    | Cockfight    | ✔        | -        |         |
| DBSPORT      | DB Sport     | DB Sport     | ✔        | -        |         |
| FB_SPORT     | FB Sport     | FB Sport     | ✔        | -        |         |
| GA28         | GA28         | GA28         | ✔        | -        |         |
| LALIKA       | Lalika       | Lalika       | ✔        | -        |         |
| MSPORT       | M-Sport      | M-Sport      | -        | ✔        |         |
| MUAYPAKYOK   | Muaypakyok   | Muaypakyok   | ✔        | -        |         |
| SABASPORTS   | Saba Sport   | Saba Sport   | ✔        | -        |         |
| SBO          | Sbobet       | Sbobet       | ✔        | -        |         |
| TFGAME       | TF Gaming    | TF Gaming    | ✔        | -        |         |
| UFABET       | Ufabet+      | Ufabet+      | ✔        | -        |         |
| UMBET        | Umbet        | Umbet        | ✔        | -        |         |

### Game Card

| Product ID | Product Name | Description | Seamless | Transfer | Release |
| ---------- | ------------ | ----------- | -------- | -------- | ------- |
| AMBPOKER   | Ambpoker     | Ambpoker    | ✔        | ✔        |         |
| KINGMAKER  | King Midas   | King Midas  | ✔        | -        |         |
| KINGPOKER  | KingPoker    | KingPoker   | ✔        | -        |         |
| KSGAME     | KS Game      | KS Game     | ✔        | ✔        |         |
| MIKIWORLD  | Miki Worlds  | Miki Worlds | ✔        | -        |         |
| MINILUCK   | Miniluck     | Miniluck    | ✔        | -        |         |

### Keno

| Product ID | Product Name | Description | Seamless | Transfer | Release |
| ---------- | ------------ | ----------- | -------- | -------- | ------- |
| KENO       | Keno         | Keno        | ✔        | -        |         |

## Language Lists

| Value | Description        |
| ----- | ------------------ |
| th    | Thai               |
| en    | English            |
| id    | Bahasa Indonesia   |
| ja    | Japanese           |
| ko    | Korean             |
| ms    | Malaysian          |
| my    | Burmese            |
| vi    | Vietnamese         |
| zh    | Simplified Chinese |

## Supported currency

| Currency | API | Report | Description       |
| -------- | --- | ------ | ----------------- |
| THB      | 1:1 | 1:1    | Thai Baht         |
| AUD      | 1:1 | 1:1    | Australian Dollar |
| BDT      | 1:1 | 1:1    | Bangladeshi Taka  |
| CNY      | 1:1 | 1:1    | Chinese Yuan      |
| EUR      | 1:1 | 1:1    | Euro              |
| GBP      | 1:1 | 1:1    | Pound sterling    |
| HKD      | 1:1 | 1:1    | Hong Kong Dollar  |
| IDR      | 1:1 | 1:1000 | Indonesian Rupiah |
| INR      | 1:1 | 1:1    | Indian Rupee      |
| JPY      | 1:1 | 1:1    | Japanese Yen      |
| KHR      | 1:1 | 1:1    | Cambodian Riel    |
| KRW      | 1:1 | 1:1    | South Korean won  |
| LAK      | 1:1 | 1:1000 | Laotian Kip       |
| MMK      | 1:1 | 1:1000 | Myanmar Kyat      |
| MYR      | 1:1 | 1:1    | Malaysian Ringgit |
| PHP      | 1:1 | 1:1    | Philippine Peso   |
| TWD      | 1:1 | 1:1    | New Taiwan Dollar |
| USD      | 1:1 | 1:1    | US Dollar         |
| USDT     | 1:1 | 1:1    | Tether (USDT)     |
| VND      | 1:1 | 1:1000 | Vietnamese Dong   |

## Supported turnOver

| Product ID     | Product Name  |
| -------------- | ------------- |
| AFB1188        | AFB1188       |
| ALLBET         | AllBet        |
| AMBPOKER       | Ambpoker      |
| AMBSPORTBOOK   | AmbSportbook  |
| AOG            | AOG           |
| BIGGAME        | Big Gaming    |
| COCKFIGHT      | Cockfight     |
| DBSPORT        | DB Sport      |
| DREAM          | Dream Gaming  |
| FB_SPORT       | FB Sport      |
| GA28           | GA28          |
| KINGMAKER      | King Midas    |
| LALIKA         | Lalika        |
| MIKIWORLD      | Miki Worlds   |
| MUAYPAKYOK     | Muaypakyok    |
| ONCASINO       | ONLive        |
| PRETTY         | Pretty Gaming |
| SABASPORTS     | Saba Sport    |
| SAGAME         | SA Gaming     |
| SBO            | Sbobet        |
| SEXY           | Sexy Gaming   |
| TFGAME         | TF Gaming     |
| UFABET         | Ufabet+       |
| UMBET          | Umbet         |
| YEEBET         | Yeebet        |
