---
title: "Login"
method: POST
path: "/api/auth/login"
tags: ["Authentication"]
---

# Login

`POST /api/auth/login`

## Request

- Base URL: `https://pegarex.com.br` (the document declares no server; this is the origin it was published from)
- URL: `https://pegarex.com.br/api/auth/login`
- Auth: none declared

Email+password login. Unverified accounts get a fresh code re-sent
instead of a session.

## Request body

- LoginRequest
  - `email` string, email, required
  - `password` string, required

## Response `200`

Successful Response

- SessionResponse
  - `user` UserResponse, required
    - `id` string, required
    - `email` string, required
    - `full_name` string, nullable
    - `avatar_url` string, nullable
    - `auth_provider` string, required
    - `email_verified` boolean, required
  - `access_token` string, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/pegarex/apis/pegarex-api.md) · [All operations](https://skmtc.dev/pegarex/apis/pegarex-api/llms.txt) · [OpenAPI document](https://skmtc.dev/pegarex/apis/pegarex-api/revisions/8c789c9bd72d?raw)
