Propose install, build, lint and test commands from the repository's files.
Reads the repository at its default branch from Koidog's mirror (never runs anything) and proposes check commands from package.json (bun, pnpm, yarn or npm, chosen by the lockfile), Cargo.toml, go.mod, pyproject.toml and requirements*.txt, a Makefile, Swift packages and Xcode projects, and Gradle.
POST/api/v1/projects/{id}/detect-commands
Scopeconfig
The proposals are stored and answered as suggestions; Koidog also reads them once when a project is created. Nothing changes the project's validation unless apply is true (then only fields, default every field proposed; its preview and named commands are kept), or you write the commands yourself with PATCH /projects/{id}. An empty repository proposes nothing (state: empty). The timeline records the key ID, action and outcome.
Path parameters.
idstringrequired
The project's id.
Headers.
Idempotency-Keystring
Retry the same request with the same key. Retry rules.
Body.
An omitted body is read as {}.
applyboolean
False (the default): read the repository and store the proposals, changing nothing else. True: also write them into the project's validation (only the fields in fields, default every field proposed), keeping its preview and named commands. Default false.
fieldsarray
With apply: which of install, build, lint and test to write. Default: every field that was proposed. Any of install, build, lint, test. At least 1 item.
Response.
200 OK · JSON object
- 422 validation_failed
- Each schema error appears in
details.