Skip to content

Profile

olesh2602 edited this page Dec 18, 2019 · 5 revisions

Profile

type access route prefix
Private For authorized users /profile

Routes

name access route type headers
User information authorized /getInformation POST Authorization: Bearer <access token>
Edit profile authorized /edit POST Authorization: Bearer <access token>
Change password authorized /changePassword POST Authorization: Bearer <access token>

JSON Schema

User information

#Request
{}
#Response
{
	"user": "Object"
}

Errors:

name description error const

Edit profile

#Request
{
	"address": "String",
	"name": "String",
}
#Response
{
	"id": "Number",
        "name": "String",
        "address": "String",
}

Errors:

name description error const

Change password

#Request
{
	"oldPassword": "String",
	"newPassword": "String",
}
#Response
{
	"passwordWasChanged": "Boolean",
}

Errors:

name description error const

Clone this wiki locally