| name | webflow-reference-architecture |
| description | Implement Webflow reference architecture — layered project structure, client wrapper,
CMS sync service, webhook handlers, and caching layer for production integrations.
Trigger with phrases like "webflow architecture", "webflow project structure",
"how to organize webflow", "webflow integration design", "webflow best practices".
|
| allowed-tools | Read, Write, Edit, Grep |
| version | 1.5.0 |
| license | MIT |
| author | Jeremy Longshore <jeremy@intentsolutions.io> |
| tags | ["saas","design","no-code","webflow"] |
| compatibility | Designed for Claude Code |
Webflow Reference Architecture
Overview
Production-ready architecture for Webflow Data API v2 integrations. Layered design
separating API access, business logic, caching, and webhook handling.
Prerequisites
- TypeScript 5+ project
webflow-api SDK (v3.x)
- Understanding of service-oriented architecture
- Redis (optional, for distributed caching)
Project Structure
my-webflow-project/
├── src/
│ ├── webflow/ # Webflow API layer
│ │ ├── client.ts # WebflowClient singleton
│ │ ├── types.ts # TypeScript types for Webflow resources
│ │ ├── errors.ts # Custom error classes
│ │ └── cache.ts # Response caching (LRU/Redis)
│ ├── services/ # Business logic layer
│ │ ├── cms.service.ts # CMS content management
│ │ ├── ecommerce.service.ts # Products, orders, inventory
│ │ ├── forms.service.ts # Form submission processing
│ │ └── sync.service.ts # External data sync
│ ├── webhooks/ # Event handling layer
│ │ ├── router.ts # Event type routing
│ │ ├── handlers/
│ │ │ ├── form-submission.ts
│ │ │ ├── cms-item-changed.ts
│ │ │ └── ecomm-new-order.ts
│ │ └── middleware.ts # Signature verification
│ ├── api/ # HTTP endpoints
│ │ ├── health.ts
│ │ ├── webhooks.ts
│ │ └── content.ts
│ └── config/
│ └── webflow.ts # Environment-aware config
├── tests/
│ ├── unit/
│ │ ├── services/
│ │ └── webhooks/
│ └── integration/
│ └── webflow.integration.test.ts
├── .env.example
├── tsconfig.json
└── package.json
Layer Architecture
┌──────────────────────────────────────────────────┐
│ API Layer │
│ Express routes, webhook endpoints, health │
├──────────────────────────────────────────────────┤
│ Service Layer │
│ CMS sync, ecommerce, form processing │
│ (Business logic, orchestration) │
├──────────────────────────────────────────────────┤
│ Webflow Client Layer │
│ WebflowClient wrapper, error handling, types │
├──────────────────────────────────────────────────┤
│ Infrastructure Layer │
│ Cache (LRU/Redis), queue (p-queue), monitoring │
└──────────────────────────────────────────────────┘
Instructions
Layer 1: Webflow Client
import { WebflowClient } ;
{ getConfig } ;
: | = ;
(): {
(!client) {
config = ();
client = ({
: config.,
: config.,
});
}
client;
}
(): {
client = ;
}