No response from _functions

I’m just starting out with using http functions. I got some modules to work initially, but after some time I was getting absolutely no response from anything in /_functions. I simplified my code as much as possible and was still getting no response.

export function get_login(request){ return ok();}

I reckon my problem lies in accidentally creating two routers.js files, one in public and one in backend. Is there a way to delete them so I can see if they’re giving me the problem?

Thanks.

You can delete a file this way:

I can’t delete routers.js. when I hover over them, the gear icon doesn’t appear. The gear does appear for other .js files though.

Please post the URL of your site. Only authorized Wix personnel can get access to your site in the editor.

https://www.untitledtattoo.com/

trying to access anything in
https://www.untitledtattoo.com/_functions/
will result in no response. I believe its a server problem.

How are you trying to access the http-functions? What does the URL that you access the API look like?

https://www.untitledtattoo.com/_functions/ login
is the only function I have. It’s not the function’s problem though, as any path after _functions/ will result in no response, instead of the expected 404 status code.

How are you calling the login function?

using the URL I provided above.
https://www.untitledtattoo.com/_functions/ login

in http-functions.js:
export function get_login(request){ return ok();}

This function used to return a json and it was working fine until sometime yesterday. I reduced it to ok after this problem started okay

Hi Shawn.
There’s a typo in the wix-data import that prevents your code from running:
import wixData from ‘wix-Data’;

should be:
import wixData from ‘wix-data’;