using WebHooks app with 123Formbuilder

I’m trying to use the WebHooks app to send data from my forms to my Wix website. It’s not working, but I can’t tell if the issue is with my script or the configuration of the app.
I have WebHooks set up on two of my forms: Copy of Contact Form and Sport for Life Evaluation. I entered the url of my script ( https://www.viasportevaluation.com/_functions/123FormWebHook ) which should direct to this script:

export function use_123FormWebHook (request) {

return request.body.json()
.then( ( body ) =>
{

return wixData.insert( ‘TestDatabase’, body.data );
} )

Does anyone have an insight as to whether there is an issue with the code I’m using?

Hello Walter,

Is your form on the same website or an external one?

Try this instead of the code you have:

export async function use_123FormWebHook (request) {   
    let body = await request.body.json();     
    console.log(body, "make sure this is not empty")
    await wixData.insert('TestDatabase', body.data );        
 }

You can also try checking out this short article:

Let me know if this works,
Majd