Users

撤销他的高级访问权限

PUT
如果用户在一段时间已经有了高级访问权限,这将缩短/撤销他的高级访问权限。 如果结束时间少于或者等于现在时间,将撤销订阅权限并将结束时间设置为现在时间,否则将缩短订阅时间。

Path parameters

handlestringRequired

文件中的 _id 或者 slug.

Request

This endpoint expects an object.
ends
stringRequired

Response

This endpoint returns an object
_id
stringOptional
email
stringOptional
name
stringOptional
slug
stringOptional
role
stringOptional
stats
objectOptional
oAuthIdentities
list of objectsOptional
subscription
objectOptional
license
objectOptional
PUT
$curl -X PUT https://koudashijie.com/api/users/%3Ahandle/shorten-subscription \
> -H "Content-Type: application/json" \
> -u "<username>:<password>" \
> -d '{
> "ends": "string"
>}'
Response
1{
2 "_id": "string",
3 "email": "string",
4 "name": "string",
5 "slug": "string",
6 "role": "string",
7 "stats": {
8 "gamesCompleted": 1,
9 "concepts": {
10 "string": 1
11 },
12 "playTime": 1
13 },
14 "oAuthIdentities": [
15 {
16 "provider": "string",
17 "id": "string"
18 }
19 ],
20 "subscription": {
21 "ends": "string",
22 "active": true
23 },
24 "license": {
25 "ends": "string",
26 "active": true
27 }
28}