Backend Developer (Node.js / Express / PostgreSQL) – API for Existing Next.js Frontend

Job ID: 39755213

Budget: $30 – $250 USD

Budget: $50 per completed function
Stack: Node.js, Express, PostgreSQL, Stripe, Cron jobs
Frontend: Already implemented in Next.js. You will only build the backend.
I need a backend developer to implement the API and database for my existing Next.js frontend.
Payment is $50 per function created, tested, and accepted (see list below).
Functions to Build ($50 each)
1) Authentication

Register, Login/Logout, Password Reset

Roles: user, admin

JWT authentication with httpOnly cookies

Password hashing with bcrypt or argon2

Acceptance: Users can register, login, logout, reset password via email, and routes are role-protected.

2) Subscriptions (Pricing)

Stripe subscriptions (Checkout + Webhooks)

Plans: Starter / Pro / Star

“My Subscription” endpoint showing current plan, renewal date, cancel option

Acceptance: User can subscribe via Stripe, database updates via webhook, endpoint returns current subscription info.

3) Post-Purchase ID by Email

After successful checkout:

Show instructions: “Send a ZIP + password with your ID to [configurable email]”

Send the same instructions by email to the user

Store an acknowledged flag when user clicks “I’ve sent it”

Acceptance: Configurable email via ENV, email sent, DB saves acknowledged flag.

4) User Dashboard – My Content

“My Content”: gallery/list of Images and Links added by Admin

Images stored on my server (filesystem)

Images: preview + open full

Links: open in new tab

Optional status/tags (reported, removed)

Acceptance: GET /me/content returns correct items; user sees only their own content.

5) My Profile

Show profile info from registration + subscription details

Allow user to edit email/password

Show current subscription

Acceptance: GET /me/profile and PUT /me/profile working with validation.

6) Admin Panel

Users table (search + pagination) with registration and subscription info

Send Content:

Upload Image (stored on server) or paste external URL

Add Link (URL + title/notes)

Bulk add optional

Soft delete / restore content

Acceptance: Admin can manage users, add/remove content, and users immediately see it in their dashboard.

7) Data Retention (Auto Cleanup)

Cron job: delete all images and links 30 days after subscription expiry

Remove files from the server filesystem and delete DB records

Write an audit log for each deletion

Acceptance: Daily cleanup runs automatically, expired users’ content is deleted, and audit records are stored.

Technical Requirements

Database: PostgreSQL (running on my server)

ORM: Prisma preferred (plain SQL acceptable if documented)

Storage: Local server filesystem for images (no AWS S3)

Email: Resend/SendGrid or Nodemailer (configurable sender)

Stripe: Subscriptions + webhook handling

Security: Input validation, rate limiting, role-based access control

Documentation: Postman or Swagger for all endpoints