Skip to content

Commit

Permalink
Add new method for module upload from vault (#86)
Browse files Browse the repository at this point in the history
  • Loading branch information
kmd-fl authored Feb 24, 2024
1 parent 724bd44 commit b439997
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion builtin.aqua
Original file line number Diff line number Diff line change
Expand Up @@ -277,20 +277,27 @@ service Dist("dist"):
-- module_name - import name of the module
default_module_config(module_name: string) -> ModuleConfig


-- Used to add modules to the node specified in the service call
-- Arguments:
-- bytes – a base64 string containing the .wasm module to add.
-- config – module info
-- Returns: blake3 hash of the module
-- NOTE: the config is IGNORED and only module's `name` is taken from it
add_module(wasm_b56_content: Bytes, conf: ModuleConfig) -> string

-- Adds module by copying it from Particle Vault directory
-- Arguments:
-- path – path or a filename
-- config - module config
-- NOTE: the config is IGNORED and only module's `name` is taken from it
add_module_from_vault(path: Path, config: ModuleConfig) -> Hash

-- Adds module by copying it from Particle Vault directory
-- Arguments:
-- path – path or a filename
-- config - module config
add_module_bytes_from_vault(name: string, module_cid: string) -> string

-- Get a list of modules available on the node
list_modules() -> []Module

Expand Down

0 comments on commit b439997

Please sign in to comment.