Changelog
What each release of @velven/sdk and the script tag added. Releases only add: nothing a page already calls changes or goes away. Versions explains which release a page runs.
0.7.0
Achievements and stats, player content, rooms, presence, friends boards and the sandbox.
Velven.achievements(unlock,list),Velven.stats(set,add,get) andVelven.onAchievement: achievements and stats declared in the block,velven.jsonor the API.Velven.content(upload,list,download,remove,report): player content, andcontentIdonscores.submitto keep a replay with a score.Velven.rooms: multiplayer rooms on Velven's relay, invites and invite links.Velven.presence.set: a line friends see.friends: trueontopandaround: friends-only boards.displayon a board shows it on the space's page.Velven.sandbox, and previews andvelven devwrite to the space's sandbox. A page onlocalhostinside a frame looks for Velven before it settleslocal.data-toasts="false"andtoasts: false: your space draws its own unlocks.@velven/sdk/serveraddsunlockAchievementandsetStat,contentIdonpostScore, andsandboxfromverifyToken.
0.6.0
Send visitors to your Velven page.
data-redirecton the script tag, orcreateVelven({ redirect: true }), sends a page opened directly to its Velven page, where sign-in, boards and saves work. Nothing changes for a page without it.
0.5.1
Batch reads on an older Velven page.
Velven.scores.readon a Velven page opened before batch reads existed sends each read on its own, instead of waiting 30 seconds and answeringfailed.- The SDK tells the Velven page its version when it starts, so a problem can be traced to the release.
If you bundle 0.5.0 from npm, update to 0.5.1: the script tag already serves it.
0.5.0
Batch reads.
Velven.scores.read([...])reads up to 10 boards in one call, each answer as its own call's.
0.4.0
Gameplay and sound.
Velven.game.start()andVelven.game.stop()tell Velven when play is on.Velven.onMute(handler)puts a sound button in the bar under your space and tells your handler the player's choice.- Locally,
?velven_muted=1calls every mute handler withtrue, andstartandstoplog to the console.
0.3.0
History reads, retry keys, cancelling a sign-in and a server helper.
top,aroundandminetakebucket(current,previousor a date) andseason, to read past days, weeks and seasons.- Every read carries
info: the board's label, unit, metric, sort, mode, entries, period, bucket and season. top({ after })pages in the bucket and season the row was read from, so a board paged across midnight stays on its day.scores.submittakesrequestId, so a retried run is entered once.signIntakes anAbortSignalassignal, and a cancelled sign-in request answerscancelled.Velven.versionnames the release, andVelven.spacethe space the page runs in.probeTimeoutMsoncreateVelven({ window, playerOrigins, probeTimeoutMs })anddata-probe-timeouton the script tag set how long a frame waits for Velven, 3 to 60 seconds.- A
signed_outanswer to a score call clears the cached token andVelven.user. - Locally, boards roll over by
periodandseason, and 3 new query parameters arrive:?velven_seed=,?velven_strict=1and?velven_slow=. @velven/sdk/serveraddsverifyTokenandpostScore, for Node 20 and later, Deno, Bun and Cloudflare Workers.
0.2.0
Saves, and the player's own row.
Velven.datakeeps a player's progress withgetItem,setItem,removeItemandclear, up to 1 MB per player and space.scores.mine({ board })answers the player's own row, ornullbefore their first score.
0.1.0
The first release, as the script tag and the npm package @velven/sdk.
ready(),Velven.environmentandVelven.user.signIn(), plain or{ silent: true }, andonAuth.scores.submit,scores.topandscores.around.- The local environment, with
?velven_user=,?velven_token=expiredand?velven_local=1.