---
title: "Login user (alias of /auth/login)"
method: POST
path: "/users/login"
tags: ["Users"]
---

# Login user (alias of /auth/login)

`POST /users/login`

## Request

- Base URL: `https://dummyjson.com`
- URL: `https://dummyjson.com/users/login`
- Auth: none required

## Request body

- object
  - `username` string, required
  - `password` string, required
  - `expiresInMins` integer

## Response `200`

Login success

- LoginResponse
  - `id` integer
  - `username` string
  - `email` string
  - `firstName` string
  - `lastName` string
  - `gender` string
  - `image` string
  - `accessToken` string
  - `refreshToken` string

## Other responses

- `400`: Error

---

[API](https://skmtc.dev/dummyjson/apis/dummyjson-api.md) - [All operations](https://skmtc.dev/dummyjson/apis/dummyjson-api/llms.txt) - [OpenAPI document](https://skmtc.dev/dummyjson/apis/dummyjson-api/revisions/5e704f33a559?raw)
