Apache Airflow Login API

The Login API from Apache Airflow — 2 operation(s) for login.

OpenAPI Specification

airflow-login-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Airflow Asset Login API
  description: Airflow API. All endpoints located under ``/api/v2`` can be used safely, are stable and backward compatible. Endpoints located under ``/ui`` are dedicated to the UI and are subject to breaking change depending on the need of the frontend. Users should not rely on those but use the public ones instead.
  version: '2'
tags:
- name: Login
paths:
  /api/v2/auth/login:
    get:
      tags:
      - Login
      summary: Airflow Login
      description: Redirect to the login URL depending on the AuthManager configured.
      operationId: login
      parameters:
      - name: next
        in: query
        required: false
        schema:
          anyOf:
          - type: string
          - type: 'null'
          title: Next
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '307':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPExceptionResponse'
          description: Temporary Redirect
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /api/v2/auth/logout:
    get:
      tags:
      - Login
      summary: Airflow Logout
      description: Logout the user.
      operationId: logout
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '307':
          description: Temporary Redirect
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPExceptionResponse'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    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
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    HTTPExceptionResponse:
      properties:
        detail:
          anyOf:
          - type: string
          - additionalProperties: true
            type: object
          title: Detail
      type: object
      required:
      - detail
      title: HTTPExceptionResponse
      description: HTTPException Model used for error response.
  securitySchemes:
    OAuth2PasswordBearer:
      type: oauth2
      description: To authenticate Airflow API requests, clients must include a JWT (JSON Web Token) in the Authorization header of each request. This token is used to verify the identity of the client and ensure that they have the appropriate permissions to access the requested resources. You can use the endpoint ``POST /auth/token`` in order to generate a JWT token. Upon successful authentication, the server will issue a JWT token that contains the necessary information (such as user identity and scope) to authenticate subsequent requests. To learn more about Airflow public API authentication, please read https://airflow.apache.org/docs/apache-airflow/stable/security/api.html.
      flows:
        password:
          scopes: {}
          tokenUrl: /auth/token
    HTTPBearer:
      type: http
      scheme: bearer