architecture-paradigm-hexagonal

architecture-paradigm-hexagonal is a skill for Claude Code from athola/claude-night-market. It costs 34 tokens per session (973 once invoked), scanned A, original, MIT.

A software design approach that keeps business logic separate from infrastructure such as databases, frameworks, user interfaces, and external APIs. These external systems connect through defined interfaces called ports and replaceable implementations called adapters.

In plain words
What is it for?
Use it to design ports and adapters, isolate domain logic, replace databases or frameworks, and test applications with mocked infrastructure.
Why use it?
It keeps the core rules stable when technical choices change and makes the core easier to test without real infrastructure. It also clarifies how third-party integrations enter and leave the application.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions Claude Code.

Part of the archetypes plugin — 15 skills shipped together

Good fit Use it to design ports and adapters, isolate domain logic, replace databases or frameworks, and test applications with mocked infrastructure.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/athola/claude-night-market/architecture-paradigm-hexagonal
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add athola/claude-night-market --skill architecture-paradigm-hexagonal
Clone the repo
git clone --depth 1 https://github.com/athola/claude-night-market

Made for: Claude Code.

Or install archetypes, the plugin that ships this one along with the rest of its 15 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for architecture-paradigm-hexagonal

README.md
[![agentmods](https://agentmods.dev/badge/skills/athola/claude-night-market/architecture-paradigm-hexagonal/github.svg)](https://agentmods.dev/skills/athola/claude-night-market/architecture-paradigm-hexagonal)
Your own site
<a href="https://agentmods.dev/skills/athola/claude-night-market/architecture-paradigm-hexagonal"><img src="https://agentmods.dev/badge/skills/athola/claude-night-market/architecture-paradigm-hexagonal/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for architecture-paradigm-hexagonal

Your own site · 80×15
<a href="https://agentmods.dev/skills/athola/claude-night-market/architecture-paradigm-hexagonal"><img src="https://agentmods.dev/badge/skills/athola/claude-night-market/architecture-paradigm-hexagonal.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 34 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 973 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00034 $0.00973
Opus 5 $0.00017 $0.00487
Sonnet 5 $0.00007 $0.00195
Haiku 4.5 $0.00003 $0.00097

Measured 9d ago against content hash d0546929fd63, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

architecture-paradigm-hexagonal scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/archetypes/skills/architecture-paradigm-hexagonal/SKILL.md · 86 lines

How it starts

The opening of the file, as written. The whole thing — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.

The Hexagonal (Ports & Adapters) Paradigm

When To Use

  • Isolating business logic from external dependencies
  • Systems needing swappable adapters for testing

When NOT To Use

  • Small scripts or utilities without external dependencies
  • Prototypes where port/adapter abstraction adds overhead

When to Employ This Paradigm

  • When you anticipate frequent changes to databases, frameworks, or user interfaces and need the core domain logic to remain stable.
  • When testing the core application requires mocking complex or slow infrastructure components.
  • When the development team needs to provide clear inbound and outbound interfaces for third-party integrations.

Adoption Steps

  1. Define Domain Ports: Identify all interactions with the core domain. Define inbound "driver ports" for actors that initiate actions (e.g., UI, CLI, automated jobs) and outbound "driven ports" for services the application consumes (e.g., database, message bus, external APIs). Express these ports as formal interfaces.
  2. Implement Adapters at the Edge: For each external technology, create an "adapter" that implements a port's interface. Keep the core domain entirely ignorant of the specific frameworks or libraries used in the adapters.
  3. Aggregate Use Cases: Organize the application's functionality into services that are built around business capabilities. These services orchestrate calls to the domain through the defined ports.
  4. Implement Contract Testing: validate that each adapter correctly honors the expectations of the port it implements. Use contract tests or consumer-driven contract tests to validate this behavior.
  5. Enforce Dependency Rules: The most critical rule is that only adapters may have dependencies on external frameworks. Enforce this with automated architecture tests or static analysis rules.

Key Deliverables

  • An Architecture Decision Record (ADR) that formally names the ports, their corresponding adapters, and the dependency policies.
  • A set of port interface definitions, stored with the core domain module.
  • A suite of contract tests for each adapter, alongside unit tests for the domain and application services.
  • Architectural diagrams showing the inbound and outbound data flows, for use by operations teams and architecture reviewers.

Read the full file on GitHub · 86 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 86 lines · 34 tokens per session scan A d0546929fd63

Subscribe to this mod's changes

architecture-paradigm-hexagonal is a skill published in the GitHub repository athola/claude-night-market (337 stars, last pushed yesterday), licensed MIT. It adds 34 tokens to every session and 973 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

architecture-patterns

Architecture validation and patterns for clean architecture, backend structure enforcement, project structure validation, test standards, and context-aware sizing. Use when designing system boundaries, enforcing layered architecture, validating project structure, defining test standards, or choosing the right…

yonatangross/orchestkit · 56 tokens

sync-new-data-type

Adds scaffolding for a new Sync data type in Chromium across protocol buffers, DataType definitions, feature flags, controller builders, unit tests, and metrics.

chromium/chromium · 36 tokens

backend/testing-guide

A guide for writing backend tests: small unit tests, tests that check connected parts such as an API and database, and end-to-end tests that follow a complete user flow.

echoVic/boss-skill · 30 tokens

unit-test-caching

Provides patterns for unit testing Spring Cache annotations (@Cacheable, @CachePut, @CacheEvict). Generates test code that mocks cache managers, verifies cache hit/miss behavior, tests cache key generation with SpEL expressions, validates eviction strategies, and checks conditional caching scenarios. Triggers: caching…

giuseppe-trisciuoglio/developer-kit · 88 tokens

spring-boot-test-patterns

Provides comprehensive testing patterns for Spring Boot applications covering unit, integration, slice, and container-based testing with JUnit 5, Mockito, Testcontainers, and performance optimization. Use when writing tests, @Test methods, @MockBean mocks, or implementing test suites for Spring Boot applications.

giuseppe-trisciuoglio/developer-kit · 64 tokens

unit-test-config-properties

Provides patterns for unit testing @ConfigurationProperties classes with @ConfigurationPropertiesTest. Validates property binding, tests validation constraints, verifies default values, checks type conversions, and mocks property sources for Spring Boot configuration properties. Use when testing application…

giuseppe-trisciuoglio/developer-kit · 75 tokens