Can a Wappler extension execute actions from the Library?


Could a server connect custom module execute actions in the Library of the current project?

Context: Queue module, where you would select which action you want to execute

I don’t believe so. I was trying to do the same thing for a queue. I ended up just calling an api within the module.

Edit: actually maybe you can. See the thread below, I don’t think I ever tried Patrick’s solution.

With the exec method you can execute actions, here an example of a single action.

await this.exec({
  "name": "myAction",
  "module": "core",
  "action": "setvalue",
  "options": {
    "value": "myValue"
}, true);

You can also pass an array with actions. When you want to use one of the server actions stored on disk you can use await fs.readJSON(path) and then pass that to the exec method.


Extensions are getting a lot of traction lately.
I love it :slight_smile:


I’m asking questions in advance so I don’t have to wait for a response later :smiley:

Hi Patrick,

Can you share the hjson property that allows users to select actions in the Library?

To understand the significance of await I went here –

Lots of eye-openers for me. :eyes:

async and await