Group
  • Testing

    Write tests for my API endpoints

    Generates happy-path and error-path tests for each route, with mocks for external services like Stripe and email.

    • Improve quality
    • Ship faster
    • Beginner
    • Cursor
    • Replit
    • General

Free Prompt

Write tests for each of my API endpoints. Cover both the happy path and the error paths, and mock external services like Stripe and email. Use the testing framework already set up in my project, or recommend one if none exists.

What This Does / How This Helps

Generates happy-path and error-path tests for every API endpoint, with external services like Stripe and email mocked out. You get a test suite that catches regressions before your users do — without needing real API keys or sending real email.

Want to skip doing this by hand?

Fortivibe audits your app for all of the areas these prompts cover (and more).

See What We Check

Related Prompts