A simple JSON counter API built with Fastify, ready to deploy on Trapiche.
| Method | Path | Description |
|---|---|---|
GET |
/ |
App info |
GET |
/counter |
Get current count |
POST |
/counter/increment |
Increment counter |
POST |
/counter/decrement |
Decrement counter |
- Push this repo to your GitHub account
- Go to trapiche.cloud and create a new deployment
- Select this repository — Trapiche detects Fastify automatically
- Done. No Dockerfile needed.
Trapiche detects this as a Fastify app via "fastify" in package.json.
- Deploy mode: SSR / Docker
- Build step: skipped
- Start command:
npm start→node server.js
npm install
npm start
# GET http://localhost:3000/counter