A static site and public API for declining requests for free work. Inspired by nohello.com.
Live Site: https://nofree.dev API Base URL: https://api.nofree.dev
NoFree.dev provides a standard link to set boundaries with clients or friends asking for unpaid labor. It includes a functional JSON API built on Cloudflare Workers that serves refusal messages with varying levels of intensity.
The API allows you to fetch messages, submit new ones, and vote on existing entries.
Fetch a random refusal message.
Endpoint: GET /
Parameters:
intensity(optional): Integer1-10.1-4: Professional / Polite5-7: Firm / Direct8-10: Rude / Aggressive
Example Request:
curl "https://api.nofree.dev/?intensity=10"
Example Response:
{
"id": 42,
"content": "Read my lips: Pay me.",
"intensity": 10,
"votes": 150
}
Fetch a refusal by its unique ID.
Endpoint: GET /{id}
Example:
curl "https://api.nofree.dev/1"Add a new refusal to the database.
Endpoint: POST /submit
Body:
{
"content": "I do not code for exposure.",
"intensity": 5
}
Upvote a message by ID.
Endpoint: POST /vote
Body:
{
"id": 42
}
- Frontend: HTML5 / CSS3 (Hosted on GitHub Pages)
- Backend: Cloudflare Workers (Serverless JavaScript)
- Database: Cloudflare D1 (SQLite)
To run the backend locally, you need npm and wrangler installed.
- Install Dependencies
npm install
- Create Database
Run this command and **copy the
database_id**it outputs:
npx wrangler d1 create nofree-db
- Configure Database
Open
wrangler.tomland paste the ID you just copied into thedatabase_idfield:
[[d1_databases]]
binding = "DB"
database_name = "nofree-db"
database_id = "PASTE_YOUR_ID_HERE"
- Apply Schema Create the tables:
npx wrangler d1 execute nofree-db --local --file=./schema.sql
- Deploy
npx wrangler deploy
MIT License.