latitude-setup
Latitude Setup (zero-account onboarding)
Orchestrates the from-scratch path: the user has no Latitude account and no API key. This skill provisions a temporary account via the CLI, instruments the app, verifies real traces, and returns a claim link the user opens in a browser to take ownership.
This skill depends on two others — latitude-cli (install + auth + command primitives) and latitude-telemetry (instrumentation). Read both; this skill only adds the orchestration between them.
Preflight: don't create a temporary account if the user already has one
The temporary-account bootstrap exists to make onboarding automatic for someone with nothing set up yet. But a user who already has a Latitude account can land on this skill by mistake — and routing them through a redundant temporary org plus a claim step is worth avoiding when you can. So before bootstrapping anything, infer from the environment whether an account already exists, and redirect instead of bootstrapping if it clearly does:
- An API key is already present —
LATITUDE_API_KEYset in the shell, in a.env(search the app root and its parents), in the app's secret manager, or in deployment/CI config. - A Latitude MCP is connected and authenticated in this harness — an OAuth-authorized Latitude MCP means the user already has a workspace.
- Existing Latitude config/instrumentation in the repo — a
LATITUDE_PROJECT_SLUG, a@latitude-data/telemetry/latitude-telemetrydependency, or an OTLP exporter already pointed atingest.latitude.so. - The user says so — they mention being signed in, having a project, or already using Latitude.
If any of these hold → do NOT bootstrap. The user has an account; redirect to the direct path:
- Use
latitude-telemetryvia its "invoked directly" entry point to audit and instrument the app against the existing key/project. Uselatitude-cliif you still need to install/authenticate the CLI or discover the project slug (latitude projects list). - Finish with
latitude-telemetry's verification step: run the user's real LLM flow and confirm the traces landed via the Latitude MCP, CLI, or API. Do not run this skill's bootstrap, claim-link, or delete-and-recreate cleanup — those belong only to the temporary-account flow, and the cleanup would destroy a project the user actually owns.