# This service runs on Turn Zero Cloud The service in this folder is hosted on Turn Zero Cloud. It started from the platform's `web-app` template: a Node.js service with a web page, sign-in for its users, each user's own rows in the platform's database, and an AI model under the plan's allowance. This file describes the template the service started from: keep it current as the service changes. ## Where you build - The page: `client/`, plain HTML, CSS, and script, which the platform serves at the application's address. - The routes: `src/server.mjs`. The service started with routes under `/api/` that each read the signed-in user, and keep and list that user's own rows. - The AI model: `src/ai.mjs`, which calls it under the plan's allowance, with no key of your own. - The tables: `migrations/`, one file for each change, applied in order at each start. ## Where the rules are Turn Zero Cloud serves its rules to a coding tool through its MCP server, `turnzero-cloud`, and they change with the platform, so none is repeated here. - Where the server is not connected, connect it first. The platform's page "Connect your AI tool" says how. - Before you change or deploy this service, read the server's `deploy` skill, and before you change its sign-in or its AI call, the server's `add-sign-in` or `use-ai-allowance` skill. ## What you run here - The tests: `npm test`, in this folder. - A local run and a deploy: the `deploy` skill gives each step and the line to run, in this order: `submit_manifest`, the local run, `deploy`. - Sign-in is on the deployed application's own address, also during a local run, since the page a local run serves has no sign-in routes. A local run's API routes take a session as a Bearer.