insert and update depending on if the user has submitted information before

These two articles might be helpful:

Velo: Functional Testing in the Backend
https://support.wix.com/en/article/velo-functional-testing-in-the-backend

Velo: Testing and Debugging Your Code
https://support.wix.com/en/article/velo-testing-and-debugging-your-code#debugging-with-the-developer-console