Choose and implement Replit validated architecture blueprints for different scales. Use when designing new Replit integrations, choosing between monolith/service/microservice architectures, or planning migration paths for Replit applications. Trigger with phrases like "replit architecture", "replit blueprint", "how to structure replit", "replit project layout", "replit microservice".
View on GitHubjeremylongshore/claude-code-plugins-plus-skills
replit-pack
plugins/saas-packs/replit-pack/skills/replit-architecture-variants/SKILL.md
February 1, 2026
Select agents to install to:
npx add-skill https://github.com/jeremylongshore/claude-code-plugins-plus-skills/blob/main/plugins/saas-packs/replit-pack/skills/replit-architecture-variants/SKILL.md -a claude-code --skill replit-architecture-variantsInstallation paths:
.claude/skills/replit-architecture-variants/# Replit Architecture Variants
## Overview
Three validated architecture blueprints for Replit integrations.
## Prerequisites
- Understanding of team size and DAU requirements
- Knowledge of deployment infrastructure
- Clear SLA requirements
- Growth projections available
## Variant A: Monolith (Simple)
**Best for:** MVPs, small teams, < 10K daily active users
```
my-app/
├── src/
│ ├── replit/
│ │ ├── client.ts # Singleton client
│ │ ├── types.ts # Types
│ │ └── middleware.ts # Express middleware
│ ├── routes/
│ │ └── api/
│ │ └── replit.ts # API routes
│ └── index.ts
├── tests/
│ └── replit.test.ts
└── package.json
```
### Key Characteristics
- Single deployment unit
- Synchronous Replit calls in request path
- In-memory caching
- Simple error handling
### Code Pattern
```typescript
// Direct integration in route handler
app.post('/api/create', async (req, res) => {
try {
const result = await replitClient.create(req.body);
res.json(result);
} catch (error) {
res.status(500).json({ error: error.message });
}
});
```
---
## Variant B: Service Layer (Moderate)
**Best for:** Growing startups, 10K-100K DAU, multiple integrations
```
my-app/
├── src/
│ ├── services/
│ │ ├── replit/
│ │ │ ├── client.ts # Client wrapper
│ │ │ ├── service.ts # Business logic
│ │ │ ├── repository.ts # Data access
│ │ │ └── types.ts
│ │ └── index.ts # Service exports
│ ├── controllers/
│ │ └── replit.ts
│ ├── routes/
│ ├── middleware/
│ ├── queue/
│ │ └── replit-processor.ts # Async processing
│ └── index.ts
├── config/
│ └── replit/
└── package.json
```
### Key Characteristics
- Separation of concerns
- Background job processing
- Redis caching
- Circuit breaker pattern
- Structured error handling
### Code Pattern
```typescript
// Service layer abstraction
class ReplitService {
constructor(
private client: ReplitClient,