Publish a signed app release.
Publishing lists a pinned release in the App Registry. Each installation runs on the user's Mac and uses the local LastDB daemon. This guide covers the manifest, checks, signatures, and installation gates.
Purpose, inputs, outputs, guarantees, and limits.
Purpose. Make an app release discoverable and installable by name.
Inputs and outputs. A manifest, a clean source checkout, a compatible running LastDB node, publisher credentials, and a version. The result is a signed registry listing pinned to a source URL and commit.
Guarantees. The publisher signs the release declaration. The registry also validates and signs its listing. Installs verify signatures and declared compatibility.
Limits. A listing is not a server deployment. App code runs on each person's machine. This page describes merged source, not the behavior of every released LastDB version.
Source reviewed at 5eb6a3a63. The signed registry lists pinned app releases for the node’s supported app API versions. Installation also checks declared compatibility, publisher identity, and consent. A recorded build is publication provenance, not a requirement to run that exact build.
Declare dependencies, schemas, and access.
The manifest includes an app id, SemVer version, a dependencies object, and a complete schema declaration list. Map each dependency app id to an npm-compatible version range; use an empty object when there are no dependencies. Ranges must be 1–256 bytes, and a manifest can name at most 256 distinct dependencies. Self-dependencies and invalid ranges are refused. Publishing signs the declaration as supplied; it does not infer dependencies. Every schema field needs a type. Names without a namespace resolve under the app id. The access block names schemas available to reads and writes, or uses * for all schemas. Keep each side as narrow as the app needs.
{
"app_id": "notes-app",
"version": "1.0.0",
"description": "A local notes app",
"dependencies": {},
"schemas": [
{
"name": "Note",
"schema_type": "Hash",
"record_keys": { "primary": { "kind": "hash" }, "alternates": {} },
"fields": ["id", "title", "body"],
"field_types": { "id": "String", "title": "String", "body": "String" },
"field_descriptions": { "id": "Note id", "title": "Title", "body": "Note text" },
"field_versions": { "id": 1, "title": 1, "body": 1 }
}
],
"access": { "read": ["notes-app/Note"], "write": ["notes-app/Note"], "extensions": [] }
}For example, "dependencies": {"contacts": "^1.0.0"} requires a compatible Contacts release. Historical signed listings with dependency arrays remain readable as presence-only requirements. The example schema name resolves to notes-app/Note. The publisher derives the pinned schema definition ids from the manifest. Declaring a schema in the manifest does not make every installer's data the same; each node keeps its own local records unless users share a database.
Meet the source and node requirements.
Publishing requires a paid LastDB Cloud subscription. Local development and using a published app remain free.
- The manifest is valid JSON and has a valid app id and non-empty SemVer version.
- The dependencies object has at most 256 distinct valid app IDs. Each value is a valid npm-compatible version range of 1–256 bytes. Self-dependencies and invalid ranges are refused.
- Its schemas are valid declarations, include field types, and describe every schema the running node holds for this app.
- The Git checkout is clean. Its origin must be a public HTTPS GitHub repository URL.
- The node is running; the publisher records its current app API version and LastDB build in the listing.
- Publisher credentials and a signing key are available through the supported credential flow.
A manifest that omits one of the app's held schemas is refused. If the node holds an older definition that the new manifest names, publish reports that installation will update it.
Publish from the app source checkout.
lastdb app publish --manifest manifest.json
The command reads the clean checkout's commit and public origin, checks the manifest against the running node, adds the app API version and build, signs the declaration with the publisher key, and submits it to the Registry. The Registry must return a listed result.
For a validation-only unsigned declaration, the CLI supports --prepare <path>. That mode says nothing was published. It creates a private prepared file; keep such generated output outside Git.
Channel selection is an optional CLI argument; the default is the Registry's default channel. The publisher must use credentials for the intended registry environment.
Review the dependency plan and consent.
lastdb app install notes-app
The installer checks the pinned Registry key, listing signature, publisher signature, app id, source, API compatibility, and install consent. It resolves transitive dependencies, keeps satisfying installed releases, and installs missing dependencies before the requested app.
If the plan changes an installed dependency, review it and repeat with its exact --accept-dependency-plan <SHA256> value. Add --accept-install too if the plan also needs install consent. Install consent alone never approves a dependency change. A stale hash is refused without changes; review the new plan before approving it. A changed publisher key needs separate, exact-key acceptance. Use lastdb app install --help for the supported flags.
Upgrades, rollbacks, and removals must preserve the version ranges required by the remaining installed apps. LastDB refuses a change that would leave a dependency missing or outside its required range. Removing an app keeps its schemas and records; --delete-data removes only its separate app data folder.
The installer registers the app's read, write, and extension grant with the local node. App calls go to the app socket with X-LastDB-App set to the installed app id. Without that registered grant, the app socket refuses requests.
After activation, the launcher starts the app with its app socket path and app id. The app's code runs locally. The app cannot call owner-only routes through the app socket.
Compatibility and signatures are explicit gates.
The publisher records the app API version served by the running node, plus its build. The Registry uses API compatibility to list releases that an install can use. The manifest's dependencies, schema IDs, and access become part of the publisher-signed declaration. Historical dependency arrays mean the named apps must be present; range maps also constrain their versions.
Signed release catalog format
For range-bearing releases, the installer reads GET /v1/lists/<channel>/api/<api_version>/releases.signed.json (private catalogues use /v1/lists/private/<prefix>/<channel>/api/<api_version>/releases.signed.json). The envelope carries base64 exact catalogue bytes in payload and its signature in signature. The version 2 catalogue lists each app's latest entry in apps and eligible historical entries in releases; it accepts at most 4096 releases and the signed envelope is capped at 3 MiB. A live signed catalogue is required to select historical releases; cached history cannot authorize an install after withdrawal. The legacy <api_version>.json projection omits new range-bearing publications so older clients cannot ignore version requirements.
An installed app remembers the publisher key that signed its listing. An upgrade signed by a different publisher key requires the machine owner to accept that exact new key. The Registry's pinned key and both listing signatures remain required; accepting a changed publisher key does not bypass other checks. Registry listings and channels can change after this source review. Check the live catalog and the installed node's supported version before relying on a specific release.
Browse published apps → · Back to developer guide → · Dependency resolver source → · Registry wire contract →