Next.js Discord

Discord Forum

api routes arent found

Answered
Nile Crocodile posted this in #help-forum
Open in Discord
Nile CrocodileOP
im trying to add an api route but it nextjs doesnt find it?
Answered by Arinji
route.ts in the folder
View full answer

5 Replies

@Arinji read the docs, https://nextjs.org/docs/app/building-your-application/routing/route-handlers#convention
Nile CrocodileOP
yeah i did it seems like i did everything right?
route.ts in the folder
Answer
so api/ask/route.ts
Nile CrocodileOP
ohhhhhhh thats confusing i thought they wanted to replace route witht the actual name