文档
测试

discountCardDetail

POST
api/v1/discountCardDetail

接口描述

优惠劵信息

请求参数

参数名
类型
描述
必填
user_id
integer
用户id
必填
token
integer
用户token
必填
status
integer
状态1未使用2已使用3.已过期
必填
page
integer
页数
必填

php

$client = new \GuzzleHttp\Client(); $response = $client->post( 'http://sns.shenruxiang.com/api/v1/discountCardDetail', [ 'headers' => [ 'Content-Type' => 'application/json', 'Accept' => 'application/json', ], 'json' => [ 'user_id' => 2, 'token' => 3, 'status' => 11, 'page' => 5, ], ] ); $body = $response->getBody(); print_r(json_decode((string) $body));

js

const url = new URL( "http://sns.shenruxiang.com/api/v1/discountCardDetail" ); let headers = { "Content-Type": "application/json", "Accept": "application/json", }; let body = { "user_id": 2, "token": 3, "status": 11, "page": 5 } fetch(url, { method: "POST", headers: headers, body: body }) .then(response => response.json()) .then(json => console.log(json));

返回值

{ "code": 0, "msg": "请求成功", "data": [ { "limit_num": "10【满limit_num减price 比如满10减2 】", "source": "全场通用(推荐新用户所得)【内容】", "price": "2【价格】", "status": "1【状态1未使用2已使用3.已过期】", "start_time": "2020-09-01 09:33:21【开始时间】", "end_time": "2020-09-29 09:33:30【结束时间】" }, { "limit_num": "10【满limit_num减price 比如满10减2 】", "source": "全场通用(推荐新用户所得)【内容】", "price": "2【价格】", "status": "1【状态1未使用2已使用3.已过期】", "start_time": "2020-09-01 09:33:21【开始时间】", "end_time": "2020-09-29 09:33:30【结束时间】" } ] }

bash

curl -X POST \ "http://sns.shenruxiang.com/api/v1/discountCardDetail" \ -H "Content-Type: application/json" \ -H "Accept: application/json" \ -d '{"user_id":2,"token":3,"status":11,"page":5}'