api-patterns

Identify and justify the optimal API pattern among REST, GraphQL, and tRPC.

Updated Jan 22, 2026
One-click install
npx skills add https://github.com/Arbab1308/BrownlandBL-2 --skill api-patterns-arbab1308
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-patterns
Source: https://github.com/Arbab1308/BrownlandBL-2/tree/main/.agent/skills/api-patterns
Command: npx skills add https://github.com/Arbab1308/BrownlandBL-2 --skill api-patterns-arbab1308

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

API design teams often struggle to choose the right architectural style (REST, GraphQL, or tRPC) and establish consistent patterns for versioning, responses, and pagination.

Core Features & Use Cases

  • Clear decision guidance between REST, GraphQL, and tRPC based on project needs.
  • Best-practice criteria for response formats, status handling, and versioning.
  • Real-world scenarios illustrating when to adopt each pattern across services, monorepos, and public APIs.

Quick Start

Craft a design brief by stating your API consumers and data needs, and select the optimal API pattern accordingly.

Frequently Asked Questions about api-patterns

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

FAQPage Schema
How do I choose between REST, GraphQL, and tRPC for a new backend project?

Choosing between REST, GraphQL, and tRPC requires evaluating your API consumers and data needs. This pattern provides a decision framework that justifies the optimal API architecture based on scalability, maintenance, and integration requirements.

What is the best way to handle API versioning and pagination across microservices?

Handling API versioning and pagination across microservices requires consistent architectural patterns. This framework establishes documented criteria for versioning guidance, response formats, and pagination strategies to maintain uniformity.

When should I use GraphQL instead of REST for complex data integration?

You should use GraphQL instead of REST when your API design involves complex data integration needs and multiple consumers requiring flexible queries. The framework identifies specific real-world scenarios where each pattern optimizes integration.

Does this API design guidance work for both monorepos and public APIs?

Yes, this API design guidance applies to monorepos and public APIs. The decision criteria illustrate real-world scenarios for adopting architectural patterns across services, ensuring scalable API design regardless of project structure.

How do I document criteria for selecting an API pattern in a monorepo?

To document criteria for selecting an API pattern in a monorepo, you craft a design brief stating your API consumers and data needs. This approach yields documented criteria and a clear decision framework for pattern selection.

Why does tRPC make sense for certain API design decisions over REST?

tRPC makes sense for API design decisions when you need end-to-end type safety within a monorepo without manual schema synchronization. The framework justifies this choice by evaluating maintenance overhead against your specific integration needs.