-
Notifications
You must be signed in to change notification settings - Fork 1
API Calls
Tomasz Tomys edited this page May 9, 2016
·
47 revisions
/reset
/authorizations
/doctors
Reset DB to default state.
Params:
{
email: String
password: String
}
Responses:
{
login: true
user: Doctor/Patient/Admin-Entity (see e.g. GET /doctors/{id} )
}
422
{
login: false
}
Params:
{
}
Response:
{
id: Int,
name: String,
surname: String,
email: String,
pesel: String,
type: String ['patient', 'doctor', 'admin']
?specialization: String
}
Params:
{
?specialization: String
}
Response:
[
{
id: Int,
name: String,
surname: String,
email: String,
type: 'doctor'
specialization: String
}
]
Params:
{
id: Int
}
Responses:
Doctor-Entity
422
{
error: "Doctor not found"
}
Params:
{
id: Int
}
Responses:
[]
422
{
error: "Doctor not found"
}
Params:
{
id: Int
}
Body:
Doctor-Entity
Responses:
[]
422
{
error: "Doctor not found"
}
Body:
{
Doctor-Entity (without id)
}
Responses:
[]
The same as /doctors, but Patient-Entity is:
{
id: Int,
name: String,
surname: String,
email: String,
pesel: String,
type: 'patient'
}