{
  "openapi": "3.1.0",
  "info": {
    "title": "AtlasisAI Public API",
    "version": "0.1.0",
    "description": "Scoped public API for approved AI assistants, developers, and partners to route public-safe Atlas AIOS requests."
  },
  "servers": [
    {
      "url": "https://api.atlasisai.com",
      "description": "Planned public API domain"
    }
  ],
  "security": [
    {
      "BearerApiKey": []
    }
  ],
  "paths": {
    "/v1/health": {
      "get": {
        "operationId": "atlas_health",
        "summary": "Health",
        "description": "Check public API availability. Required scope: `atlas:read_public`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:read_public"
      }
    },
    "/v1/capabilities": {
      "get": {
        "operationId": "atlas_capabilities",
        "summary": "Capabilities",
        "description": "List public-safe Atlas capabilities and scopes. Required scope: `atlas:read_public`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:read_public"
      }
    },
    "/v1/route": {
      "post": {
        "operationId": "atlas_route_request",
        "summary": "Route request",
        "description": "Recommend the right Atlas lane for a business request. Required scope: `atlas:route`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:route",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": false,
                "properties": {
                  "request": {
                    "type": "string",
                    "maxLength": 4000
                  },
                  "public_url": {
                    "type": "string"
                  },
                  "business_type": {
                    "type": "string"
                  }
                },
                "required": [
                  "request"
                ]
              }
            }
          }
        }
      }
    },
    "/v1/review/url": {
      "post": {
        "operationId": "atlas_review_public_url",
        "summary": "Review public URL",
        "description": "Queue a public website clarity and AI visibility review. Required scope: `atlas:review_url`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:review_url",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": false,
                "properties": {
                  "url": {
                    "type": "string"
                  },
                  "review_type": {
                    "type": "string",
                    "default": "ai_visibility_starter"
                  }
                },
                "required": [
                  "url"
                ]
              }
            }
          }
        }
      }
    },
    "/v1/playbooks/recommend": {
      "post": {
        "operationId": "atlas_recommend_playbook",
        "summary": "Recommend playbook",
        "description": "Recommend a playbook from a public-safe workflow problem. Required scope: `atlas:recommend_playbook`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:recommend_playbook",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": true,
                "properties": {
                  "workflow_problem": {
                    "type": "string"
                  },
                  "workflow": {
                    "type": "string"
                  },
                  "business_type": {
                    "type": "string"
                  },
                  "tools": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/v1/agent-pack/scope": {
      "post": {
        "operationId": "atlas_scope_agent_pack",
        "summary": "Scope agent pack",
        "description": "Create an agent-pack scope draft. Required scope: `atlas:scope_agent_pack`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:scope_agent_pack",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": true,
                "properties": {
                  "workflow_problem": {
                    "type": "string"
                  },
                  "workflow": {
                    "type": "string"
                  },
                  "business_type": {
                    "type": "string"
                  },
                  "tools": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/v1/project-factory/scope": {
      "post": {
        "operationId": "atlas_scope_project_factory",
        "summary": "Scope project factory",
        "description": "Create a Project Factory scope draft. Required scope: `atlas:scope_project`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:scope_project",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": true,
                "properties": {
                  "workflow_problem": {
                    "type": "string"
                  },
                  "workflow": {
                    "type": "string"
                  },
                  "business_type": {
                    "type": "string"
                  },
                  "tools": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/v1/proof/checklist": {
      "post": {
        "operationId": "atlas_proof_checklist",
        "summary": "Proof checklist",
        "description": "Create a proof checklist for a proposed workflow. Required scope: `atlas:proof_checklist`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:proof_checklist",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": true,
                "properties": {
                  "workflow_problem": {
                    "type": "string"
                  },
                  "workflow": {
                    "type": "string"
                  },
                  "business_type": {
                    "type": "string"
                  },
                  "tools": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/v1/jobs": {
      "post": {
        "operationId": "atlas_create_job",
        "summary": "Create job",
        "description": "Create a public-safe job that the outbound Atlas bridge can poll. Required scope: `atlas:create_job`. Rate limits apply. This endpoint does not provide direct local file, Gmail, shell, Docker, Codex, private memory, or local model access.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          },
          "400": {
            "description": "Request blocked or invalid",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Missing scope or terms acceptance",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:create_job",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "job_type",
                  "payload"
                ],
                "properties": {
                  "job_type": {
                    "type": "string"
                  },
                  "payload": {
                    "type": "object"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/v1/jobs/{job_id}": {
      "get": {
        "operationId": "atlas_get_job",
        "summary": "Get job status",
        "description": "Read a queued Atlas public API job by ID. Required scope: `atlas:read_job`.",
        "security": [
          {
            "BearerApiKey": []
          }
        ],
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Job status",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AtlasResponse"
                }
              }
            }
          }
        },
        "x-atlas-required-scope": "atlas:read_job"
      }
    }
  },
  "components": {
    "securitySchemes": {
      "BearerApiKey": {
        "type": "http",
        "scheme": "bearer"
      }
    },
    "schemas": {
      "AtlasResponse": {
        "type": "object",
        "properties": {
          "ok": {
            "type": "boolean"
          },
          "status": {
            "type": "string"
          },
          "job_id": {
            "type": "string"
          },
          "result": {
            "type": "object"
          }
        }
      },
      "ErrorResponse": {
        "type": "object",
        "properties": {
          "ok": {
            "type": "boolean"
          },
          "error": {
            "type": "string"
          },
          "message": {
            "type": "string"
          }
        }
      }
    }
  },
  "x-atlas-public-scopes": [
    "atlas:read_public",
    "atlas:route",
    "atlas:review_url",
    "atlas:recommend_playbook",
    "atlas:scope_agent_pack",
    "atlas:scope_project",
    "atlas:create_job",
    "atlas:read_job",
    "atlas:proof_checklist"
  ],
  "x-atlas-external-actions": {
    "emails_sent": 0,
    "posts_published": 0,
    "payments_charged": 0,
    "delivery_unlocked": 0
  }
}
