Agent contract
Lunar Atlas API
The front door to the catalog. The web dashboard walks through it. Your agents walk through it. Single source of truth for reads, curator-reviewed proposals, and trusted GTM operating actions. Vendor-neutral by design: REST + Bearer + OpenAPI 3.1.
Key idea
Atlas describes reality. GTM describes what Lunar Rails is doing about it. Agent API keys can be powerful, but that power is scoped, audited, and split between proposals and operational layers.
01
Explore endpoints
Interactive OpenAPI explorer below. Human-readable, high contrast, and copy/paste friendly.
02
Onboard an agent
System prompt, workflows, scopes, retry rules, examples, and taxonomy reference.
03
OpenAPI spec
Canonical machine contract. Paste into any client or agent framework.
Quick start
- 1.Admin/curator mints an API key in
/dashboard/teamwith only the scopes the agent needs. - 2.Agent calls
GET /api/v1/whoamito confirm identity, scopes, and budget before doing work. - 3.Agent reads context from Atlas, then either submits proposal bundles or uses trusted GTM endpoints for operating-board updates.
- 4.Every POST uses
Idempotency-Key. Every response is JSON with structured errors, hints, and retry flags.
What agents can read
- Entities, segments, taxonomy, capabilities, needs, sources
- People graph, roles, relationships, and entity context
- GTM segments, assignments, lanes, weekly briefs, events, and links
- OpenAPI, usage, whoami, and structured error contracts
Copy/paste agent prompt
“Let’s add a new entity” mode
Give this to an agent when you want it to interview a curator, research sources, validate a bundle, and submit an inbox proposal without creating duplicate or half-baked Atlas rows.
You are a Lunar Atlas analyst agent. The curator wants to add or enrich an entity in the Bitcoin ecosystem.
Your job is to interview the curator, research public sources, and prepare a curator-reviewed Atlas proposal. Do not submit anything until the curator approves the final change set.
API base: https://lunaratlas.dev/api/v1
Docs: https://lunaratlas.dev/api and https://lunaratlas.dev/api/onboarding
OpenAPI: https://lunaratlas.dev/api/v1/openapi.json
Rules:
- Call GET /whoami first to confirm scopes.
- Search Atlas before creating anything: GET /entities?q=<name>.
- Read valid taxonomy/reference data: GET /segments, /taxonomy, /capabilities, /needs, /verticals.
- Do not invent facts, people, relationships, warm paths, sources, or GTM priority.
- If confidence is below 3/5, ask a question instead of proposing the change.
- Atlas is the wiki/source-of-truth layer. GTM is the operating/action layer.
- Always run POST /agents/validate/bundle before POST /agents/proposals/bundle.
- Always use Idempotency-Key on writes.
Interview the curator in this order:
1. Identity: entity name, website, X, LinkedIn, GitHub, country/city, one-liner.
2. Existing Atlas match: summarize what Atlas already knows, or confirm none.
3. Placement: segment(s), taxonomy tags, capabilities, needs, verticals.
4. Why it matters: customer, partner, provider, competitor, funder, benchmark, or context.
5. Evidence: public URLs, docs, filings, announcements, interviews, or meeting notes.
6. Key People: 3-5 relevant humans, roles, why they matter, primary contact if any.
7. Relationships: connected entities, relationship type, confirmed vs inferred.
8. GTM check: Atlas-only or promote to GTM with segment, lane, owner, rationale, next action.
Then output:
Entity:
Existing Atlas match:
Proposed Atlas changes:
Key People:
Sources:
GTM recommendation:
Open questions:
Ask: "Validate this bundle now?" If validation passes, ask: "Submit this proposal to the curator inbox?"Agent power model
Write access is explicit, scoped, and understandable.
write:proposals
Curator-reviewed proposals
Default write path. Agents propose entity, source, relationship, Key People, taxonomy, lore, and dossier updates. Curators accept in the inbox.
write:gtm
GTM operating actions
Trusted GTM agents can directly manage operating assignments, lanes, next actions, weekly brief records, brief links, and Field Intel events without changing canonical Atlas facts.
write:sources
Source intake
Agents can register public sources and upload source files against an entity, preserving attribution and review trails. Audio capture was retired on 2026-07-25 — submit the transcript or notes as text instead.
Readable endpoint map
The API surface at a glance
This first-party map is generated from the same OpenAPI object as the JSON spec, so agents and humans see the same contract even if an embedded docs viewer fails to load.
Auth, usage, and contract
/api/v1/whoamiIdentify the calling agent
/api/v1/usageCurrent period's API usage
/api/v1/agent-work/queuesList Atlas agent work queues
/api/v1/agent-work/itemsList prioritized Atlas cleanup work items
GTM operating layer
/api/v1/gtm/segmentsList GTM operating segments
/api/v1/gtm/assignmentsList GTM entity assignments
/api/v1/gtm/assignmentsCreate or update a GTM entity assignment
/api/v1/gtm/assignments/{id}Patch a GTM assignment
/api/v1/gtm/briefsList GTM intelligence briefs
/api/v1/gtm/briefsCreate or update a GTM intelligence brief
/api/v1/gtm/briefs/{id}/linksList links for a GTM brief
/api/v1/gtm/briefs/{id}/linksAttach an entity, segment, or source to a GTM brief
Events / Field Intel
/api/v1/field-eventsList Field Intel events
/api/v1/field-eventsCreate or update a Field Intel event
/api/v1/field-events/{slug}Read one Field Intel event
/api/v1/field-events/{slug}Patch one Field Intel event
/api/v1/field-events/{slug}/entitiesAttach an entity to a Field Intel event
/api/v1/field-events/{slug}/peopleAttach a person to a Field Intel event
/api/v1/field-events/{slug}/segmentsAttach a segment to a Field Intel event
/api/v1/field-events/{slug}/goalsAdd a goal to a Field Intel event
/api/v1/field-events/{slug}/goals/{goalId}Update a Field Intel event goal
/api/v1/field-events/{slug}/interactionsLog a meeting/touchpoint at a Field Intel event
/api/v1/field-events/{slug}/interactions/{interactionId}Update a Field Intel event interaction
/api/v1/field-events/{slug}/follow-upsAdd a follow-up action item to a Field Intel event
/api/v1/field-events/{slug}/follow-ups/{followUpId}Update a Field Intel event follow-up
/api/v1/field-events/{slug}/scorecardRead a Field Intel event's post-event scorecard
/api/v1/field-events/{slug}/scorecardUpsert a Field Intel event's post-event scorecard
/api/v1/field-events/{slug}/rosterRead a Field Intel event's roster candidates
/api/v1/field-events/{slug}/rosterBulk-ingest roster candidates discovered by an agent
/api/v1/field-events/{slug}/roster/{candidateId}Refine one Field Intel event roster candidate
Discovery sprints
/api/v1/discovery-sprints/{sprint}/targets/{target}Read one discovery sprint target
/api/v1/discovery-sprints/{sprint}/targets/{target}Update one discovery sprint target
Atlas segments and drilldowns
/api/v1/segments/{slug}Get one segment with optional Dossier embed
/api/v1/atlas/segments/{slug}/drilldownGet a page-shaped Atlas segment drill-down
/api/v1/atlas/segments/{slug}/drilldown/proposalsPropose drill-down curation updates
/api/v1/atlas/visualization/overlapsGet heuristic Atlas role-overlap buckets
/api/v1/atlas/visualization/coverageGet Atlas data coverage and curation gaps
/api/v1/segmentsList ecosystem segments
Taxonomy
/api/v1/taxonomyList agent-facing taxonomy terms
/api/v1/taxonomy/{slug}Get one taxonomy term
/api/v1/taxonomy/{slug}/entitiesList entities assigned to a taxonomy term
Reference data
/api/v1/capabilitiesList Lunar Rails capabilities
/api/v1/needsList demand-side needs
/api/v1/verticalsList sub-classification verticals
/api/v1/sources/{id}Get a source with a signed download URL
Entity catalog
/api/v1/entitiesList catalog entities with filters
/api/v1/entities/{id}Get a full entity dossier
/api/v1/entities/{id}/sourcesList sources backing an entity's Dossier
Proposal inbox writes
/api/v1/agents/proposalsList your proposals
/api/v1/agents/proposals/{id}Get one of your proposals with full change payload
/api/v1/agents/proposals/entityPropose a new entity (optionally with enrichment)
/api/v1/agents/proposals/segmentsPropose a new ecosystem segment
/api/v1/agents/proposals/lr-fitPropose lr_fit rows for an entity (batch)
/api/v1/agents/proposals/entity-relationshipPublish an entity's relationship path (how contact formed + where comms live)
/api/v1/agents/proposals/providersPropose provider relationships for an entity (batch)
/api/v1/agents/proposals/relationshipsPropose entity-to-entity relationships (batch)
/api/v1/agents/proposals/eventsPropose events for an entity (batch)
/api/v1/agents/proposals/field-eventsPropose a field event with segment/entity/people intel (batch)
/api/v1/agents/validate/bundleDry-run validate a bundle proposal
/api/v1/agents/proposals/bundlePropose multiple change kinds in one inbox card
/api/v1/agents/proposals/lore-updatePropose an update to an entity's Dossier narrative
/api/v1/agents/proposals/personPropose a new person or an update to an existing one
/api/v1/agents/proposals/person-rolePropose attaching a person to an entity in a specific role
/api/v1/agents/proposals/segment-lore-updatePropose an update to a SEGMENT's Dossier narrative
Capture and source intake
/api/v1/agents/sourcesCreate a URL-based source for an entity
/api/v1/agents/sources/uploadUpload a file-backed source for an entity
Key People graph
/api/v1/peopleList people with filters
/api/v1/people/{id}Get a full person dossier
Interactive reference
Endpoint explorer
This is generated from /api/v1/openapi.json, which is the source of truth for agents and client builders.