Get a list of all users.
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/users.json#",
"type": "object",
"additionalProperties": false,
"required": [
"users"
],
"properties": {
"users": {
"type": "array",
"minItems": 0,
"items": {
"$ref": "http://schema.envirocar.org/user.json#"
}
}
}
}
{
"users": [
{
"name": "test1",
"mail": "test1@example.de",
"created": "2013-06-25T09:56:13Z",
"modified": "2013-07-01T14:19:19Z"
},
{
"name": "test2",
"mail": "test2@example.de",
"created": "2013-06-25T07:56:10Z",
"modified": "2013-07-01T18:19:36Z"
}
]
}
Get the user user
.
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/user.json#",
"type": "object",
"required": [
"name"
],
"allOf": [
{
"$ref": "http://schema.envirocar.org/definitions.json#/optional-user-properties"
},
{
"properties": {
"created": {
"type": "string",
"format": "date-time"
},
"mail": {
"$ref": "http://schema.envirocar.org/definitions.json#/mail"
},
"modified": {
"type": "string",
"format": "date-time"
},
"name": {
"$ref": "http://schema.envirocar.org/definitions.json#/username"
}
}
}
]
}
{
"country": "Germany",
"created": "2013-06-25T09:56:13Z",
"dayOfBirth": "1989-01-01",
"firstName": "Jakob",
"gender": "m",
"language": "de-DE",
"lastName": "M",
"mail": "jakob@jakob.de",
"modified": "2013-07-10T08:30:04Z",
"name": "jakob1"
}
Creates a new user.
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/user.create.json#",
"type": "object",
"required": [
"name",
"mail",
"token"
],
"allOf": [
{
"$ref": "http://schema.envirocar.org/definitions.json#/optional-user-properties"
},
{
"properties": {
"name": {
"$ref": "http://schema.envirocar.org/definitions.json#/username"
},
"mail": {
"$ref": "http://schema.envirocar.org/definitions.json#/mail"
},
"token": {
"type": "string"
}
}
}
]
}
{
"name": "NewUserName",
"mail": "test@testmail.com",
"token": "testtoken"
}
Updates the user user
.
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/user.modify.json#",
"type": "object",
"allOf": [
{
"$ref": "http://schema.envirocar.org/definitions.json#/optional-user-properties"
},
{
"properties": {
"mail": {
"$ref": "http://schema.envirocar.org/definitions.json#/mail"
},
"token": {
"type": "string"
}
}
}
]
}
{
"mail": "test@example.de",
"token": "NewToken",
"firstname": "NewFirstName",
"lastname": "NewLastName"
}
Deletes the user user
.