Skip to main content

Crate comindly_api

Crate comindly_api 

Source
Expand description

The requests and answers of /api/v1, /health and /ready: what the server writes and what the CLI and the web app read. Grouped by area and re-exported here.

Re-exports§

pub use crate::server::AccessToken;
pub use crate::server::AuditEntry;
pub use crate::server::AuditPage;
pub use crate::server::AuditQuery;
pub use crate::server::DeviceRequest;
pub use crate::server::Invite;
pub use crate::server::Member;
pub use crate::server::Role;
pub use crate::server::SecretInfo;
pub use crate::server::SignIn;
pub use crate::doctor::Check;
pub use crate::graph::ContractRole;
pub use crate::graph::ContractView;
pub use crate::graph::FlowStep;
pub use crate::graph::Node;
pub use crate::graph::Zoom;
pub use crate::view::View;
pub use crate::conventions::Convention;
pub use crate::conventions::Manual;
pub use crate::ledger::Entry;
pub use crate::preflight::Change;
pub use crate::events::Event;
pub use crate::hosting::Provider;
pub use crate::hosting::RemoteRepo;
pub use crate::jobs::JobRecord;
pub use crate::jobs::Status;
pub use crate::credentials::Source as KeySource;
pub use crate::team::TeamSettings;

Modules§

agents
When and how agents should use comindly’s tools: one text for MCP, hooks, files and the app.
answers
conventions
credentials
doctor
events
graph
hosting
jobs
ledger
manifests
model
Comindly core domain model.
preflight
prompts
search
server
team
view

Structs§

AgentQuery
GET /api/v1/agent?tool=&args=: what a read-only MCP tool answers an agent.
AnswerFocus
answer/why, answer/flow and answer/explore.
AnswerQuery
answer/find and answer/search: repos is a comma-separated list.
AtQuery
GET /api/v1/orgmap?at=: at indexes /api/v1/versions (oldest first); absent, the latest.
CodeRequest
POST /api/v1/auth/code: sign in with an email address and a code.
ContractsQuery
answer/contracts.
ConventionChange
POST /api/v1/conventions: add, edit, hide or restore.
Conventions
The conventions in effect, and the measured ones a person hid.
CreateTeam
POST /api/v1/team/create: start a team at an empty location.
Defaults
comindly’s built-in values, shown where a setting is left empty.
DeviceApprove
POST /api/v1/auth/device/approve.
DeviceCodeQuery
GET /api/v1/auth/device?code=.
DeviceStart
Where to approve the sign-in, and how often to poll.
DeviceStartRequest
POST /api/v1/auth/device/start: a command line asks to sign in.
DeviceTokenRequest
POST /api/v1/auth/device/token: what the command line polls with.
Done
What most changes answer: done, and a line to show.
EmailRequest
{ email }: request a sign-in link, reset a code, remove a member or withdraw an invitation.
ErrorBody
Every failed request: {"error": {"code", "message"}}.
ErrorDetail
Why a request failed; host and username when a clone needs an access token.
FindQuery
GET /api/v1/find?q=: symbols by name.
FlowDetail
One flow: its walkthrough when the index has one, and every step.
FlowQuery
GET /api/v1/flow?id=.
FlowRow
GET /api/v1/flows: an entry point and how far its flow reaches.
FocusQuery
GET /api/v1/node?focus= and /api/v1/context?focus=&budget=.
GraphEdge
GuideSectionText
Health
GET /health: the process answers.
HookQuery
answer/hook: event is session-start or pre-edit; seen the record ids shown already, comma-separated.
IdRequest
{ id }: revoke a token, erase a record.
IndexDirRequest
POST /api/v1/settings/test: whether an index location can be read.
IndexRequest
POST /api/v1/index: queue indexing of the listed repositories.
IndexStarted
The job that runs it; position when it waits, 1 for the next to run.
IndexWatch
GET /api/v1/index/watch: whether automatic re-indexing is on and what it last found.
Invited
An invitation sent: by email, or with a code the admin hands over.
JobDetail
GET /api/v1/jobs/{id}: the job, its events so far and its place in the queue.
JobRow
A job; a waiting one carries its position, 1 for the next to run.
Jobs
GET /api/v1/jobs: most recent first.
JoinRequest
POST /api/v1/join: use a team’s index.
KeyRequest
POST /api/v1/team/key: your API key; empty removes it.
LatestJob
LedgerQuery
answer/ledger.
Logging
GET/POST /api/v1/logging: which kinds of lines the engine logs, switched without a restart.
MemberRole
POST /api/v1/members/invite and /members/role.
Members
GET /api/v1/members.
MyTeams
POST /api/v1/me/teams: the teams you belong to.
Narration
A flow’s walkthrough and the questions it answers.
Neighbourhood
Nodes and labelled edges around the focus, for the canvas graph.
NewToken
POST /api/v1/tokens: absent expires_in_days means 90 days, null never.
NodeDetail
One symbol: its neighbours, what a change ripples to, and what the team recorded about it.
OrgEdge
src uses dst; via names the contracts a contract link goes through.
OrgMap
Repositories as nodes, linked by cross-repository code and contracts.
OrgNode
Overview
GET /api/v1/overview: the index at a glance.
Package
GET /api/v1/packages: internal packages and who uses which version.
PackagesQuery
answer/packages.
PreflightRequest
POST answer/preflight: the changed lines, read from git by the caller.
PromptChange
POST /api/v1/prompts: one change, at the version read.
PromptTask
PromptTried
PromptTry
POST /api/v1/prompts/try: run text on one sample without saving it.
Prompts
GET /api/v1/prompts: each LLM task’s built-in prompt, its saved versions and the one in use.
QueuedJob
A job waiting its turn.
Ready
GET /ready: an index is loaded and, on a server, the stores answer.
RedeemRequest
POST /api/v1/auth/redeem: a sign-in link’s token, an invitation or the admin token.
RememberRequest
POST /api/v1/remember: a record written by a person.
Remembered
The new record’s id.
RemoteAddRequest
POST /api/v1/repos/remote/add: clone URLs, optionally shared with the team.
RemoteList
The host’s repositories, the ones already here marked.
RemoteListRequest
POST /api/v1/repos/remote/list: a GitHub organisation or GitLab group, with a token if needed.
RemoteRow
RepoChange
POST /api/v1/repos: folders to add and remove.
RepoQuery
GET /api/v1/conventions?repo=.
RepoRow
A listed repository and what the index holds of it.
RepoSymbols
RepoTeams
POST /api/v1/repos/teams: exactly these teams on repo (its indexed name).
Repos
GET /api/v1/repos: the list comindly link indexes, and what the index has besides.
ReviewRequest
POST /api/v1/review: confirm, archive, invalidate, … a record by id or id prefix.
Ripple
How many symbols a change reaches, per repository.
Scan
ScanHit
A repository found under the folder, marked when already listed.
ScanRequest
POST /api/v1/repos/scan: git repositories under a folder, depth 1 to 4 (2).
SearchHit
A hybrid search hit.
SearchQuery
GET /api/v1/search?q=&repo=.
SecretRequest
POST /api/v1/secrets: an empty value removes it.
SecretSource
A secret the deployment provides (deployment) or nobody set (none).
Secrets
GET /api/v1/secrets: where each token and key comes from, never its value.
Settings
GET /api/v1/settings: your preferences and what is in effect.
SettingsChange
POST /api/v1/settings: only the given settings change; an empty text removes one.
Setup
GET /api/v1/setup: the index, its checks and how to connect agents.
ShownConvention
A convention with the handle edits use.
Skew
A consumer locked to another version of a package than its publisher declares.
SourceLine
SourceLines
The lines around path:line.
SourceQuery
GET /api/v1/source?repo=&at=path:line&around=.
StatsQuery
answer/stats: repos is a comma-separated list.
Team
GET /api/v1/team: the index’s shared settings and where your API key comes from.
TeamSave
POST /api/v1/team: version is the one read, so a concurrent change is not overwritten.
TeamsSave
POST /api/v1/teams: the whole team list, at the settings version read.
TokenCreated
A personal access token, shown once.
Tokens
GET /api/v1/tokens: your personal access tokens.
Tool
An MCP tool.
UnlistedRepo
A repository in the index with no folder in the list.
WatchResult
WithCode
A change that hands out a sign-in code: signing in with an invitation, or a reset.

Enums§

DeviceToken
Pending, or the token once a member approved; denied and expired are errors.
IndexState
GET /api/v1/index: the latest job with its events, or none yet; and the queue.
Me
GET /api/v1/auth/me: who is signed in, or local on this machine.
PromptAction
SecretState
One secret: stored here with its details, or from the deployment or nowhere.