openvibers/openvibe.sdk Commits
0.5.0: Media object API v2 client (createObjectsClient in openvibe-sdk/media)
OP OpenVibers committed 23 Sept 2026 · tag v0.5.0 · 0 files, +0 −0
createObjectsClient({ app, baseUrl?, tokenClient | apiKey | client }) wraps /api/v2/:app/objects and
/api/v2/:app/jobs:
- upload() picks single or multipart by size: single = init, the bytes to Media's presigned PUT URL
(no credential on it), complete; multipart above multipartThreshold (or when Media answers 413 to one
part) = parts in parallel with X-Content-SHA256, the session read back after each round and missing
parts sent again, complete naming every part's sha256; the whole object's sha256 for Media to verify.
A part that cannot be sent ends in sdk.upload_incomplete with err.resume.
- resume() continues a session from another process with the client's credential, re-sending parts
whose sha256 differs from the caller's bytes.
- get, signedUrl, delete, list, iterate; jobs.create (Idempotency-Key), get, list, approve, cancel, wait.
- Without baseUrl, Media's origin comes from the platform descriptor (/.well-known/openvibe), which
gives origins only for live services; no live origin is sdk.service_unavailable, never a guess.
Types, ESM entry and browser bundle regenerated; test/objects.test.js runs it against a mock of
Media v2 (discovery, single, multipart, 413 fallback, dropped parts, resume, reads, jobs, headers).
CHANGELOG 0.5.0; not tagged.
This commit has no diff to show.