
Research
/Security News
737 Chrome VPN Extensions Linked to Brand Impersonation and Browser Traffic Redirection
The campaign amassed more than 75,000 installs by targeting Russian-speaking users seeking access to blocked services.
@authon/node
Advanced tools
Node.js server SDK for Authon — verify tokens, manage users, and validate webhooks.
npm install @authon/node
# or
pnpm add @authon/node
import { AuthonBackend } from '@authon/node';
const authon = new AuthonBackend('sk_live_...');
const user = await authon.verifyToken(accessToken);
console.log(user.id, user.email);
import express from 'express';
import { expressMiddleware } from '@authon/node';
const app = express();
app.use('/api', expressMiddleware({
secretKey: process.env.AUTHON_SECRET_KEY!,
}));
app.get('/api/profile', (req, res) => {
// req.auth is the verified AuthonUser
res.json({ user: req.auth });
});
import Fastify from 'fastify';
import { fastifyPlugin } from '@authon/node';
const app = Fastify();
app.addHook('onRequest', fastifyPlugin({
secretKey: process.env.AUTHON_SECRET_KEY!,
}));
app.get('/api/profile', (request, reply) => {
reply.send({ user: request.auth });
});
const authon = new AuthonBackend('sk_live_...');
// List users
const { data, total } = await authon.users.list({ page: 1, limit: 20 });
// Get a user
const user = await authon.users.get('user_abc123');
// Create a user
const newUser = await authon.users.create({
email: 'new@example.com',
password: 'securePassword',
displayName: 'New User',
});
// Update a user
await authon.users.update('user_abc123', {
displayName: 'Updated Name',
publicMetadata: { role: 'admin' },
});
// Ban / unban
await authon.users.ban('user_abc123', 'Violation of ToS');
await authon.users.unban('user_abc123');
// Delete a user
await authon.users.delete('user_abc123');
import { AuthonBackend } from '@authon/node';
const authon = new AuthonBackend('sk_live_...');
app.post('/webhooks/authon', express.raw({ type: 'application/json' }), (req, res) => {
const signature = req.headers['x-authon-signature'] as string;
try {
const event = authon.webhooks.verify(req.body, signature, process.env.WEBHOOK_SECRET!);
console.log('Event:', event);
res.sendStatus(200);
} catch (err) {
res.sendStatus(400);
}
});
AuthonBackend| Method | Returns | Description |
|---|---|---|
verifyToken(token) | Promise<AuthonUser> | Verify an access token |
users.list(options?) | Promise<ListResult<AuthonUser>> | List users with pagination |
users.get(id) | Promise<AuthonUser> | Get a user by ID |
users.create(data) | Promise<AuthonUser> | Create a user |
users.update(id, data) | Promise<AuthonUser> | Update a user |
users.delete(id) | Promise<void> | Delete a user |
users.ban(id, reason?) | Promise<AuthonUser> | Ban a user |
users.unban(id) | Promise<AuthonUser> | Unban a user |
webhooks.verify(payload, signature, secret) | Record<string, unknown> | Verify webhook HMAC-SHA256 signature |
| Export | Description |
|---|---|
expressMiddleware(options) | Express/Connect middleware, sets req.auth |
fastifyPlugin(options) | Fastify onRequest hook, sets request.auth |
FAQs
Authon Node.js SDK — verify tokens, manage users, validate webhooks
The npm package @authon/node receives a total of 21 weekly downloads. As such, @authon/node popularity was classified as not popular.
We found that @authon/node demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
/Security News
The campaign amassed more than 75,000 installs by targeting Russian-speaking users seeking access to blocked services.

Company News
Open source maintainers are under more pressure than ever. We're raising our open source program from the Team plan to the Business plan, free.

Security News
The supply chain control that delays freshly published gems now covers lockfile generation and gem vendoring in Ruby projects.