Deno

Talon Auth works with Deno's built-in HTTP server. Deno uses the standard Web platform Request/Response API and imports npm packages via the npm: specifier — no install step required.

Setup

No install needed. Import talon-auth directly using the npm: prefix:

import { createVerifier } from 'npm:talon-auth'

Create a verifier with your app ID from the Talon dashboard:

const verifier = createVerifier({ appId: '[your-app-id]' })

Verifying requests

Call verifier.verifyHeader() with the value of the Authorization header. Use req.headers.get('authorization') to read it from the Web-standard Headers object:

const { user } = await verifier.verifyHeader(req.headers.get('authorization')!)

Example

The example below uses Deno.serve to handle requests. The index route serves an HTML page with the <talon-login> component, and the /message route verifies the JWT and returns a greeting.

deno.ts
Subscribe to our NewsletterGet new Feathers content as it becomes available.
Talon Auth logo

Copyright © 2012 - 2026 feathers.dev