DiamondDragonD
Convex Community14mo ago
6 replies
DiamondDragon

HTTP Path Suffix Not Working?

Now it is almost midnight for me so I could have missed something, but I'm not able to get HTTP routes like https:CONVEX_URL.site/route/$params

Am i doing something wrong? I get the Response No matching routes found

The docs: https://docs.convex.dev/functions/http-actions#defining-http-actions

// Define a route using a path prefix (typo - should be suffix)

http.route({
  // Will match /getAuthorMessages/User+123 and /getAuthorMessages/User+234 etc.
  pathPrefix: "/getAuthorMessages/",
  method: "GET",
  handler: getByAuthorPathSuffix,
});


My suggestion would be for an explicit path param definition like https://hono.dev/docs/api/routing#path-parameter
image.png
Web framework built on Web Standards for Cloudflare Workers, Fastly Compute, Deno, Bun, Vercel, Node.js, and others. Fast, but not only fast.
Routing - Hono
HTTP actions allow you to build an HTTP API right in Convex!
HTTP Actions | Convex Developer Hub
Was this page helpful?