openapi: 3.0.0
info:
  title: AktoraERP API
  version: '1.0'
paths:
  /auth/register:
    post:
      summary: Register a new user
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                email:
                  type: string
                password:
                  type: string
      responses:
        '201':
          description: Registered
  /auth/login:
    post:
      summary: Login and get token
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                password:
                  type: string
      responses:
        '200':
          description: Token response
  /tenants:
    get:
      summary: List tenants
      security:
        - bearerAuth: []
      responses:
        '200':
          description: ok
    post:
      summary: Create tenant
      security:
        - bearerAuth: []
      responses:
        '201':
          description: created
  /tenants/{id}:
    get:
      summary: Tenant details
      security:
        - bearerAuth: []
      parameters:
        - in: path
          name: id
          required: true
          schema:
            type: string
      responses:
        '200':
          description: ok
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
