Skip to content

Add values() method for last-seen bus state#3

Merged
zourzouvillys merged 2 commits into
mainfrom
theo/last-values
Mar 4, 2026
Merged

Add values() method for last-seen bus state#3
zourzouvillys merged 2 commits into
mainfrom
theo/last-values

Conversation

@zourzouvillys
Copy link
Copy Markdown
Contributor

Summary

  • New client.values() method fetches GET /values, returning last-seen frame per (device, PGN)
  • New PGNValue and DeviceValues types
  • Works on both boat (Client) and cloud (CloudClient.client()) paths
  • 3 new tests (fetch values, empty array, error handling)

Files changed

File Change
packages/lplex/src/types.ts Add PGNValue, DeviceValues interfaces
packages/lplex/src/client.ts Add values() method
packages/lplex/src/index.ts Export new types
packages/lplex/test/client.test.ts 3 new tests
packages/lplex/README.md Add values() API docs, types, endpoint table
CLAUDE.md Update file map, test counts, endpoint table

Test plan

  • npm run build (clean)
  • npm test (30/30 pass)

New client.values() fetches GET /values, returning the most recent
frame per (device, PGN) pair. Adds PGNValue and DeviceValues types.
Works on both boat (Client) and cloud (CloudClient.client()) paths.
@zourzouvillys zourzouvillys merged commit e4a7e17 into main Mar 4, 2026
1 check passed
@zourzouvillys zourzouvillys deleted the theo/last-values branch March 10, 2026 23:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant