BriefFast is an application for creating and sharing professional briefs.
BriefFast now uses Redis for data storage instead of PostgreSQL. Follow these steps to set up Redis:
- Create a Redis instance on Railway (https://railway.app/)
- Copy your Redis connection URL - it should look like this:
redis://default:password@hostname:port - Update your
.envfile with the Redis URL:REDIS_URL="your-redis-connection-url"
If you have existing data in PostgreSQL that you want to migrate to Redis, follow these steps:
- Make sure both
DATABASE_URLandREDIS_URLare in your.envfile - Run the migration script:
npm run migrate:redis
BriefFast uses Datafast for analytics. To set up analytics:
- Create a Datafast account and get your website ID
- Update the
data-website-idinapp/layout.tsxwith your website ID - Update the
data-domaininapp/layout.tsxwith your domain name
First, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun devOpen http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.
This project uses next/font to automatically optimize and load Geist, a new font family for Vercel.
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.
Check out our Next.js deployment documentation for more details.
Build the application for production:
npm run buildStart the production server:
npm startBriefFast uses API key authentication to protect API endpoints. To configure this:
-
Add the following to your
.env.localfile:# API key for server-side verification API_KEY="your-random-secure-key" # Same key for client-side access NEXT_PUBLIC_API_KEY="your-random-secure-key" -
For production, generate a strong random key (at least 32 characters)
-
Keep these keys secret and don't commit them to version control
-
The middleware automatically allows public access to shared briefing links (/b/[uuid])
When making API requests from custom clients, include the API key in the header:
x-api-key: your-api-key