Starter
Express starter
A minimal Express.js backend pre-configured with Meridian licensing. Clone, set your API key, and ship.
Quick start
Clone the repo, install dependencies, and run the dev server in under two minutes.
git clone https://github.com/meridian/starter-express
cd starter-express && npm install
MERIDIAN_KEY=sk_... npm run dev
cd starter-express && npm install
MERIDIAN_KEY=sk_... npm run dev
What is inside
- -Express 4.x with TypeScript
- -Meridian middleware for license validation
- -Environment-based configuration
- -Health-check endpoint
Usage
Import the Meridian middleware and wrap your protected routes. The middleware validates the license key on every request and returns a signed session token.
import express from 'express';
import { meridian } from '@meridian/express';
const app = express();
app.use('/api', meridian());
app.get('/api/data', (req, res) => res.json({ ok: true }));
import { meridian } from '@meridian/express';
const app = express();
app.use('/api', meridian());
app.get('/api/data', (req, res) => res.json({ ok: true }));