From e95484139c4633d0e6bcca170958de171a0a78ee Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 10 Mar 2026 20:40:52 +0000 Subject: [PATCH] Update Notecard API from upstream schema changes (6bdf5ccf79992d9f436145d77da2cfba347b8277) --- notecard/card.py | 2 +- notecard/env.py | 4 ++-- notecard/web.py | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/notecard/card.py b/notecard/card.py index 711123b..16cb46b 100644 --- a/notecard/card.py +++ b/notecard/card.py @@ -707,7 +707,7 @@ def temp(card, minutes=None, status=None, stop=None, sync=None): @validate_card_object def time(card): - """Retrieve current date and time information in UTC. Upon power-up, the Notecard must complete a sync to Notehub in order to obtain time and location data. Before the time is obtained, this request will return `{"zone":"UTC,Unknown"}`. + """Retrieve current date and time information in UTC. Upon power-up, the Notecard must complete a sync to Notehub in order to obtain time and location data. Before the time is obtained, this request will return `{"zone":"UTC,Unknown"}`. The Notecard's stored timezone is only updated when a new Notehub session begins. Args: card (Notecard): The current Notecard object. diff --git a/notecard/env.py b/notecard/env.py index ab18874..9707bdc 100644 --- a/notecard/env.py +++ b/notecard/env.py @@ -13,7 +13,7 @@ @validate_card_object -def default(card, name=None, sync=None, text=None): +def default(card, name, sync=None, text=None): """Use by the Notecard host to specify a default value for an environment variable until that variable is overridden by a device, project or fleet-wide setting at Notehub. Args: @@ -76,7 +76,7 @@ def modified(card, time=None): @validate_card_object -def set(card, name=None, text=None): +def set(card, name, text=None): """Set a local environment variable on the Notecard. Local environment variables cannot be overridden by a Notehub variable of any scope. Args: diff --git a/notecard/web.py b/notecard/web.py index e8ff830..55d1f5e 100644 --- a/notecard/web.py +++ b/notecard/web.py @@ -18,11 +18,11 @@ def delete(card, async_=None, content=None, file=None, name=None, note=None, rou Args: card (Notecard): The current Notecard object. - async_ (bool): If `true`, the Notecard performs the web request asynchronously, and returns control to the host without waiting for a response from Notehub. + async_ (bool): If `true`, the Notecard performs the web request asynchronously, and returns control to the host without waiting for a response from Notehub. This argument only applies when the Notecard is in `continuous` mode and currently online. content (str): The MIME type of the body or payload of the response. Default is `application/json`. - file (str): The name of the local-only Database Notefile (`.dbx`) to be used if the web request is issued asynchronously and you wish to store the response. + file (str): The name of a local-only Database Notefile (.dbx) where the response will be stored when the web request is executed as a queued web transaction (e.g. if the request is made when Notecard is not in continuous mode and not online). If `file` is not specified, queued web transaction responses are discarded. This argument is not used when the Notecard is in `continuous` mode and online, as responses in that case are returned directly to the host. name (str): A web URL endpoint relative to the host configured in the Proxy Route. URL parameters may be added to this argument as well (e.g. `/deleteReading?id=1`). - note (str): The unique Note ID for the local-only Database Notefile (`.dbx`). Only used with asynchronous web requests (see `file` argument above). + note (str): The unique Note ID within the local-only Database Notefile (.dbx) specified by the `file` argument (see above). Used with queued web transactions to identify a specific Note where the response will be stored. route (str): Alias for a Proxy Route in Notehub. seconds (int): If specified, overrides the default 90 second timeout.