Backend Bff Pattern
Use when the user asks about Backend for Frontend (BFF), a mobile vs web API layer, API aggregation or composition for one client, or a frontend-specific gateway. Produces a BFF design with aggregation, partial failure and caching. Not for federated GraphQL (use api-graphql-federation) or general API design (use backend-api-design).
Install
npx skills add j4flmao/agent-skills --skill backend-bff-patterngit clone --depth 1 https://github.com/j4flmao/agent-skills.git /tmp/agent-skills
mkdir -p ~/.claude/skills
cp -r /tmp/agent-skills/skills/backend/universal/bff-pattern ~/.claude/skills/backend-bff-patternPersonal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.
From the SKILL.md
# Backend BFF Pattern
## Purpose
Design specialized Backend for Frontend (BFF) services that compose and transform backend APIs for each client type (web, mobile, IoT, third-party), reducing over-fetching and client complexity.
## Agent Protocol
### Trigger
Exact user phrases: "BFF", "Backend for Frontend", "API gateway", "gateway specialization", "frontend API", "mobile API", "web API", "API composition", "aggregation service", "frontend gateway", "BFF pattern".
### Input Context
- Client types consuming the API (web, iOS, Android, third-party).
- Backend microservices architecture.
- Latency and data shape requirements per client.
### Output Artifact
BFF architecture design or implementation snippet. No file unless requested.
### Response Format
```
BFF: {client type}
Backing Services: [{service list}]
Composition: {aggregation|transformation|caching}
Security: {auth pattern}
```
### Completion Criteria
- [ ] BFF per distinct client type defined.
- [ ] API composition logic documented.
- [ ] Auth model appropriate for each BFF.
- [ ] Caching and error handling configured.
- [ ] No business logic in BFF — only orchestration.
### Max Response Length
4 lines per BFF. 20 lines for full design.
## Workflow
### Step 1: Identify Client Types
```
Web BFF -> SPA (React, Vue)
Mobile BFF -> iOS + Android apps
Partners BFF -> Third-party integrations
Admin BFF -> Internal admin panel
```
### Step 2: Design BFF API per ClientDetails
- Skill name
backend-bff-pattern- Repository
- j4flmao/agent-skills
- Path
skills/backend/universal/bff-pattern/SKILL.md- License
- MIT
- Repo updated
- 17 November 2026
FAQ
What does the Backend Bff Pattern skill do?
Use when the user asks about Backend for Frontend (BFF), a mobile vs web API layer, API aggregation or composition for one client, or a frontend-specific gateway. Produces a BFF design with aggregation, partial failure and caching. Not for federated GraphQL (use api-graphql-federation) or general API design (use backend-api-design).
How do I install the Backend Bff Pattern skill?
skills CLI (Claude Code, Cursor, Codex and more): npx skills add j4flmao/agent-skills --skill backend-bff-pattern. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.
Is Backend Bff Pattern popular?
It lives in j4flmao/agent-skills, which has 45 GitHub stars and 6 forks.
Related skills
Agent Observability
45j4flmao/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).
AI Agent Architectures
45j4flmao/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 Agent Core Loop
45j4flmao/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).
Backend Bulk Import
45j4flmao/agent-skills
Use when the user asks about bulk import, CSV upload, importing a million-row CSV without locking the table, Excel import, row validation error reports, upsert from file or import progress. Produces a streaming import pipeline with staging, batching and an error report. Not for file upload storage itself (use backend-file-storage).
Backend Background Jobs
45j4flmao/agent-skills
Use when the user asks about background jobs, processing uploads in a background worker with retries, task queues, BullMQ, Sidekiq, Celery, dead letter queues or worker concurrency. Produces idempotent job workers with retry policy. Not for cron schedules (use backend-scheduling-cron) or broker design (use backend-message-queue).
Backend Caching
45j4flmao/agent-skills
Use when the user asks about caching, adding a Redis cache in front of a query, cache-aside, write-through, cache invalidation, TTL jitter, cache stampede or Memcached. Produces a cache strategy with keys, TTLs, invalidation and code. Not for browser/HTTP caching (use frontend-browser-caching) or distributed locks (use backend-distributed-locking).
Browse the most popular Claude skills, all software development skills, or write your own with the skills generator.