@keel-ai/updates
v0.1.0
Published
OTA bundle distribution for Keel — manifest fetch, bsdiff patching, channel pin, rollback.
Maintainers
Readme
@keel-ai/updates
OTA bundle distribution client for Keel — manifest fetch, bsdiff patching, channel pin, rollback. Counterpart of
expo-updates.
Three parallel implementations of the same OTA protocol:
- TypeScript (
src/) — JS-side OTA: a running RN bundle can check for updates and reload itself. Usesfetch(); no native module bridge. - Swift (
ios/) — for iOS host shells that handle OTA in the native launcher (e.g. fetch the next bundle before mountingKeelView).import KeelUpdate. - Kotlin (
android/) — Android counterpart. Packagecom.keel.updates.
The three impls share the protocol shape (manifest schema, bsdiff patch format, channel + rollout semantics) but don't bridge through each other — each is self-contained for its consumer.
Install
keel install @keel-ai/updatesJS usage
import { KeelUpdateClient } from '@keel-ai/updates';
const client = new KeelUpdateClient({
endpoint: 'https://api.keel.appunvs.com',
project: 'my-project',
channel: 'production',
});
const result = await client.check();
if (result.kind === 'update_available') {
await client.download(result.bundle);
await client.apply();
// ... reload the JS engine
}Swift usage (iOS host shell)
import KeelUpdate
let client = KeelUpdateClient(
endpoint: URL(string: "https://api.keel.appunvs.com")!,
project: "my-project",
channel: "production"
)
let result = try await client.check()
// branch on result.kind ...Kotlin usage (Android host shell)
import com.keel.updates.KeelUpdateClient
val client = KeelUpdateClient(
endpoint = "https://api.keel.appunvs.com",
project = "my-project",
channel = "production",
)
val result = client.check()
// branch on result ...Protocol
See keel/docs/update.md for the wire
protocol (manifest schema, bsdiff patch format, channel + rollout
semantics).
