> ## Documentation Index
> Fetch the complete documentation index at: https://docs.checkfu.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Add Projects to your app

> Create a Project from your backend and project its coordinating log and work board into your UI.

Your application keeps its authentication, business data, and user interface.
Checkfu supplies the Project aggregate, ordinary Sessions for coordinator and
work roles, governed actions, and execution lanes.

Before this guide, create or select:

* a Workspace-bound API key held only by your backend;
* a coordinator Agent and at least one work Agent;
* an Environment that defines execution authority;
* a Principal the Project's Sessions will act as; and
* model access for the models those Agents select.

Confirm [capability status](/getting-started/status). Projects stay
private-alpha until the owning plan promotes the proved slice.

<Warning>
  The Checkfu CLI and TypeScript SDK are private-alpha artifacts with no self-service public installation channel.
  The artifacts this page uses are gated behind the current private-alpha rollout.
  Confirm [capability status](/getting-started/status) before making availability part of your application's contract.
</Warning>

## Create the server-side client

```ts theme={"theme":{"light":"github-light","dark":"github-dark"}}
import { Checkfu } from "@checkfu/sdk"

const checkfu = new Checkfu({
  apiKey: process.env.CHECKFU_API_KEY!,
})
```

Never expose this client or its API key to the browser.

## Launch a Project

```ts theme={"theme":{"light":"github-light","dark":"github-dark"}}
const launched = await checkfu.launchProject({
  launchKey: `migration-${requestId}`,
  name: "API migration",
  actedAs: principalId,
  goal: "Produce a compatibility analysis and a migration guide.",
  coordinator: {
    agent: { id: coordinatorAgentId },
    environment: { id: environmentId },
  },
  work: { agents: [{ id: workAgentId }] },
  message: "Plan the two work streams.",
})
```

Retrying with the same `launchKey` rejoins the original Project and agents.
The first coordinating message claims the coordinating generation. Request
completion is not settlement.

## Follow the coordinating log

```ts theme={"theme":{"light":"github-light","dark":"github-dark"}}
const project = checkfu.project(launched.project.id)
const work = await project.startWork(workAgentId, "Draft the migration guide.")

for await (const event of project.follow()) {
  console.log(event.kind, event.seq)
  if (event.kind === "work_reported") break
}
```

`work` is an ordinary `SessionHandle`. Membership does not imply a right.
Drive, interrupt, and approvals on that Session use the same Session
operations as any other Session.

## Proxy Project reads

Expose authenticated host routes for `GET /v1/projects/{id}`, its session,
attention, and library lists, and the coordinating Session event stream. For
each request the backend must authenticate the application user, verify that
user may observe the requested Project, attach the server-held Checkfu key,
and forward only the exact upstream operation.

```tsx theme={"theme":{"light":"github-light","dark":"github-dark"}}
import { projectProxyTransport, useProject } from "@checkfu/ui/sdk"
import { ProjectView } from "@checkfu/ui"

const transport = projectProxyTransport({
  projectId,
  routePrefix: "/api/checkfu",
})
const snapshot = useProject({ projectKey: projectId, transport })

return snapshot.project === null ? null : (
  <ProjectView
    project={snapshot.project}
    sessions={snapshot.sessions}
    attention={snapshot.attention}
    library={snapshot.library}
    onSelectWork={openSession}
    onSend={(content) => postCoordinatingMessage(content)}
  />
)
```

A request for another user's Project or Session id is an isolation failure.
Do not treat it as an ordinary denied request you can hide. No Checkfu
credential belongs in browser bundles, logs, or Session content.

## What this guide omits

The optional `examples/projects-workbench/` source is not in the current
`checkfu-examples` checkout. PROJ-16 — the workbench BFF isolation proof —
remains a live qualification that needs that example and credentials.
