---
title: "login with email and password"
method: POST
path: "/v1/users/login-with-email"
tags: ["Auth"]
---

# login with email and password

`POST /v1/users/login-with-email`

## Request

- Base URL: `https://api.chat.ethora.com`
- URL: `https://api.chat.ethora.com/v1/users/login-with-email`
- Auth: none required

**Auth**: None (appId required; legacy App JWT accepted)

End user login endpoint, should be used with Authorization header set to App JWT.
Ethora App JWT example: JWT eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJkYXRhIjp7Il9pZCI6IjYxZTU1YzlkOTBlYTk5NTk0YmM3ZTZhMiIsImFwcE5hbWUiOiJFdGhvcmEiLCJhcHBHb29nbGVJZCI6Ijk3MjkzMzQ3MDA1NC1oYnNmMjlvaHBhdG83NnRpbDJqdGY2amdnMWI0Mzc0Yy5hcHBzLmdvb2dsZXVzZXJjb250ZW50LmNvbSIsImNyZWF0b3JJZCI6IjYyYzNmNGE5M2FkMjcwNjc0YzFmNjJmYiIsImNyZWF0ZWRBdCI6IjIwMjItMDctMDVUMDg6Mjc6MjYuMzM2WiIsIl9fdiI6MH0sImlhdCI6MTY1NzAwOTY1OH0.dnvrO_dQ_2GLyUX-b71CcHFDnphpjeTYOxz6vZ2fsPY


Provide `appId` in the request body to resolve app context. Legacy `Authorization` app token is also accepted for backward compatibility.

## Request body

- object
  - `email` string: Account email address. Must match an existing user under the calling app context.
  - `password` string: Account password. 8+ characters in practice; weaker passwords are rejected with `WRONG_CREDENTIALS`.
  - `appId` string: Application id used to resolve tenant/app context.

## Response `200`

```
{
  success: boolean,
  user: {
    defaultWallet: {
      walletAddress: string
    },
    isSuperAdmin: {
      read: boolean,
      write: boolean
    },
    _id: string,
    firstName: string,
    lastName: string,
    email: string,
    username: string,
    tags: string[],
    profileImage: string,
    emails: [
      {
        loginType: string,
        email: string,
        verified: boolean,
        _id: string
      }
    ],
    appId: string,
    xmppPassword: string,
    roles: string[],
    isProfileOpen: boolean,
    isAssetsOpen: boolean,
    isAgreeWithTerms: boolean,
    homeScreen: string,
    registrationChannelType: string,
    createdAt: string,
    updatedAt: string
  },
  token: string,
  refreshToken: string
}
```

- LoginSuccessResponse
  - `success` boolean, required
  - `token` string, required
  - `refreshToken` string, required
  - `wsToken` string
  - `user` UserPublic, required
    - `_id` string
    - `uuid` string, nullable
    - `xmppUsername` string
    - `email` string, nullable
    - `firstName` string, nullable
    - `lastName` string, nullable
    - `username` string, nullable
    - `profileImage` string, nullable
    - `profilePicture` string, nullable
    - `description` string, nullable
    - `tags` string[], nullable
  - `isAllowedNewAppCreate` boolean, nullable

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `422`: ``` { error: string } ```
- `500`: Internal Server Error

---

[API](https://skmtc.dev/ethora/apis/platform-api.md) · [All operations](https://skmtc.dev/ethora/apis/platform-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ethora/apis/platform-api/revisions/01b6e64378ee?raw)
