Extend Script service interface with add_from_vault (#26)

This commit is contained in:
Maria Kuklina 2022-06-23 15:09:12 +03:00 committed by GitHub
parent d24d2bf6ed
commit 3298a0e23c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -249,6 +249,15 @@ service Script("script"):
-- (NOTE: an actual interval may vary by up to 3 seconds)
add(air_script: string, interval: ?u64) -> string
-- Adds the script from the given path to a node
-- Arguments:
-- path - path to the AIR script without any undefined variables in the particle file vault
-- interval - time to next run of the script in seconds
-- - if set, script will be ran once in the interval
-- - if not set, script will be ran only once
-- (NOTE: an actual interval may vary by up to 3 seconds)
add_from_vault(path: string, interval: ?u64) -> string
-- Removes recurring script from a node. Only a creator of the script can delete it
remove(script_id: string) -> bool