How to pass proxy? nodejs

I have implemented a nodejs application in Cyberpanel, everything is fine and it works well.

But I ran into a problem.
Nodejs is on, now I can’t access the subdomain.
Is there a way to pass that /api?

I’ve read is a config server, but I honestly can’t find the solution.

This is a sub directory i think you need to add right htaccess rule for that

yes. it’s a subdirectory.

I did with: RewriteRule /api/(.*)$1 [P]
but it didn’t work.

I did something wrong?

I am new with the servers and stuff and I try to understand