> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lyceum.technology/llms.txt
> Use this file to discover all available pages before exploring further.

# Login

> Login with email and password, return JWT tokens.
This JWT can be used directly with MinIO STS.



## OpenAPI

````yaml /api-reference/openapi.json post /api/v2/external/auth/login
openapi: 3.1.0
info:
  title: Lyceum Cloud API
  version: 0.1.0
servers:
  - url: https://api.lyceum.technology
    description: Production
security:
  - bearerAuth: []
paths:
  /api/v2/external/auth/login:
    post:
      tags:
        - Authentication
      summary: Login
      description: |-
        Login with email and password, return JWT tokens.
        This JWT can be used directly with MinIO STS.
      operationId: login_api_v2_external_auth_login_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/LoginRequest'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LoginResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    LoginRequest:
      properties:
        email:
          type: string
          title: Email
        password:
          type: string
          title: Password
        captcha_token:
          type: string
          minLength: 1
          title: Captcha Token
      type: object
      required:
        - email
        - password
        - captcha_token
      title: LoginRequest
    LoginResponse:
      properties:
        access_token:
          type: string
          title: Access Token
        refresh_token:
          type: string
          title: Refresh Token
        user_id:
          type: string
          title: User Id
        email:
          type: string
          title: Email
      type: object
      required:
        - access_token
        - refresh_token
        - user_id
        - email
      title: LoginResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Pass an API key (prefixed `lk_`) or a JWT access token as a bearer
        token. Generate API keys in the dashboard at
        https://dashboard.lyceum.technology/api-keys.

````