main branch to the ContextLayer Git remote. ContextLayer builds that commit, applies its database migrations, publishes the app and MCP tools, and installs its agent schedules.
Work from the slate checkout created by init, which has origin set to the slate’s repository. You need the saved CLI login configured during Installation and permission to manage the slate. There is no separate deploy command.
Check the local changes
If you changed the app, run the checkout’s type check and production build:Include any declarations, migrations, and generated database types that the code needs. Local success does not configure hosted accounts or copy local data; those are separate from the deployment.
Commit your changes
init already committed the starter on main. If you have not changed it, continue directly to the push. Otherwise, commit the files you want to deploy:Push main
main starts a build; other branches do not deploy the slate.A successful push means the repository received the commit. The hosted app changes after the build, migrations, and publication succeed.Open the hosted URL
After deployment succeeds, open the hosted URL printed by
init. Its dashboard link is the management page; the hosted URL is the running app.New slates are private. Sign in with an account allowed to view the slate: its owning user or a member of its owning organization. If a coding agent is deploying for you, it should give you the hosted URL so you can open it in your browser.Check the behavior you changed in the hosted app. Configure any newly declared hosted connections or viewer secrets through the chrome when prompted.What the pipeline does
The pipeline takes its source code, declarations, migrations, and schedules from the pushed commit, in this order:- Prepare. ContextLayer reads the commit’s declarations and selects the databases to migrate.
- Build. An isolated sandbox installs the committed dependencies and runs
pnpm build. - Migrate. The commit’s Kysely migrations run against the slate’s owner-mode databases and every existing member’s viewer-mode databases.
- Deploy. The built app is published to the slate’s hosted URL.
- Schedules. The schedules of the slate’s agents are installed from the same commit.
Configure hosted resources separately
Git carries committed source, declarations, migrations, and generated query types. It does not carry the local resources those files used during development:
See Connect an account and Secrets for hosted configuration.
The hosted URL
The hosted URL ishttps://<name>.contextlayer.xyz/. <name> is the slate’s name, which ContextLayer chose when it created the slate. On the hosted slate, the chrome appears above the app: the ContextLayer header that shows who is signed in and what the slate still needs to be set up. See Use a slate.