Packages

@clerk/backend

3.29.0 · 14 Nov 2026MIT8.4M / weekRepositoryHomepagenpmAtom feed

Your version

0.36.0

13 Dec 2023Where it was published

0.38.15 is the newest release of 0.36.x.

In short

1 new1 internal

Release note

Minor Changes

  • Introduce Protect for authorization.

    Changes in public APIs:

    • Rename Gate to Protect

    • Support for permission checks. (Previously only roles could be used)

    • Remove the experimental tags and prefixes

    • Drop some from the has utility and Protect. Protect now accepts a condition prop where a function is expected with the has being exposed as the param.

    • Protect can now be used without required props. In this case behaves as <SignedIn>, if no authorization props are passed.

    • has will throw an error if neither permission or role is passed.

    • auth().protect() for Nextjs App Router. Allow per page protection in app router. This utility will automatically throw a 404 error if user is not authorized or authenticated.

      • inside a page or layout file it will render the nearest not-found component set by the developer

      • inside a route handler it will return empty response body with a 404 status code

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.