@mayurajs/filestorage-mesa
v1.2.0
Published
Mesa (mesa.dev), a versioned filesystem for agents, for Mayura's file stores.
Readme
@mayurajs/filestorage-mesa
Mesa, a versioned filesystem for agents, for Mayura's file stores (mayura/files).
npm install mayura @mayurajs/filestorage-mesaimport { createFileStore } from 'mayura/files';
import { mesaFiles, mesaMaxFileBytes } from '@mayurajs/filestorage-mesa';
// token: a Mesa access token source (a short-lived JWT minted from your API key).
const files = createFileStore(mesaFiles({ token, org: 'acme', repo: 'agent-notes' }), { maxFileBytes: mesaMaxFileBytes });- Each key is a file path on a bookmark (
mainby default). Every write and delete is a change committed on the bookmark's head; when another writer moved the bookmark first, the write is rebased onto it, so concurrent writers never lose each other's changes. The history is Mesa's: every version stays in the repository. - Mesa has no per-file preconditions, media types or metadata:
ifMatch,ifNoneMatchand metadata are refused, and reads report no media type. A file's etag is its git blob SHA. - Files are at most 128 KB (Mesa's REST limit); ranges are read from the whole file.
- No dependencies: requests go through fetch. Nothing is read from the environment.
See the files guide. Apache-2.0.
