# Me

Endpoints for the authenticated user.

## Get my user information

> Get my user information by me (logged in user)

```json
{"openapi":"3.0.3","info":{"title":"AppMaker API - OAS 3.0","version":"1.0.0"},"tags":[{"name":"me","description":"Endpoints for the authenticated user."}],"servers":[{"url":"https://abp-api.akinon.net/api/v1","description":"Production server"},{"url":"https://abptest-api.akinon.net/api/v1","description":"Test server"},{"url":"http://localhost:5001/api/v1","description":"Local server"}],"security":[{"bearerAuth":[]},{"accessToken":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT"},"accessToken":{"type":"apiKey","in":"header","name":"x-access-token"}},"responses":{"GetMeResponse":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Me"}}}},"UnauthorizedErrorResponse":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"ForbiddenErrorResponse":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}}},"schemas":{"Me":{"required":["organization","roles","userType"],"allOf":[{"$ref":"#/components/schemas/User"},{"properties":{"organization":{"$ref":"#/components/schemas/Organization"},"roles":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/Role"},{"properties":{"organization":{"$ref":"#/components/schemas/MongoId"}}}]},"description":"User roles"},"userType":{"type":"string","enum":["super-admin","admin","user"],"description":"User type","readOnly":true}}}]},"User":{"required":["_id","username","password","firstName","lastName","status","createdAt","updatedAt","lastLoginAt"],"properties":{"_id":{"$ref":"#/components/schemas/MongoId"},"username":{"type":"string","minLength":5,"maxLength":255,"description":"User username (email)"},"password":{"type":"string","minLength":3,"maxLength":255,"writeOnly":true,"description":"User password"},"language":{"type":"string","description":"User ISO 639-1 language code"},"region":{"type":"string","description":"User ISO 3166-1 alpha-2 region code"},"firstName":{"$ref":"#/components/schemas/FirstName"},"lastName":{"$ref":"#/components/schemas/LastName"},"status":{"$ref":"#/components/schemas/Status"},"attributes":{"type":"object","description":"User attributes"},"avatarUrl":{"type":"string","description":"User avatar URL"},"settings":{"type":"object","description":"User settings","properties":{"mailOnBuildCompleted":{"type":"boolean","description":"send email when build is completed"},"mailOnCodePushCompleted":{"type":"boolean","description":"send email when codepush is completed"}}},"lastLoginAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"createdAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"updatedAt":{"$ref":"#/components/schemas/ReadOnlyDate"}}},"MongoId":{"type":"string","pattern":"^[0-9a-fA-F]{24}$","description":"Entity ID"},"FirstName":{"type":"string","minLength":5,"maxLength":255,"description":"User first name"},"LastName":{"type":"string","minLength":5,"maxLength":255,"description":"User last name"},"Status":{"type":"integer","description":"Status","enum":[0,1]},"ReadOnlyDate":{"type":"string","format":"date-time","readOnly":true,"description":"Date"},"Organization":{"type":"object","required":["_id","name","slug","description","owner","isExecutive","status","privileges"],"properties":{"_id":{"$ref":"#/components/schemas/MongoId"},"name":{"type":"string","minLength":2,"maxLength":100,"description":"Organization name"},"slug":{"$ref":"#/components/schemas/Slug"},"description":{"type":"string","minLength":2,"maxLength":255,"description":"Organization description"},"owner":{"$ref":"#/components/schemas/MongoId"},"isExecutive":{"type":"boolean","description":"Organization is executive","default":false,"readOnly":true},"status":{"$ref":"#/components/schemas/Status"},"privileges":{"type":"array","items":{"type":"string"},"description":"Organization privileges, formatted as (<domain>:<action>)","default":[]},"imageUrl":{"type":"string","description":"Organization image URL"},"createdAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"updatedAt":{"$ref":"#/components/schemas/ReadOnlyDate"}}},"Slug":{"type":"string","pattern":"^[a-z0-9-]{2,100}$","minLength":2,"maxLength":100,"description":"Slug"},"Role":{"required":["name","organization","status","createdAt","updatedAt"],"properties":{"_id":{"$ref":"#/components/schemas/MongoId"},"name":{"type":"string","minLength":2,"maxLength":100,"description":"Role name"},"description":{"type":"string","description":"Role description"},"organization":{"$ref":"#/components/schemas/Organization"},"privileges":{"type":"array","items":{"type":"string"},"description":"Role privileges, formatted as (<domain>:<action>)"},"createdAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"updatedAt":{"$ref":"#/components/schemas/ReadOnlyDate"}}},"UnauthorizedError":{"type":"object","properties":{"apiError":{"type":"array","items":{"type":"string"},"description":"Error message"}}},"ForbiddenError":{"type":"object","properties":{"apiError":{"type":"array","items":{"type":"string"},"description":"Error message"}}}}},"paths":{"/me":{"get":{"tags":["me"],"summary":"Get my user information","description":"Get my user information by me (logged in user)","operationId":"getMe","responses":{"200":{"$ref":"#/components/responses/GetMeResponse"},"401":{"$ref":"#/components/responses/UnauthorizedErrorResponse"},"403":{"$ref":"#/components/responses/ForbiddenErrorResponse"}}}}}}
```

## Change my password

> Change my password by me (logged in user)

```json
{"openapi":"3.0.3","info":{"title":"AppMaker API - OAS 3.0","version":"1.0.0"},"tags":[{"name":"me","description":"Endpoints for the authenticated user."}],"servers":[{"url":"https://abp-api.akinon.net/api/v1","description":"Production server"},{"url":"https://abptest-api.akinon.net/api/v1","description":"Test server"},{"url":"http://localhost:5001/api/v1","description":"Local server"}],"security":[{"bearerAuth":[]},{"accessToken":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT"},"accessToken":{"type":"apiKey","in":"header","name":"x-access-token"}},"requestBodies":{"ChangeMyPasswordRequest":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["password","newPassword"],"properties":{"password":{"type":"string","minLength":3,"maxLength":255,"description":"User old password"},"newPassword":{"type":"string","minLength":3,"maxLength":255,"description":"User new password"}}}}}}},"responses":{"NoContentResponse":{"description":"No Content"},"ValidationErrorResponse":{"description":"Bad Request","content":{"application/json":{"schema":{"type":"object","properties":{"validationError":{"type":"object","properties":{}}}}}}},"UnauthorizedErrorResponse":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"ForbiddenErrorResponse":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}}},"schemas":{"UnauthorizedError":{"type":"object","properties":{"apiError":{"type":"array","items":{"type":"string"},"description":"Error message"}}},"ForbiddenError":{"type":"object","properties":{"apiError":{"type":"array","items":{"type":"string"},"description":"Error message"}}}}},"paths":{"/me":{"post":{"tags":["me"],"summary":"Change my password","description":"Change my password by me (logged in user)","operationId":"changeMyPassword","requestBody":{"$ref":"#/components/requestBodies/ChangeMyPasswordRequest"},"responses":{"201":{"$ref":"#/components/responses/NoContentResponse"},"400":{"$ref":"#/components/responses/ValidationErrorResponse"},"401":{"$ref":"#/components/responses/UnauthorizedErrorResponse"},"403":{"$ref":"#/components/responses/ForbiddenErrorResponse"}}}}}}
```

## Update my user information

> Update my user information by me (logged in user)

```json
{"openapi":"3.0.3","info":{"title":"AppMaker API - OAS 3.0","version":"1.0.0"},"tags":[{"name":"me","description":"Endpoints for the authenticated user."}],"servers":[{"url":"https://abp-api.akinon.net/api/v1","description":"Production server"},{"url":"https://abptest-api.akinon.net/api/v1","description":"Test server"},{"url":"http://localhost:5001/api/v1","description":"Local server"}],"security":[{"bearerAuth":[]},{"accessToken":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT"},"accessToken":{"type":"apiKey","in":"header","name":"x-access-token"}},"requestBodies":{"UpdateMeRequest":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"firstName":{"$ref":"#/components/schemas/FirstName"},"lastName":{"$ref":"#/components/schemas/LastName"},"language":{"type":"string","minLength":2,"maxLength":2,"description":"User language"},"region":{"type":"string","minLength":2,"maxLength":2,"description":"User region"},"status":{"$ref":"#/components/schemas/Status"},"avatarUrl":{"type":"string","description":"User avatar URL"},"settings":{"type":"object","description":"User settings","properties":{"mailOnBuildCompleted":{"type":"boolean","description":"Send email when build is completed"},"mailOnCodePushCompleted":{"type":"boolean","description":"Send email when codepush is completed"}}}}}}}}},"schemas":{"FirstName":{"type":"string","minLength":5,"maxLength":255,"description":"User first name"},"LastName":{"type":"string","minLength":5,"maxLength":255,"description":"User last name"},"Status":{"type":"integer","description":"Status","enum":[0,1]},"Me":{"required":["organization","roles","userType"],"allOf":[{"$ref":"#/components/schemas/User"},{"properties":{"organization":{"$ref":"#/components/schemas/Organization"},"roles":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/Role"},{"properties":{"organization":{"$ref":"#/components/schemas/MongoId"}}}]},"description":"User roles"},"userType":{"type":"string","enum":["super-admin","admin","user"],"description":"User type","readOnly":true}}}]},"User":{"required":["_id","username","password","firstName","lastName","status","createdAt","updatedAt","lastLoginAt"],"properties":{"_id":{"$ref":"#/components/schemas/MongoId"},"username":{"type":"string","minLength":5,"maxLength":255,"description":"User username (email)"},"password":{"type":"string","minLength":3,"maxLength":255,"writeOnly":true,"description":"User password"},"language":{"type":"string","description":"User ISO 639-1 language code"},"region":{"type":"string","description":"User ISO 3166-1 alpha-2 region code"},"firstName":{"$ref":"#/components/schemas/FirstName"},"lastName":{"$ref":"#/components/schemas/LastName"},"status":{"$ref":"#/components/schemas/Status"},"attributes":{"type":"object","description":"User attributes"},"avatarUrl":{"type":"string","description":"User avatar URL"},"settings":{"type":"object","description":"User settings","properties":{"mailOnBuildCompleted":{"type":"boolean","description":"send email when build is completed"},"mailOnCodePushCompleted":{"type":"boolean","description":"send email when codepush is completed"}}},"lastLoginAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"createdAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"updatedAt":{"$ref":"#/components/schemas/ReadOnlyDate"}}},"MongoId":{"type":"string","pattern":"^[0-9a-fA-F]{24}$","description":"Entity ID"},"ReadOnlyDate":{"type":"string","format":"date-time","readOnly":true,"description":"Date"},"Organization":{"type":"object","required":["_id","name","slug","description","owner","isExecutive","status","privileges"],"properties":{"_id":{"$ref":"#/components/schemas/MongoId"},"name":{"type":"string","minLength":2,"maxLength":100,"description":"Organization name"},"slug":{"$ref":"#/components/schemas/Slug"},"description":{"type":"string","minLength":2,"maxLength":255,"description":"Organization description"},"owner":{"$ref":"#/components/schemas/MongoId"},"isExecutive":{"type":"boolean","description":"Organization is executive","default":false,"readOnly":true},"status":{"$ref":"#/components/schemas/Status"},"privileges":{"type":"array","items":{"type":"string"},"description":"Organization privileges, formatted as (<domain>:<action>)","default":[]},"imageUrl":{"type":"string","description":"Organization image URL"},"createdAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"updatedAt":{"$ref":"#/components/schemas/ReadOnlyDate"}}},"Slug":{"type":"string","pattern":"^[a-z0-9-]{2,100}$","minLength":2,"maxLength":100,"description":"Slug"},"Role":{"required":["name","organization","status","createdAt","updatedAt"],"properties":{"_id":{"$ref":"#/components/schemas/MongoId"},"name":{"type":"string","minLength":2,"maxLength":100,"description":"Role name"},"description":{"type":"string","description":"Role description"},"organization":{"$ref":"#/components/schemas/Organization"},"privileges":{"type":"array","items":{"type":"string"},"description":"Role privileges, formatted as (<domain>:<action>)"},"createdAt":{"$ref":"#/components/schemas/ReadOnlyDate"},"updatedAt":{"$ref":"#/components/schemas/ReadOnlyDate"}}},"UnauthorizedError":{"type":"object","properties":{"apiError":{"type":"array","items":{"type":"string"},"description":"Error message"}}},"ForbiddenError":{"type":"object","properties":{"apiError":{"type":"array","items":{"type":"string"},"description":"Error message"}}}},"responses":{"GetMeResponse":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Me"}}}},"UnauthorizedErrorResponse":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"ForbiddenErrorResponse":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}}}},"paths":{"/me":{"patch":{"tags":["me"],"summary":"Update my user information","description":"Update my user information by me (logged in user)","operationId":"updateMe","requestBody":{"$ref":"#/components/requestBodies/UpdateMeRequest"},"responses":{"200":{"$ref":"#/components/responses/GetMeResponse"},"401":{"$ref":"#/components/responses/UnauthorizedErrorResponse"},"403":{"$ref":"#/components/responses/ForbiddenErrorResponse"}}}}}}
```
