Skip to main content
DOCS

Quickstart

Connect your editor, describe your backend in a sentence, and ship typed API calls — in five steps.

From zero to a live backend

  1. Connect your editor

    The fastest path is the CLI — it detects VS Code, Cursor, Claude Code, or Claude Desktop and writes the right MCP config:

    npx @codata-io/cli init

    Open your AI chat afterwards; your browser opens for login — approve access and you're connected.

  2. Create a workspace

    Ask your assistant, or do it from the dashboard:

    "Create a Codata workspace for a book-tracking app with
    users, books, and reading lists"

    Your agent calls workspaces-create, hands the whole need to plan_backend_change, and deploys the plan with apply_backend_plan.

  3. Generate

    Once the spec looks right, your agent calls workspaces-generate. Codata deploys the backend and returns an integration kit: a typed client file, generated types, and env entries.

  4. Install the SDK

    npm install codata-io

    The integration kit writes src/lib/codata.ts for you. Create a workspace API key from the Settings deep link and put it in .env as CODATA_API_KEY.

  5. Call your backend

    import { ws } from "@/lib/codata";
    
    const books = await ws.get("/books");
    const created = await ws.post("/books", {
      title: "The Pragmatic Programmer",
      author: "Hunt & Thomas",
    });

    Responses are fully typed from your spec — no manual interfaces, mappers, or ORMs.

Add .env, .env.local, and .codata/ to your .gitignore so secrets and the local spec cache never get committed.

Where next