Pure contracts and SDK
Pure contracts and SDK
Section titled “Pure contracts and SDK”Motivation
Section titled “Motivation”Plugin SDK, schema ownership, entitlement contracts and shared event types. Core never imports Server or a database implementation. Business plugins, customer data, credentials, actual infrastructure settings and operator receipts remain outside this public package.
Architectural Diagram
Section titled “Architectural Diagram”flowchart LR Contract[Public contract] --> Host[Verified host bindings] Host --> Runtime[Scoped runtime operation] Runtime --> Evidence[Durable result and audit]Public import
Section titled “Public import”Install the package; the subpath below is an import target, not a separate package. Registry installation requires a published EAOS release; before publication use the owning workspace’s checksum-verified build artifact.
bun add @alneas/eaos-coreimport { definePlugin } from '@alneas/eaos-core'
export const defineFeature = definePluginPure contracts run in server and browser hosts. Supply verified capabilities at the host boundary.
Trade-offs & Decisions
Section titled “Trade-offs & Decisions”The host supplies verified identity and current lifecycle/resource authorization. CAS rejects stale revisions; durable host stores retain audit and Outbox. Provider connections and secrets are injected through trusted ports.
Code installation, database/infrastructure application and tenant activation are separate operations. Import/build/test/install do not perform production migrations or infrastructure updates. Before registry publication, build and test checksum-pinned tarballs in isolated consumers instead of linking sibling source.
See the declarative SDK for policy and scoped context contracts.