LogoLogo
PostmanOpenAPIContact usSign up
  • Overview
    • Introduction
  • API Reference
    • POSTAdd Oauth2 Identity
PostmanOpenAPIContact usSign up
API ReferenceUsers

Get User Hero

PUT
https://codecombat.com/api/users/:handle/hero-config
PUT
/api/users/:handle/hero-config
1curl -X PUT https://codecombat.com/api/users/:handle/hero-config \
2 -H "Content-Type: application/json" \
3 -u "<username>:<password>" \
4 -d '{}'
Try it
200Updated
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}
Set the user's hero.

Path parameters

handlestringRequired
The document's `_id` or `slug`.

Headers

AuthorizationstringRequired
Basic authentication of the form `Basic <username:password>`.

Request

This endpoint expects an object.
thangTypestringOptional

Response

This endpoint returns an object.
_idstring or null
emailstring or null
namestring or null
slugstring or null
rolestring or null
Usually either 'teacher' or 'student'
statsobject or null
oAuthIdentitieslist of objects or null
subscriptionobject or null
licenseobject or null
Was this page helpful?
Previous

Put Ace Config

Next
Built with

The document’s _id or slug.

Basic authentication of the form Basic <username:password>.