← Back to Forum
Announcements
New Feature: Retrieve latest key value across multiple dweets
by dweet ยท 01/05/26 14:37
The existing key lookup (/get/dweet/for/thing-name/key) only checks the single most recent dweet, which returns null if that dweet doesn't happen to contain the key you're looking for โ€” a common problem when multiple devices post independently to the same thing name.
The new endpoint scans back through recent dweets to find the latest value for a given key, regardless of which dweet it was in.
Example โ€” multiple devices posting to the same thing:

curl "https://dweet.cc/dweet/for/thing-name?temperature=21.4&humidity=55"
curl "https://dweet.cc/dweet/for/thing-name?status=ON&power=82.7"

curl https://dweet.cc/get/latest/key/for/thing-name/temperature
"21.4"
curl https://dweet.cc/get/latest/key/for/thing-name/power
"82.7"
๐Ÿ’ฌ Replies (0)

No replies yet. Be the first to reply!

Reply