Route Handlers
Clerk provides helpers to allow you to protect your Route Handlers, fetch the current user, and interact with the Clerk API.
If you aren't protecting your Route Handler using Clerk's middleware, you can check if the user is signed in.
Clerk provides integrations with a number of popular databases. Below is an example of retrieving a template to be used.
In some cases, you might need the current user in your Route Handler. Clerk provides an asynchronous helper called currentUser
to retrieve it.
The clerkClient
helper allows you to retrieve and update data from Clerk's API.
Last updated on