External api integration

From Dadmin88/hermes-profile-packs · View interactive version

External api integration is an AI agent skill from the GitHub repository Dadmin88/hermes-profile-packs. Integrate an external API through authoritative contract discovery, typed mapping, authentication, pagination, limits, compatibility, resilient client behavior, and provider-isolated application boundaries.

How to use this skill

Skill file

External API Integration

Use when application behavior depends on calling a third-party or separately owned HTTP/RPC/GraphQL API.

Procedure

  1. Read the provider's current authoritative documentation and pin the API/version or compatibility assumptions the integration relies on. Record deprecation/lifecycle information when the provider publishes it.
  2. Define the internal operation the application needs before mirroring provider resources. Keep provider-specific fields and error quirks behind a clear adapter boundary where practical.
  3. Implement authentication/authorization using the provider's supported mechanism and minimum required scopes/permissions. Resolve credentials through approved secret/identity systems, never source code or URLs.
  4. Validate and normalize request/response data: identifiers, types, optional/null fields, enum expansion, units, timestamps/timezones, pagination, ordering, and partial results.
  5. Define timeout, cancellation, connection behavior, rate-limit handling, pagination termination, and retry semantics based on provider guarantees and operation idempotency.
  6. Classify provider failures into actionable internal categories while retaining provider request IDs/status/details needed for diagnosis without exposing secrets or sensitive payloads.
  7. Handle compatibility/deprecation deliberately. Encapsulate provider version differences and add monitoring for warnings or behaviors that signal upcoming migration.
  8. Add observability for call volume, latency, errors, rate-limit pressure, retries, and provider correlation identifiers.
  9. Test against sandbox/test endpoints when trustworthy and supplement with contract fixtures for important success, pagination, auth, rate-limit, malformed, and error responses.
  10. Define degraded behavior for provider unavailability: queue, retry later, cached/read-only mode, explicit user failure, or another product-approved response.

Decision rules

Quality gate

The integration is ready when the current provider contract is understood and versioned, credentials/scopes are appropriate, data is validated and mapped cleanly, limits/retries/failures are explicit, provider-specific behavior is contained, telemetry supports diagnosis, and representative provider failure/deprecation scenarios have a defined response.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.