secondsky/claude-skills / plugins/cloudflare-zero-trust-access/skills/cloudflare-zero-trust-access
cloudflare-zero-trust-access
VerifiedCloudflare Zero Trust Access authentication for Workers. Use for JWT validation, service tokens, CORS, or encountering preflight blocking, cache race conditions, missing JWT headers.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 10.1 KB |
| references/access-policy-setup.md | markdown | 13.5 KB |
| references/common-errors.md | markdown | 15.1 KB |
| references/jwt-payload-structure.md | markdown | 12.8 KB |
| references/quick-start.md | markdown | 1.8 KB |
| references/service-tokens-guide.md | markdown | 15.3 KB |
| references/use-cases.md | markdown | 8.1 KB |
| references/value-proposition.md | markdown | 1.6 KB |
| scripts/create-service-token.shexecutable | script | 8.3 KB |
| scripts/test-access-jwt.shexecutable | script | 10.8 KB |
| templates/.env.example | other | 4.2 KB |
| templates/cors-access.ts | script | 8.1 KB |
| templates/hono-basic-setup.ts | script | 3.8 KB |
| templates/jwt-validation-manual.ts | script | 6.6 KB |
| templates/multi-tenant.ts | script | 10.1 KB |
| templates/service-token-auth.ts | script | 7.5 KB |
| templates/types.ts | script | 8.5 KB |
| templates/wrangler.jsonc | other | 3.9 KB |
templates/wrangler.jsonc
View on GitHub/**
* Cloudflare Zero Trust Access - Wrangler Configuration
*
* This is a complete wrangler.jsonc example for a Worker using Access authentication.
*
* Configuration includes:
* - Access team domain as environment variable
* - Access AUD (Application Audience) tag
* - Optional bindings (D1, KV, R2) for user/tenant data
* - Development and production environments
*
* Usage:
* 1. Copy this to your project root as wrangler.jsonc
* 2. Replace placeholder values with your actual configuration
* 3. Run: npx wrangler deploy
*/
{
"name": "my-access-protected-worker",
"main": "src/index.ts",
"compatibility_date": "2024-10-01",
// ============================================================================
// ENVIRONMENT VARIABLES
// ============================================================================
"vars": {
// Your Access team domain (without https://)
"ACCESS_TEAM_DOMAIN": "your-team.cloudflareaccess.com",
// Application Audience (AUD) tag from your Access policy
// Find this in: Zero Trust Dashboard > Access > Applications > Your App > Application Audience
"ACCESS_AUD": "your-app-aud-tag-here"
// Optional: Frontend URL for CORS
// "FRONTEND_URL": "https://app.example.com"
},
// ============================================================================
// BINDINGS (Optional - add as needed)
// ============================================================================
// D1 Database (for user profiles, tenant configs, etc.)
// Uncomment if using D1:
/*
"d1_databases": [
{
"binding": "DB",
"database_name": "access-users-db",
"database_id": "your-database-id"
}
],
*/
// KV Namespace (for session storage, user preferences, etc.)
// Uncomment if using KV:
/*
"kv_namespaces": [
{
"binding": "KV",
"id": "your-kv-namespace-id"
}
],
*/
// R2 Bucket (for user uploads, assets, etc.)
// Uncomment if using R2:
/*
"r2_buckets": [
{
"binding": "BUCKET",
"bucket_name": "user-uploads"
}
],
*/
// ============================================================================
// SECRETS (Set via Wrangler CLI - DO NOT commit to git!)
// ============================================================================
// Service token credentials (if using service tokens)
// Set with:
// npx wrangler secret put SERVICE_TOKEN_ID
// npx wrangler secret put SERVICE_TOKEN_SECRET
// ============================================================================
// ROUTES & CUSTOM DOMAIN
// ============================================================================
// Uncomment to map your Worker to a custom domain:
/*
"routes": [
{
"pattern": "api.example.com/*",
"custom_domain": true
}
],
*/
// ============================================================================
// DEVELOPMENT ENVIRONMENT (Optional)
// ============================================================================
// Configure separate settings for development
"env": {
"dev": {
"vars": {
"ACCESS_TEAM_DOMAIN": "your-dev-team.cloudflareaccess.com",
"ACCESS_AUD": "dev-app-aud-tag"
}
// Add dev-specific bindings here
},
"staging": {
"vars": {
"ACCESS_TEAM_DOMAIN": "your-staging-team.cloudflareaccess.com",
"ACCESS_AUD": "staging-app-aud-tag"
}
},
"production": {
"vars": {
"ACCESS_TEAM_DOMAIN": "your-prod-team.cloudflareaccess.com",
"ACCESS_AUD": "prod-app-aud-tag"
}
}
}
// ============================================================================
// ADDITIONAL CONFIGURATION
// ============================================================================
// Workers Limits
// "limits": {
// "cpu_ms": 50
// },
// Observability
// "observability": {
// "enabled": true
// },
// Tail consumers (for logging)
// "tail_consumers": [
// {
// "service": "my-log-consumer"
// }
// ]
}
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |