mcpField
R
restful-hateoas

restful-hateoas

github.com/pproencaDevelopment218294 installsUpdated 11w ago
Repository

About restful-hateoas

A HATEOAS best-practices reference for developers designing REST APIs in Ruby on Rails. It arranges 47 rules across nine categories, following the request/response lifecycle from resource URIs to API evolution.

Key features

  1. 01Guidance across nine API categories
  2. 02Resource URI and modeling practices
  3. 03Hypermedia links and relation guidance
  4. 04HTTP method, status, and header rules
  5. 05Media type, collection, error, and caching practices

Use cases

  1. 01Designing REST resources and endpoint URIs
  2. 02Adding hypermedia links and actions to responses
  3. 03Planning pagination, filtering, and sorting endpoints
  4. 04Evolving APIs while accounting for existing clients

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/pproenca/dot-skills --skill restful-hateoas

After installing, type/restful-hateoasin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

AGENTS.md
metadata.json
assets/templates/
_template.md
references/
_sections.md
cache-cache-control-headers.md
cache-etag-conditional-get.md
cache-last-modified.md
cache-vary-header.md
coll-cursor-pagination.md
coll-field-selection.md
coll-filtering-via-query-params.md
coll-link-header-pagination.md
coll-sorting-convention.md
err-auth-error-codes.md
err-error-links.md
err-machine-readable-codes.md
err-problem-details.md
err-validation-errors.md
evolve-additive-changes-only.md
evolve-deprecation-headers.md
evolve-hateoas-reduces-versioning.md
http-delete-is-idempotent.md
http-get-must-be-safe.md
http-head-for-metadata.md
http-idempotency-key.md
http-patch-for-partial-updates.md
http-post-for-creation.md
http-put-for-full-replacement.md
link-action-affordances.md
link-embedded-vs-linked.md

Details

From the project README

Community RESTful HATEOAS Best Practices

Comprehensive guide to building REST APIs that reach the Glory of REST (Richardson Maturity Level 3) in Ruby on Rails. Contains 47 rules across 9 categories, ordered by the request/response lifecycle — from resource URI design through hypermedia link relations to API evolution.

When to Apply

Reference these guidelines when:

  • Designing new REST API endpoints and resource URIs
  • Adding hypermedia controls (_links, affordances) to API responses
  • Implementing content negotiation with HAL, JSON:API, or vendor media types
  • Building paginated, filterable, sortable collection endpoints
  • Reviewing APIs for proper HTTP method semantics and status codes
  • Evolving APIs without breaking existing clients

Rule Categories by Priority

PriorityCategoryImpactPrefix
1Resource ModelingCRITICALres-
2HTTP Method SemanticsCRITICALhttp-
3Hypermedia & Link RelationsCRITICALlink-
4Status Codes & Response HeadersHIGHstatus-
5Content Negotiation & Media TypesHIGHmedia-
6Collection PatternsMEDIUM-HIGHcoll-
7Error SemanticsMEDIUMerr-
8Caching & Conditional RequestsMEDIUMcache-
9API EvolutionLOW-MEDIUMevolve-

Quick Reference

1. Resource Modeling (CRITICAL)
2. HTTP Method Semantics (CRITICAL)
3. Hypermedia & Link Relations (CRITICAL)
4. Status Codes & Response Headers (HIGH)
5. Content Negotiation & Media Types (HIGH)
6. Collection Patterns (MEDIUM-HIGH)
7. Error Semantics (MEDIUM)
8. Caching & Conditional Requests (MEDIUM)
9. API Evolution (LOW-MEDIUM)

How to Use

Read individual reference files for detailed explanations and code examples:

Reference Files

FileDescription
references/_sections.mdCategory definitions and ordering
assets/templates/_template.mdTemplate for new rules
metadata.jsonVersion and reference information

Comments

Markdown supported