types.ts
Install with bun add @addonium/helpers. Zero runtime dependencies - works under Bun, Node 18+, and browsers.
types.ts
AddoniumSpecVersion
Spec version string, e.g. "1.0" (§5.1 addonium).
AddonType
type AddonType.
AuthMethod
type AuthMethod.
TokenGrant
type TokenGrant.
AuthConfig
interface AuthConfig.
AuthRequirement
Author-defined, out-of-band conditions for getting access (§6.2). Free-text for humans only — hosts display, never enforce. E.g. a Discord invite, a supporter role, a purchase receipt. Anything goes; Addonium never prescribes an identity provider (§6.3). / requirements?: Array<string | AuthRequirement>; }
Manifest
Short label, e.g. "Join the Example Discord". / label: string; /* Optional link, e.g. an invite URL. / url?: string; /* Optional longer explanation. */ detail?: string; }
StreamResponse
Required unless distribution is ["module"] only. May embed a token segment (§7). / baseUrl?: string; distribution?: Array<"manifest" | "module">; type: AddonType; /* Required non-null when type is "locked" (§6.2, §16 allOf). / auth?: AuthConfig | null; clients?: ClientsConfig | null; /* Defaults to false (§11). */ storesData?: boolean; update?: UpdatePointer; settings?: SettingDef[]; catalogs?: CatalogDef[]; repository?: string; homepage?: string; license?: string; }
ResolveItem
interface ResolveItem.
SettingsValues
type SettingsValues.
ModuleManifest
interface ModuleManifest.
ModuleUnlockContext
interface ModuleUnlockContext.
AddoniumModule
interface AddoniumModule.
RegistryEntry
interface RegistryEntry.