Velo Events.js "onEvent" Functions do not get Triggered by the Events

Dear Forum Users!

I am having a problem running backend actions in Velo! More specifically in the events.js file. When an event is triggered, the functions don’t run. Not even console.log functions placed outside the onEvent functions work. For example: I place a session booking order, and the event function inside events.js does not trigger, and not even the console.logs outside the function trigger.

What could cause this problem? Maybe some settings in the dashboard are incorrectly set up? Could you please help with this? I have been digging the forums, the documentations, and asked the AI assistant in Velo IDE, but with no luck. :frowning:

I have attached a screenshot of my event.js. According to the debugger and the AI assistant, the code is correct. Honestly, what I’m concerned about is that the events.js is completely ignored, because not even console.log works. :frowning:

I appreciate your help!
Thank you!

Please share your code by pasting it in the following format:

```js
const myCode = “here”;
```

This will then look like:

const myCode = "here";

As for the issue:

  1. Bare console.logs probably won’t fire in this file as only the exported functions are ever called.
  2. Can you confirm the name of the file? From the title it says Events.js but filenames are case sensitive and it would have to be events.js
  3. Are you testing in preview mode or on a published site? Events only fire for a published site.
  4. How are you checking the logs?

More info on the events.js file is here if that helps: Velo Backend Events