DEV Community

Jawad Khan
Jawad Khan

Posted on

How I Built a Mock API Platform Solo and Shipped It to Production - MockStation.io

Every project I've worked on had the same frustration.

The frontend team is ready. QA is ready. The demo is scheduled for tomorrow.

But the backend isn't ready.

So everyone waits.

I've seen this happen on small projects, at agencies, at startups. It's one of those problems that feels so normal that teams just accept it as part of the process. I didn't want to accept it anymore — so I built MockStation.io.

What is MockStation?
MockStation is a platform that lets you create fully functional mock API endpoints in minutes — no backend required, no infrastructure to manage.

You define your endpoints, methods, headers, and response payloads. MockStation gives you a live, shareable URL that responds exactly like a real API. JSON, XML, GraphQL — all supported out of the box.

The part I'm most proud of is the dynamic test data engine. Instead of returning the same static JSON every time, you define data rules — names, emails, IDs, dates, numeric ranges — and every API call returns fresh, realistic data. It's the difference between testing with dummy data and testing with production-like data.

The stack

  • Backend: FastAPI running on AWS Lambda (serverless, scales to zero when idle)
  • Frontend: Next.js on Vercel
  • Database: MySQL on RDS
  • Auth: JWT + Google OAuth

I chose Lambda for the backend because MockStation's traffic pattern is unpredictable — a new user might hammer endpoints for an hour then go quiet. Paying for an always-on server didn't make sense at this stage. Lambda keeps costs near zero until there's real load.

FastAPI was an easy choice — it's fast, the developer experience is excellent, and the automatic OpenAPI docs saved me a lot of time during development.

The hardest part

Building the mock server routing was the trickiest piece.

Every organization gets their own namespace — so api.mockstation.io/acme-corp/v1/orders routes to the right mock endpoint for the right team. Getting subdomain extraction, path matching, and wildcard routing working reliably across environments took longer than I expected.

The other challenge was the dynamic data engine. Supporting templates like {{faker.name}}, {{faker.email}}, randomized ranges, and conditional responses while keeping the response time under 100ms required careful caching design.

What it can do today

  • Create endpoints with custom methods, headers, query params, and response bodies
  • Return JSON, XML, GraphQL, CSV, or Excel responses
  • Generate dynamic, realistic test data on every request
  • Share endpoints instantly with your team
  • Monitor usage and request history from a clean dashboard
  • Multi-project and multi-team support

Where I am now

Launched. Zero users. Trying to fix that.

The product is live at mockstation.io with a 30-day free trial — no credit card required. The trial includes 15,000 API requests/month, 5 projects, 10 endpoints per project, JSON, XML, and GraphQL support.

Paid plans start at $9/month for teams that need more.

What's next

  • ProductHunt launch (next week)
  • Webhook notifications on endpoint invocations
  • Request history with diff view

If you've ever been blocked waiting on a backend that wasn't ready — I'd love for you to try it and tell me what you think.

mockstation.io — feedback welcome in the comments.

Top comments (1)

Collapse
 
jawad_khan1992 profile image
Jawad Khan

Happy to answer any questions about the stack or the build. Also genuinely looking for feedback on what features would make this useful for your workflow.