agentsclimarketplace

Api contract review

Skill ajaygodbole7/rest-api-skill/skills/api-contract-review

Zalando RESTful API Guidelines reformatted as Agent Skills for AI coding agents

Install
npx -y skills add ajaygodbole7/rest-api-skill --skill api-contract-review

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Use when reviewing or auditing an existing OpenAPI 3.1 specification for compliance with Zalando RESTful API Guidelines. Produces a structured checklist report (BLOCKER / WARNING / INFO severity) covering naming, security, HTTP usage, pagination, compatibility, and all other rule categories. Activate for API review, contract audit, or spec compliance checking tasks.

The file declares its own license as CC-BY-4.0 (derivative of Zalando RESTful API Guidelines by Zalando SE). That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

9.2 KB, as published. Nobody here has run it

API Contract Review

You are an API contract reviewer. Given an OpenAPI 3.1 specification, you systematically check every applicable Zalando guideline rule and produce a structured compliance report.

Inputs

InputRequiredDescription
OpenAPI 3.1 YAML/JSON specYesThe specification to review
x-audience contextNoExpected audience (external-public, external-partner, company-internal, component-internal)
Known exemptionsNoList of rule numbers the team has an approved exemption for

Severity Ratings

LevelRFC 2119Meaning
BLOCKERMUST / MUST NOTSpecification is non-compliant; must be fixed before merge
WARNINGSHOULD / SHOULD NOTStrong recommendation violated; document justification if skipped
INFOMAYOptional best practice; note for awareness

Review Checklist

Work through each section in order. For every check, emit one line:

  • PASS — rule satisfied
  • FAIL (BLOCKER|WARNING|INFO) — rule violated, with location and fix guidance
  • N/A — rule does not apply to this spec

1. Meta & General

CheckRuleSeverityWhat to verify
✅/❌ OpenAPI 3.1 with info block[#101], [#218]BLOCKERopenapi: "3.1.x" present; info.title, info.description, info.contact populated
✅/❌ Semantic version in info.version[#116]BLOCKERinfo.version follows MAJOR.MINOR.PATCH semver
✅/❌ x-api-id present[#215]BLOCKERinfo.x-api-id is a valid UUID
✅/❌ x-audience present[#219]BLOCKERinfo.x-audience is one of: external-public, external-partner, company-internal, component-internal
✅/❌ US English[#103]WARNINGAll descriptions, summaries, and enum values use American English spelling
✅/❌ Immutable remote refs[#234]BLOCKERAny $ref pointing to a remote URL uses a version-pinned, immutable reference
✅/❌ Published spec[#192]WARNINGSpec is stored in a discoverable location (API portal, repository)

2. Security

CheckRuleSeverityWhat to verify
✅/❌ All endpoints secured[#104]BLOCKEREvery operation has a security requirement or inherits a global one; no unprotected endpoints
✅/❌ OAuth scopes defined[#105]BLOCKERsecuritySchemes defines OAuth2 flows; scopes follow <api-name>.<resource>.<access-mode> naming

3. Naming Conventions

CheckRuleSeverityWhat to verify
✅/❌ snake_case properties[#118]BLOCKERAll schema property names use snake_case (no camelCase, no kebab-case)
✅/❌ kebab-case paths[#129]BLOCKERAll path segments use lowercase-kebab-case
✅/❌ snake_case query params[#130]BLOCKERAll query parameter names use snake_case
✅/❌ Plural resource names[#134]WARNINGCollection resource path segments are plural nouns
✅/❌ Verb-free URLs[#141]BLOCKERNo verbs in path segments; actions use HTTP methods or command resource pattern
✅/❌ Domain-specific names[#142]WARNINGProperty and resource names reflect the business domain, not generic terms
✅/❌ UPPER_SNAKE_CASE enums[#240]WARNINGEnum values use UPPER_SNAKE_CASE unless representing domain literals

4. Data Types & Formats

CheckRuleSeverityWhat to verify
✅/❌ Number/integer format defined[#171]BLOCKEREvery type: number or type: integer has an explicit format (int32, int64, float, double, decimal)
✅/❌ Date/time ISO 8601[#169]BLOCKERDate properties use format: date (RFC 3339 full-date) or format: date-time (RFC 3339 date-time with UTC offset)
✅/❌ No null booleans[#122]BLOCKERBoolean properties are required or have a default; never nullable
✅/❌ No null empty arrays[#124]WARNINGArray properties return [] rather than null when empty
✅/❌ Top-level JSON objects[#110]BLOCKERAll request and response bodies are JSON objects at the top level, never bare arrays or primitives
✅/❌ Common money/address objects[#173], [#249]WARNINGMoney amounts use a Money object with amount + currency; addresses follow standard structure

5. HTTP Methods & Status Codes

CheckRuleSeverityWhat to verify
✅/❌ Correct method usage[#148]BLOCKERGET is safe/idempotent, PUT is idempotent full replace, PATCH is partial update, DELETE is idempotent, POST for creation/commands
✅/❌ All responses specified[#151]BLOCKEREvery operation defines success and relevant error responses; no missing response codes
✅/❌ Problem JSON for errors[#176]BLOCKERAll 4xx/5xx responses use application/problem+json (RFC 9457) with type, title, status
✅/❌ No stack traces[#177]BLOCKERError response schemas do not include internal implementation details or stack traces
✅/❌ Most specific status codes[#220]WARNINGOperations return the most specific status code (e.g., 201 for creation, 204 for no content, not just 200 everywhere)

6. Pagination

CheckRuleSeverityWhat to verify
✅/❌ Collections paginated[#159]BLOCKERAll list/collection endpoints support pagination via query parameters
✅/❌ Cursor-based preferred[#160]WARNINGLarge or frequently-updated collections use cursor-based pagination rather than offset-based

7. Compatibility & Lifecycle

CheckRuleSeverityWhat to verify
✅/❌ No breaking changes[#106]BLOCKERIf reviewing a diff: no removed endpoints, no removed required properties, no changed types
✅/❌ REST maturity level 2[#162]WARNINGAPI uses proper HTTP methods and status codes (Richardson maturity level 2+)
✅/❌ Deprecated items marked[#187]WARNINGAny deprecated operations, parameters, or schemas have deprecated: true set

Review Procedure

START
│
├─ 1. Parse the OpenAPI spec
│     ├─ Valid YAML/JSON?  → if not, BLOCKER: spec is unparseable
│     └─ openapi: "3.1.x"? → if not, BLOCKER [#101]
│
├─ 2. Walk Meta & General checks (Section 1)
│     └─ For each check: emit ✅ PASS, ❌ FAIL (severity), or ⬚ N/A
│
├─ 3. Walk Security checks (Section 2)
│
├─ 4. Walk Naming checks (Section 3)
│     └─ Scan every path, parameter, property, and enum value
│
├─ 5. Walk Data checks (Section 4)
│     └─ Inspect every schema recursively
│
├─ 6. Walk HTTP checks (Section 5)
│     └─ Inspect every operation and response
│
├─ 7. Walk Pagination checks (Section 6)
│     └─ Identify collection endpoints (GET returning arrays)
│
├─ 8. Walk Compatibility checks (Section 7)
│     └─ If a previous version is provided, diff for breaking changes
│
└─ 9. Produce Report

Output Format

review:
  spec: "<filename or path>"
  date: "YYYY-MM-DD"
  summary:
    blockers: <count>
    warnings: <count>
    info: <count>
    pass: <count>
    not_applicable: <count>
  findings:
    - rule: "#NNN"
      check: "<check description>"
      result: "FAIL"
      severity: "BLOCKER | WARNING | INFO"
      location: "<JSON pointer or path in spec>"
      message: "<what is wrong>"
      fix: "<how to fix it>"
    # ... one entry per failing check
  passed:
    - rule: "#NNN"
      check: "<check description>"
    # ... one entry per passing check
  verdict: "APPROVED | CHANGES REQUESTED"

Verdict Logic

if blockers > 0:
    verdict = "CHANGES REQUESTED"
else:
    verdict = "APPROVED"  # warnings are advisory

Important Notes

  • Every rule number [#NNN] in this skill maps to the Zalando RESTful API Guidelines rule catalog. Do not fabricate rule numbers.
  • When a rule is not applicable (e.g., no collection endpoints to check pagination), mark it ⬚ N/A rather than ✅ PASS.
  • If the spec includes x-audience: component-internal, some external-facing rules may be relaxed — note this in the report but still flag them as INFO.

Derived from the Zalando RESTful API Guidelines by Zalando SE, licensed under CC-BY-4.0.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.