English
1import requests23url = "https://codecombat.com/api/users/%3Ahandle/subscription"45payload = { "ends": "string" }6headers = {7 "Authorization": "Basic <username>:<password>",8 "Content-Type": "application/json"9}1011response = requests.put(url, json=payload, headers=headers)1213print(response.json())
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": 111 },12 "playTime": 113 },14 "oAuthIdentities": [15 {16 "provider": "string",17 "id": "string"18 }19 ],20 "subscription": {21 "ends": "string",22 "active": true23 },24 "license": {25 "ends": "string",26 "active": true27 }28}
The document’s _id or slug.
_id
slug
Basic authentication of the form Basic <username:password>.
Basic <username:password>