---
title: "Login and get a session token"
method: POST
path: "/v1/auth/login"
tags: ["Auth"]
---

# Login and get a session token

`POST /v1/auth/login`

## Request

- Base URL: `https://api.algenta.ai`
- URL: `https://api.algenta.ai/v1/auth/login`
- Auth: none declared

Returns a JWT bearer token valid for 7 days. Use as `Authorization: Bearer <token>`.

## Request body

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

## Response `200`

Successful Response

- TokenResponse
  - `access_token` string, required
  - `token_type` string
  - `expires_in` integer, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/codna/apis/algenta-api.md) · [All operations](https://skmtc.dev/codna/apis/algenta-api/llms.txt) · [OpenAPI document](https://skmtc.dev/codna/apis/algenta-api/revisions/35d30f84a5df?raw)
