Headless, framework-neutral composition editing engine for agents and custom editors.
The SDK package provides a programmatic editing layer for HyperFrames compositions. It opens composition HTML, exposes query and mutation APIs, emits JSON patches, supports undo/redo, and can persist changes through pluggable adapters without requiring React, Studio, or a browser UI.
Build a custom composition editor in your own application
Let an agent inspect and edit composition HTML without driving a browser UI
Apply batch text, style, timing, asset, variable, or animation edits from code
Track undo/redo and patch events for host application history
Persist edited HTML through memory, filesystem, or custom storage adapters
Layer sparse overrides on top of a reusable base composition template
Use a different package if you want to:
Render compositions to MP4 or WebM - use the CLI or producer
Preview and edit visually out of the box - use the CLI (npx hyperframes preview) or studio
Parse, lint, or generate low-level composition HTML - use core
Capture frames from a headless browser - use engine
The SDK is the right layer for product integrations and agents that need structured edits. The CLI and Studio are user-facing tools built around the same composition format; the SDK is the editing engine you embed behind your own UI or automation.
All edits target stable HyperFrames element IDs. This makes the SDK safe for headless agents and backend jobs because mutations do not depend on mouse state or a current UI selection.
Pass a persistence adapter to autosave edits. The SDK ships memory and filesystem adapters, and host applications can implement the same PersistAdapter interface for S3, HTTP, IndexedDB, or app-specific storage.
For template-driven products, open a composition with an overrides object. The SDK applies the sparse override set on top of the base HTML, accumulates additional edits into that override set, and lets the host store only the delta.
For browser integrations, createIframePreviewAdapter() bridges the SDK to a same-origin composition iframe so hit-testing, selection, and draft preview updates can stay outside the model mutation path.