Backend contract v1: descriptor, data-plane module, conformance suite

Open
#2,738 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
typescript

Research direction

Start by reading the ADR and inspect shared/contract/backend.ts, then trace how nemar-api serves routes and how the CLI discovers and selects a backend. Define the descriptor and data-plane contract, add a conformance suite runnable against any backend origin, and connect version rejection in the CLI. Done means the production descriptor is served, the suite passes against nemar-api in CI, and its digest is recorded.

Written by the indexing model from the issue text.

Description

api backend feature

Goal

Define what any NEMAR backend must serve, so the CLI can talk to more than one without special cases.

Scope

  • GET /.well-known/nemar-backend, open, no credential: contract version, API version, where the OpenAPI document is, auth methods and token audience, the dataset id pattern it holds, and a closed list of capabilities (catalog, git, objects, manifest, zarr, groups, grants, upload, mcp, job-grants). It names no storage provider or bucket and lists no dataset or group.
  • shared/contract/backend.ts: the descriptor, the data-plane routes (/git/, /o/, /f/, the manifest, /z/), the dataset list entry, the error envelope and the version header.
  • A conformance suite next to it, runnable against any backend origin, with a published digest so other repositories can pin a copy. nemar-api's own data plane passes it.
  • The CLI refuses a backend whose contract major version it does not know, with one sentence, before any command runs.

ADR

"A backend describes itself, and the CLI routes a dataset id by what backends say" and "The data-plane contract is one module and one conformance suite that every backend passes."

Done when

The descriptor is served by nemar-api in production, the suite passes against it in CI, and the suite's digest is recorded.

Dominant language
TypeScript
Stars
0
Forks
1
Avg merge
4h 48m
Merged PRs (30d)
468

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from nemarOrg/nemar-cli

All issues in nemarOrg/nemar-cli

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.