Overview
Access the Workers for Platforms API:Dispatch namespaces
Dispatch namespaces provide isolation between customer Workers in a multi-tenant environment.Create a dispatch namespace
Create a new namespace for isolating customer Workers.string
required
Your Cloudflare account ID
string
required
Name for the dispatch namespace
string
The unique identifier for the namespace
string
The namespace name
string
ISO 8601 timestamp when the namespace was created
List dispatch namespaces
Retrieve all dispatch namespaces in your account.string
required
Your Cloudflare account ID
Get a dispatch namespace
Retrieve details about a specific dispatch namespace.string
required
The name of the dispatch namespace
string
required
Your Cloudflare account ID
Delete a dispatch namespace
Delete a dispatch namespace and all Workers within it.string
required
The name of the dispatch namespace to delete
string
required
Your Cloudflare account ID
Use cases
Multi-tenant SaaS platforms
Use dispatch namespaces to isolate customer code:Dynamic Worker deployment
Deploy Workers programmatically for your users:Best practices
- Namespace naming: Use a consistent naming convention for customer namespaces (e.g.,
customer-{id}) - Isolation: Each customer should have their own namespace to ensure security and isolation
- Cleanup: Delete namespaces when customers churn to free up resources
- Monitoring: Track namespace usage and performance per customer