😎
No HTTP methods exported in Export a named export for each HTTP method
API Routesで下記エラーが
No HTTP methods exported in api/foo/route.ts'. Export a named export for each HTTP method.
結論
公式ドキュメントのpagesを見ていたので間違えていた
app routerではexport async function GET() {}
のように決められた関数名を付ける必要がある(GET,POST)
Discussion