api-testing

Automate API testing across REST and GraphQL services with Supertest, Pact, MSW, and Zod schemas.

207|31|Updated Mar 14, 2026
One-click install
npx skills add https://github.com/AbsolutelySkilled/AbsolutelySkilled --skill api-testing-absolutelyskilled
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-testing
Source: https://github.com/AbsolutelySkilled/AbsolutelySkilled/tree/main/skills/api-testing
Command: npx skills add https://github.com/AbsolutelySkilled/AbsolutelySkilled --skill api-testing-absolutelyskilled

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

API testing across REST and GraphQL services to validate behavior, contracts, and resilience, reducing regressions and speeding feedback.

Core Features & Use Cases

  • Opinionated testing guidance for unit, integration, and contract tests, including mocks and contract verification.
  • Practical recipes for Supertest, Pact, MSW, and GraphQL testing workflows.
  • Use Case: When building or maintaining APIs, this skill helps teams verify endpoint behavior, data contracts, and error handling across environments.

Quick Start

Write a REST endpoint test using Supertest against a sample Express app and verify a 200 response.

Frequently Asked Questions about api-testing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test a REST API endpoint using Supertest?

To test a REST API endpoint using Supertest, you write a test script that imports your Express app and verifies the HTTP response, such as asserting a 200 status code for successful requests.

What is contract testing for APIs and when do I need it?

Contract testing for APIs validates that services adhere to agreed data schemas and interactions. You need contract testing when integrating REST or GraphQL services to catch regressions early and enforce robust behavior.

Can I use mock servers with GraphQL testing workflows?

Yes, you can use mock servers with GraphQL testing workflows. Tools like MSW allow you to intercept and mock network requests, enabling isolated unit and integration tests for your GraphQL services.

Does Zod schema validation work for API testing?

Zod schema validation works for API testing by enforcing data contracts and validating API responses. It integrates into your testing strategy to ensure endpoint payloads match expected structures.

What's the best way to automate API testing across REST and GraphQL services?

The best way to automate API testing across REST and GraphQL services is to implement opinionated testing guidance covering unit, integration, and end-to-end tests using tools like Supertest, Pact, and MSW.

How does Pact help with API contract verification?

Pact helps with API contract verification by defining consumer-driven contracts, ensuring that REST or GraphQL providers and consumers communicate correctly and preventing integration regressions across environments.