Next.js Discord

Discord Forum

Is kapa correct?

Answered
Siamese posted this in #help-forum
Open in Discord
Answered by joulev
I’m too lazy to read the long AI answer, but the answer to your original question is:

If the function runs on the server, yes, the endpoint is hidden and users won’t see the URL. If it runs on the client, no.

To ensure it runs on the server, import server-only there
View full answer

5 Replies

which one are you referring to
@Siamese https://discord.com/channels/752553802359505017/1144596633875656785/1144596825966383164
I’m too lazy to read the long AI answer, but the answer to your original question is:

If the function runs on the server, yes, the endpoint is hidden and users won’t see the URL. If it runs on the client, no.

To ensure it runs on the server, import server-only there
Answer
SiameseOP
thanks!