# 로그인

## /api/login

<mark style="color:green;">`POST`</mark> `http://localhost:8080/api/login`

이메일, 비밀번호를 통하여 로그인 요청을 할 수 있습니다.

#### Headers

| Name         | Type   | Description                    |
| ------------ | ------ | ------------------------------ |
| Content-Type | string | application/json;charset=UTF-8 |

#### Request Body

| Name     | Type   | Description |
| -------- | ------ | ----------- |
| email    | string | 이메일         |
| password | string | 비밀번호        |

{% tabs %}
{% tab title="200 인증에 필요한 access\_token 을 반환합니다." %}

```
{
    "access_token" : "Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJlbWFpbEBlbWFpbC5jb20iLCJyb2xlcyI6W3siYXV0aG9yaXR5IjoiUk9MRV9VU0VSIn1dLCJpYXQiOjE2MDMyMDUxNjcsImV4cCI6MTYwMzIwNjk2N30.A3Ee52WX-Ha0Xvv94TTUDkXpMB4fyyy0wuFxnOJLkJs"
}
```

{% endtab %}

{% tab title="400 에러 메세지를 반환합니다." %}

```
{
    "message" : "Bad Request"
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://ksyj8256.gitbook.io/login-base-token-api/undefined.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
