Public DocsRoute-backed sectionsUpdated July 24, 2026

Clivly docs that match the product you ship today

Install the CLI, scaffold your routes, and connect your database to Clivly. Every step below is its own page, so you can deep-link straight to the one you need.

What Changed In This Refresh
The previous page was accurate in parts, but it no longer mirrored the current integration path closely enough.

Lead with `clivly@next`, not the older stable line.

Added `create-clivly`, `connect()`, `doctor()`, and `cursorStore` guidance.

Separated framework recipes from widget and auth setup.

Kept better-auth, remote sync, and serverless guidance current.

Best first path
Quickstart → CLI
Scaffold, pair, set your keys, then mount the routes.
Docs structure
10 pages
Overview plus nine focused sections with stable URLs.
Public surface
8 packages
SDK, CLI, chat widget, auth adapters, scaffolder.
Recommended pathFor July 2026
Use the docs like a guided integration, not a long scroll
Clivly now spans a consolidated runtime package, a CLI, optional auth adapters, a chat widget, and multiple framework recipes. The new docs route mirrors that shape so each concern lives on its own page.

01

Scaffold and pair

`npx clivly init` scaffolds the config and routes; `npx clivly login` pairs the app with your org.

02

Set the two keys

Keep `CLIVLY_SECRET_KEY` server-side. `CLIVLY_PUBLISHABLE_KEY` is the only one safe in the browser.

03

Pick the right entry point

Define the SDK once, then choose `connect()`, `start()`, or `runScheduled()` based on the runtime.

04

Verify and harden

Validate with `npx clivly status` or `doctor`, then persist cursors if the host is serverless.

How Clivly reaches your app
Worth reading once — it explains why the setup asks for what it asks for.

Clivly never connects to your database. The SDK runs inside your app, and it is the only thing that touches your data.

Data only ever moves outward: the SDK reads your tables and pushes rows to Clivly. That direction needs no route at all.

Control moves inward, so it needs an address. Clivly Cloud posts to your tick route to start a sync — on serverless there is no long-lived process to hold a timer, so the cloud is the clock.

The chat widget adds a second inbound route, because a browser needs a short-lived session token minted by something that trusts your app.

Browse by task

Each section now has its own route so support, onboarding, and deep links can point to the exact step a developer needs.

Getting Started
Quickstart
Install the package, define the SDK once, and pick the correct runtime entry point before doing anything else.
  • `npm install clivly`
  • `connect()`
  • `start()` vs `runScheduled()`
Open Section
CLI
CLI
Scaffold, pair, tunnel localhost, push schema, and use the current diagnostic ladder without leaving the docs route.
  • `init`
  • `status`
  • `doctor`
Open Section
Configuration
Keys & Environment
Understand the two-key model, keep the secret key server-side, and configure the sync trigger the cloud uses to reach your app.
  • `CLIVLY_SECRET_KEY`
  • `CLIVLY_PUBLISHABLE_KEY`
  • Trigger secret
Open Section
Framework Guides
Framework Guides
Use route and runtime examples tailored to the host framework instead of adapting a generic snippet by hand.
  • Next.js
  • TanStack Start
  • Remix + Nuxt
Open Section
Chat Widget
Chat Widget
Configure the visitor widget, expose a session bootstrap endpoint, and embed it through React or a script tag.
  • Session bootstrap
  • React embed
  • Script tag
Open Section
Auth Adapters
Auth
Resolve end-user identity through Clerk, WorkOS, or better-auth with the adapter that matches the host app.
  • Clerk
  • WorkOS
  • better-auth
Open Section
Package Surface
Packages
Understand the consolidated package story, the scaffolder, and the import surface the current product expects developers to use.
  • `create-clivly`
  • `clivly/sdk`
  • `@clivly/chat-widget`
Open Section
Stability
Stability
Know which entry points are safe to depend on before 1.0, and which ones can change under you without notice.
  • Stable
  • Beta
  • Internal
Open Section
Troubleshooting
Troubleshooting
Debug the version, runtime, remote sync, and cursor persistence issues that show up most often in the current integration flow.
  • Version drift
  • Serverless runtime
  • Cursor persistence
Open Section

Current public package surface

This table now reflects the packages and responsibilities visible in the repository today.

clivly
Runtime imports + CLI
Consolidated runtime package plus the CLI command developers keep using after setup.
create-clivly
App creation bootstrap
Scaffolder for `npm create clivly`, wrapping the init flow for greenfield starts.
@clivly/sdk
Cloud connection SDK
Still the package-local README source for heartbeat, sync, serverless, and diagnostics guidance.
@clivly/chat-widget
Visitor chat widget
Embeddable React and script-tag widget with a host-side session bootstrap route.
@clivly/auth-clerk
Clerk auth adapter
Clerk adapter for host session resolution.
@clivly/auth-workos
WorkOS auth adapter
WorkOS adapter for host session resolution.
@clivly/auth-better-auth
better-auth adapter
better-auth adapter with no runtime dependency lockstep.
@clivly/core
Contracts + config
Entity config and schema discovery contracts that the runtime shares.