查询一般优惠券的使用

查询一般优惠券使用明细。 无法查询关键词优惠券使用明细。

请求


GET https://dashboard-api.gamepot.ntruss.com/v1/api/project/{projectId}/coupon/{couponNumber}

项目

类型

是否为必填项

描述

备注

projectId

String

O

GamePot SDK的projectId

couponNumber

String

O

仪表盘发放的优惠券编号

请求头

报头名称

是否为必填项

描述

x-api-key

O

GamePot发放的认证密钥

accept-language

X

使用语言

响应


字段名称

类型

描述

status

Int

结果值\(1:成功\)

id

String

优惠券使用明细ID

status

Boolean

是否使用优惠券\(true:使用,false:未使用\)

enable

Int

是否可用

number

String

优惠券编号

userdata

String

优惠券使用用户查询

usedAt

String

优惠券使用日期

request

String

优惠券使用请求

response

String

优惠券使用响应

(coupon_id的)id

String

优惠券ID

(coupon_id的)enable

int

是否可用

type

String

优惠券类型

keyword

String

关键词优惠券关键词

desc

String

优惠券名称

used

int

优惠券状态

count

int

优惠券数量

length

int

优惠券长度

limit

String

道具数量

prefix

String

优惠券后缀

suffix

String

优惠券前缀

store_id

String

商店ID(google,one,apple,galaxy)

startedAt

String

优惠券使用开始日期

endedAt

String

优惠券使用结束日期

item_id

String

道具ID

store_item_id

String

道具商店ID

count

int

道具数量

示例


请求示例

curl --request GET \
  --url https://dashboard-api.gamepot.ntruss.com/v1/api/project/12a0f2ff-xxxx-xxxx-xxxx-9c13ef02f5fs/coupon/xxxxxx  \
  --header 'accept-language:ko' \
  --header 'x-api-key:86dcgffae0641745432as02a8801ce5a5475f764fxxxxxxxxx'

响应示例

{
  "status":1,
  "result":{
    "id":"xxxxxxxxxxxxxxxx",
    "status":false,
    "enable":1,
    "number":"xxxxxxxxxxxxxxxx",
    "userdata":"",
    "usedAt":null,
    "createdAt":"Wed May 13 2020 12:12:04 GMT+0900 (Korean Standard Time)",
    "request":null,
    "response":null,
    "coupon_id":{
      "id":"xxxxxxxxxxxxxxxx",
      "enable":1,
      "type":"normal",
      "keyword":null,
      "desc":"第2季更新提前预约奖励",
      "used":1,
      "count":2010,
      "length":7,
      "limit":null,
      "prefix":"",
      "suffix":"",
      "store_id":"",
      "startedAt":"Sun May 10 2020 16:35:00 GMT+0900 (Korean Standard Time)",
      "endedAt":"Sat May 23 2020 16:35:00 GMT+0900 (Korean Standard Time)",
      "items":[
        {
          "item_id":"xxxxxxxxxxxxxxxx",
          "store_item_id":"xxxxxxxxxxxxxxxx",
          "count":10
        },
        {
          "item_id":"xxxxxxxxxxxxxxxx",
          "store_item_id":"xxxxxxxxxxxxxxxx",
          "count":1
        }
      ]
    }
  }
}

错误代码


发送Gamepot Open API请求时发生的通用错误代码。

参数

描述

status

错误代码\(1:成功,失败时请参考Error code\)

message

错误详细描述

错误代码

描述

-1

使用了仪表盘上没有的密钥时

-2

仪表盘密钥和报头的密钥不同时

-3

使用了仪表盘已删除的密钥时

-4

使用了仪表盘中作为未使用处理的密钥时

-5

密钥到期时

-6

没有项目ID时

{
    "status":-6,
    "message":"projectId was wrong."
}

Last updated