---
title: "check if login & pass correspond to values in DB and return JWT token"
method: POST
path: "/login"
---

# check if login & pass correspond to values in DB and return JWT token

`POST /login`

## Request body

- Login
  - `teamname` string
  - `password` string

## Response `200`

successful operation

- object
  - `bot` Bot
    - `id` integer
    - `team_id` string
    - `admin` boolean
    - `team_name` string
    - `password` string
    - `language` 'ru_Ru' | 'en_US' — bot language
    - `notifier_interval` integer
    - `reminder_repeat_max` integer
    - `reminder_time` integer
    - `reporting_channel` string
    - `reporting_time` string
    - `individual_reports_on` boolean
  - `token` string — JWT access token

## Other responses

- `400` — Invalid login/password
- `500` — Internal Error

## Changes

- **2019-04-09** `5363057b67b0` — 2 warning
  - deleted the `query` request parameter `password`
  - deleted the `query` request parameter `teamname`
- **2019-04-04** `14e268f15cf7` — 2 breaking
  - added the new required `query` request parameter `password`
  - added the new required `query` request parameter `teamname`
- **2019-03-27** `07d9552ad3fa` — 4 info
  - added the non-success response with the status `400`
  - added the non-success response with the status `500`
  - removed the non-success response with the status `401`
  - removed the non-success response with the status `404`
- **2019-03-25** `78fbfa24e940` — 1 info
  - endpoint added
- **2019-03-13** `ea0deca478db` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/maddevsio/apis/mad-devs-comedian/changes/login/post.md)

---

[API](https://skmtc.dev/maddevsio/apis/mad-devs-comedian.md) · [All operations](https://skmtc.dev/maddevsio/apis/mad-devs-comedian/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/maddevsio/mad-devs-comedian/revisions/db207131dfd9/schema)
