openapi: 3.1.0
info:
  title: ZeroCode AIDE API
  version: 1.0.1
  description: API for securely writing files into /var/www/html/projects.
servers:
  - url: https://srrrobotics.cloud/api
paths:
  /create-file:
    post:
      operationId: createFile
      summary: Create a file inside /var/www/html/projects.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                filename:
                  type: string
                  description: Name of the file to create (e.g., index.html).
                content:
                  type: string
                  description: Content to write inside the file.
              required:
                - filename
                - content
      responses:
        '200':
          description: File created successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                  message:
                    type: string
        '500':
          description: Server error.
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                  message:
                    type: string
