Conversation
Keep the update property time interval tests consistent with the singular client method name so the renamed API surface is less confusing in review. Made-with: Cursor
There was a problem hiding this comment.
All prior inline threads resolved. The _device_identifier extraction is a nice dedup, and the urlquote addition to the existing device methods fixes path-encoding for names with special characters — that's a good side-effect improvement.
One note: the _device_identifier refactor changes the existing validation from truthy checks (if device_name and device_id) to is not None checks. This means callers who previously passed device_name="" alongside a device_id wouldn't have gotten the mutual-exclusivity error, but now will. More correct behavior, but technically a subtle breaking change for get_device, update_device, and delete_device.
PR description still has "Pending" in the Description section — clean that up before un-drafting.
| "limit": ["5"], | ||
| "offset": ["10"], | ||
| "projectId": ["project-id"], | ||
| } |
There was a problem hiding this comment.
suggestion: The list test covers key, limit, offset, and projectId but doesn't exercise start/end. Those params go through astimezone().isoformat() serialization, which is the most interesting codepath to verify (timezone handling, format). Worth adding a test that passes start/end datetimes and asserts the query params are serialized correctly.
…evice-property-history
Changelog
Support for device custom property time intervals
Docs
Relevant docs will be updated with the associated API PR
Description
Pending
Adds support for device custom property time intervals - listing, getting, and updating. Also a small deduplication refactor to consolidate our device id or name handling into a single method. This is in line with how we do session id or key.
Testing
Local testing against a local API instance. A custom test script was used to hit the API with a high volume of reads and edits and examine the results for correctness.