Bladeren bron

兑换码

Jason 2 weken geleden
bovenliggende
commit
3934c1ce60
7 gewijzigde bestanden met toevoegingen van 158 en 28 verwijderingen
  1. 1 0
      en/_sidebar.md
  2. 3 15
      en/currency.md
  3. 5 0
      en/invoke_method.md
  4. 74 0
      en/redeemcode_credate.md
  5. 1 0
      zh/_sidebar.md
  6. 1 13
      zh/currency.md
  7. 73 0
      zh/redeemcode_credate.md

+ 1 - 0
en/_sidebar.md

@@ -18,6 +18,7 @@
   * [Query Total Win Specific Players](en/user_win_result)
   * [Query Total Win All Players](en/all_user_win_result)
   * [Change Password](en/change_password)
+  * [RedeemCode](en/redeemcode_credate)
 * [Appendix](en/appendix)
   * [Currency List](en/currency)
   * [Languages](en/language)

+ 3 - 15
en/currency.md

@@ -1,17 +1,5 @@
 # <font>Currency List</font>
 
-| Currency ID | Currency Code | Description                |
-|-------------|----------------|----------------------------|
-| 1           | USD            | US Dollar                 |
-| 2           | CAD            | Canadian Dollar           |
-| 3           | BRL            | Brazilian Real            |
-| 4           | MXN            | Mexican Peso              |
-| 5           | GBP            | British Pound             |
-| 6           | EUR            | Euro                      |
-| 7           | AUD            | Australian Dollar         |
-| 8           | NZD            | New Zealand Dollar        |
-| 9           | SGD            | Singapore Dollar          |
-| 10          | BND            | Brunei Dollar             |
-| 11          | MYR            | Malaysian Ringgit         |
-| 12          | THB            | Thai Baht                 |
-| 13          | PGK            | Papua New Guinean Kina         |
+| Currency ID | Currency Code | Description            |
+| ----------- | ------------- | ---------------------- |
+| 1           | PGK           | Papua New Guinean Kina |

+ 5 - 0
en/invoke_method.md

@@ -0,0 +1,5 @@
+# <font>Invocation Method</font>
+
+- The API supports both **HTTP POST** and **HTTP GET** methods.  
+- 
+- When using **HTTP GET**, all parameters **must be URL-encoded**.

+ 74 - 0
en/redeemcode_credate.md

@@ -0,0 +1,74 @@
+# <font>Generate Redeem Code</font>
+
+## Request URL
+>{API_URL}
+
+## Request Parameters
+
+| Field Name    | Type   | Length | Description |                                                           |
+| ------------- | ------ | ------ | ----------- | --------------------------------------------------------- |
+| itype         | string | 21     | Yes         | 30 = Generate Redeem Code                                 |
+| authcode      | string | 32     | Yes         | Agent identifier, assigned by the provider                |
+| authkey       | string | 32     | Yes         | Agent secret key, assigned by the provider                |
+| info          | string | 128    | Yes         | Redeem code identifier                                    |
+| quantity      | int    | 32     | Yes         | Generate the number of redeem codes                       |
+| type          | int    | 32     | Yes         | Type :1= Unique code, 2= Shared code                      |
+| exchangelimit | int    | 32     | Yes         | The number of times each code can be redeemed             |
+| accountlimit  | int    | 32     | Yes         | The number of times each code can be redeemed per account |
+| score         | int64  | 64     | Yes         | Denomination of the exchange code                         |
+| st            | int64  | 64     | Yes         | The starting time of the validity period                  |
+| et            | int64  | 64     | Yes         | Expiration time of validity period                        |
+
+
+## Example
+
+- **URL**:
+    - {API_URL}
+
+- **HTTP Method**:
+    - `POST`
+
+- **Form Data**:  
+    > Content-Type: `application/x-www-form-urlencoded`
+
+    ```
+    itype           :30
+    authcode        :test666
+    authkey         :KepYRwz4mOP3THAcfiQb
+    info            :National Day Activity
+    quantity        :10
+    type            :2
+    exchangelimit   :10
+    accountlimit    :2
+    score           :1000
+    st              :1758272961261
+    et              :1758652455165
+    ```
+
+## Response Fields
+
+| Field Name | Type | Length | Description                                           |
+| ---------- | ---- | ------ | ----------------------------------------------------- |
+| ret        | int  | 32     | -1 indicates success; other than -1 indicates failure |
+| data       | arr  | 2048   | the array of  redeem code    created                |
+
+## Response Format
+
+```
+{
+	"ret": -1,
+    "info": "ok",
+	"data": [
+		"29EZ3V",
+		"4DQNMU",
+		"59NW2Q",
+		"CZX79Z",
+		"DDUWYR",
+		"M6FP3L",
+		"N53J44",
+		"PBFYHS",
+		"QXQWZN",
+		"USYFQN"
+	]
+}
+```

+ 1 - 0
zh/_sidebar.md

@@ -18,6 +18,7 @@
   * [查询部分玩家总赢回](zh/user_win_result)
   * [查询所有玩家总赢回](zh/all_user_win_result)
   * [修改密码](zh/change_password)
+  * [修改密码](zh/redeemcode_credate)
 * [附录](zh/appendix)
   * [货币列表](zh/currency)
   * [语言](zh/language)

+ 1 - 13
zh/currency.md

@@ -2,16 +2,4 @@
 
 | 货币 ID | 货币代码 | 说明               |
 | ------- | -------- | ------------------ |
-| 1       | USD      | 美元               |
-| 2       | CAD      | 加拿大元           |
-| 3       | BRL      | 巴西雷亚尔         |
-| 4       | MXN      | 墨西哥比索         |
-| 5       | GBP      | 英镑               |
-| 6       | EUR      | 欧元               |
-| 7       | AUD      | 澳元               |
-| 8       | NZD      | 新西兰元           |
-| 9       | SGD      | 新加坡元           |
-| 10      | BND      | 文莱元             |
-| 11      | MYR      | 马来西亚林吉特     |
-| 12      | THB      | 泰铢               |
-| 13      | PGK      | 巴布亚新几内亚基那 |
+| 1      | PGK      | 巴布亚新几内亚基那 |

+ 73 - 0
zh/redeemcode_credate.md

@@ -0,0 +1,73 @@
+# <font>创建兑换码</font>
+
+## 请求地址
+>{API_URL}
+
+## 请求参数
+
+| 字段名称      | 类型   | 长度 | 必要 | 描述                    |
+| ------------- | ------ | ---- | ---- | ----------------------- |
+| itype         | string | 21   | 是   | 30 = 生成兑换码   |
+| authcode      | string | 32   | 是   | 代理标识,由厂商配发    |
+| authkey       | string | 32   | 是   | 代理秘钥,由厂商配发    |
+| info          | string | 128  | 是   | 兑换码标识              |
+| quantity      | int    | 32   | 是   | 生成兑换码数量          |
+| type          | int    | 32   | 是   | 类型:1=唯一码, 2=共享码 |
+| exchangelimit | int    | 32   | 是   | 每个码的兑换次数        |
+| accountlimit  |        | int  | 是   | 每个码单个账号兑换次数  |
+| score         | int64  | 64   | 是   | 兑换码面额              |
+| st            | int64  | 64   | 是   | 有效期起始时间          |
+| ed            | int64  | 64   | 是   | 有效期结束时间          |
+
+## 示例
+
+- **URL**:
+    - {API_URL}
+
+- **HTTP Method**(请求方式):
+    - `POST`
+
+- **表单数据**:
+    > Content-Type: `application/x-www-form-urlencoded`
+
+    ```
+    itype           :30
+    authcode        :test666
+    authkey         :KepYRwz4mOP3THAcfiQb
+    info            :National Day Activity
+    quantity        :10
+    type            :2
+    exchangelimit   :10
+    accountlimit    :2
+    score           :1000
+    st              :1758272961261
+    et              :1758652455165
+    ```
+
+## 返回结果
+
+| 字段名称 | 类型   | 长度 | 说明                     |
+| -------- | ------ | ---- | ------------------------ |
+| ret      | int    | 32   | -1 表示成功,非 -1 表示失败 |
+| data     | arr | 2048  | 返回创建的兑换码code             |
+
+## 返回格式
+
+```
+{
+	"ret": -1,
+    "info": "ok",
+	"data": [
+		"29EZ3V",
+		"4DQNMU",
+		"59NW2Q",
+		"CZX79Z",
+		"DDUWYR",
+		"M6FP3L",
+		"N53J44",
+		"PBFYHS",
+		"QXQWZN",
+		"USYFQN"
+	]
+}
+```