3.11 Demo Launch Lobby (取得试玩进入游戏大厅网址)

Notice (注意事项)

  • Bets and results are excluded from all report APIs.
    注单与结果不会出现在任何报表 API。

Description (说明)

This API call is used to launch the HRG lobby in demo mode.
本功能用于开启 HRG 游戏大厅的试玩模式。

URL (网址)

https://{host}/api/demo_launch_lobby

Request Method

POST

Request Parameters (请求参数)

Field
(栏位)
Type
(型态)
Required
(必要)
Description
(说明)
agentIdStringYAgent ID <= 50 characters
代理帐号
langStringNLanguage fixed 2 characters
语言

default: EN
预设: EN

Please refer to 5.3 Languages for details.
详情请参考 5.3 语言
soundBooleanNEnable Sound
启用声音

default: true
预设: true
homePageUrlStringNSpecify the url to return to the operator's home page. <= 3000 characters
指定返回营运商主页的 URL

need to set http:// or https://
需要设置 http:// or https://
{
  "agentId": "hrgag",
  "lang": "EN",
  "sound": true,
  "homePageUrl": "https://www.google.com"
}

Return Result (返回结果)

Field
(栏位)
Type
(型态)
Description
(说明)
codeStringStatus Code fixed 4 characters
状态码

Please refer to 5.4 Status Code for details.
详情请参考 5.4 状态代码
dataObject
urlStringLobby URL
游戏大厅链结
{
  "code": "0000",
  "data": {
    "url": "https://{lobby}/?lang=EN&sound=true&isTopWindowRedirect=Y&x=Q2cA1qPvyUo26TzfM_dUgWTV5wDQ1gbAt8AgyEYgFAfOO1iopp1DEEwppfwW92akPCbsbp-Cmk95KXGiNEntz1nG2aRUcGnfex4UlCBTWdhhXchsyws5B1Xwt4QeP10d1t6JCqE77peH5IyHcdu41w=="
  }
}

Sample Request For Each Language (各语言请求范例)

SimpleDateFormat xtsFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
xtsFormat.setTimeZone(TimeZone.getTimeZone("GMT+8"));
String xts = xtsFormat.format(new Date());

OkHttpClient client = new OkHttpClient().newBuilder()
  .build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"agentId\":\"hrgag\",\"lang\":\"EN\",\"sound\":true,\"homePageUrl\":\"https://www.google.com\"}");
Request request = new Request.Builder()
  .url("https://{host}/api/demo_launch_lobby")
  .method("POST", body)
  .addHeader("Authorization", "Basic dGVzdDp0ZXN0")
  .addHeader("xts", xts)
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();