POST
/
users
Example
url = 'https://codecombat.com/api/users'
json = { email: 'an@email.com', name: 'Some Username', role: 'student' }
request.post({ url, json, auth })

Authorizations

Authorization
string
headerrequired

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Body

application/json
name
string
required
email
string
required
role
enum<string> | null

"student" or "teacher". If unset, a home user will be created, unable to join classrooms.

Available options:
student,
teacher
preferredLanguage
string | null
heroConfig
object | null
birthday
string | null

Response

200 - application/json
_id
string | null
email
string | null
name
string | null
slug
string | null
role
string | null

Usually either 'teacher' or 'student'

stats
object | null
oAuthIdentities
object[] | null
subscription
object | null
license
object | null