Elysia Patterns

Use when the user asks about Elysia Eden Treaty clients, Elysia WebSocket pub/sub, Elysia macros, custom plugins, hook scopes (local, scoped, global) or file upload validation. Produces Elysia recipe code. Not for app folder structure (use elysia-architecture).

45 stars 6 forksSoftware Development

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add j4flmao/agent-skills --skill elysia-patterns
Manual install
git clone --depth 1 https://github.com/j4flmao/agent-skills.git /tmp/agent-skills
mkdir -p ~/.claude/skills
cp -r /tmp/agent-skills/skills/backend/elysia/patterns ~/.claude/skills/elysia-patterns

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

# Elysia Patterns

## Purpose
Implement Elysia.js-specific patterns — Eden Treaty type-safe client, WebSocket with Bun, macro-based guards, custom plugins, and validation patterns.

## Agent Protocol

### Trigger
User request includes: `elysia pattern`, `elysia eden treaty`, `elysia websocket`, `elysia plugin`, `elysia macro`, `elysia validation`, `elysia type safe`.

### Input Context
- Elysia version and plugin set
- Server-side patterns needed (auth, middleware, validation)
- Client-side (React, Svelte, Vue) for Eden Treaty

### Output Artifact
Code examples for the requested patterns — plugin, macro, WebSocket handler, Eden client.

### Response Format
Code-first: pattern name, problem, implementation. Compress output.

### Completion Criteria
- Pattern implemented with type safety
- Schema validation applied
- Error handling included
- Test example provided

### Max Response Length
4096 tokens

## Architecture Decision Trees

### Eden Treaty vs tRPC vs REST+OpenAPI

| Criterion | Eden Treaty | tRPC | REST+OpenAPI |
|-----------|-------------|------|--------------|
| Backend | Elysia only | TypeScript servers (Node, Bun, Deno, edge adapters) | Any |
| Type safety | Full-stack inference | Full-stack inference | Generated client |
| Setup | Single `typeof app` | Manual procedure defs | External tooling |
| File upload | Declarative | Manual | Multipart |
| Websocket | Via plugin | Via subscription | Separate |
| Flexibility | Elysia-native | tRPC server | Any HTTP |
Read the full skill on GitHub

Details

Skill name
elysia-patterns
Path
skills/backend/elysia/patterns/SKILL.md
License
MIT
Repo updated
17 November 2026

FAQ

What does the Elysia Patterns skill do?

Use when the user asks about Elysia Eden Treaty clients, Elysia WebSocket pub/sub, Elysia macros, custom plugins, hook scopes (local, scoped, global) or file upload validation. Produces Elysia recipe code. Not for app folder structure (use elysia-architecture).

How do I install the Elysia Patterns skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add j4flmao/agent-skills --skill elysia-patterns. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Elysia Patterns popular?

It lives in j4flmao/agent-skills, which has 45 GitHub stars and 6 forks.

Related skills

Agent Observability

45

j4flmao/agent-skills

Use when the user asks about agent observability, tracing agent reasoning, debugging an agent loop, OpenTelemetry GenAI spans for LLM calls, LLM cost tracking per agent, agent audit logs or hallucination/eval monitoring in production. Produces instrumentation config, trace schema, dashboards, alerts and cost attribution. Not for generic service tracing without LLMs (use devops-opentelemetry).

DevOps & Cloud

AI Agent Architectures

45

j4flmao/agent-skills

Use when the user asks to build an AI agent, design an agent that calls tools and keeps memory, write an agent system prompt or pick an agent framework (Claude Agent SDK, OpenAI Agents SDK, LangGraph). Produces an architecture brief covering loop, tools, memory, guardrails and evals, routing depth to child skills. Not for workflow patterns (use ai-agentic-workflows).

AI, LLMs & Agents

AI Agent Core Loop

45

j4flmao/agent-skills

Use when the user asks about the agent loop, ReAct vs plan-and-solve, re-planning, Reflexion, an agent stuck in a loop, max iterations or termination conditions. Produces a loop spec or patch with state, success predicate, caps and no-progress detection. Not for overall agent design (use ai-agent-architectures) or tool schemas (use tool-calling-principles).

AI, LLMs & Agents

Enterprise Architecture Governance

45

j4flmao/agent-skills

Use when the user asks about an architecture review board (ARB), architecture decision rights, architecture principles, design review gates, exception and waiver process or compliance with standards. Produces ARB charter, review process and principle checks. Not for the TOGAF ADM method (use enterprise-togaf-zachman) or a single design doc (use create-tech-spec).

Software Development

Elysia Architecture

45

j4flmao/agent-skills

Use when the user asks about an Elysia API on Bun with typed routes, Elysia project structure, plugin/module layout, lifecycle hook order, TypeBox schemas or auth macros. Produces an Elysia app structure with fail-fast config. Not for Eden Treaty, WebSocket or macro recipes (use elysia-patterns).

Software Development

Enterprise Identity Provider

45

j4flmao/agent-skills

Use when the user asks about SSO, SAML, OIDC federation, choosing an IdP (Okta, Entra ID, Keycloak), SCIM directory sync, MFA enforcement or access reviews. Produces IdP selection, federation and provisioning design. Not for in-app login code (use backend-auth-patterns) or permission models (use backend-authorization).

Software Development

Browse the most popular Claude skills, all software development skills, or write your own with the skills generator.