anima-rate-limits

Featured

Implement rate limiting for Anima API code generation requests. Use when batching component generation, handling rate limit errors, or optimizing API throughput for large design systems. Trigger: "anima rate limit", "anima throttling", "anima batch generation".

AI & Automation 2,926 stars 433 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 99/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Anima Rate Limits ## Overview Anima API has per-minute rate limits on code generation. Each `generateCode` call processes one Figma node through AI — it's compute-intensive and rate-limited accordingly. ## Rate Limit Tiers | Tier | Generations/min | Concurrent | Notes | |------|----------------|------------|-------| | Partner (standard) | 10 | 2 | Most common | | Enterprise | 30 | 5 | Custom agreement | ## Instructions ### Step 1: Throttled Generator with Bottleneck ```typescript // src/anima/throttled-generator.ts import Bottleneck from 'bottleneck'; import { Anima } from '@animaapp/anima-sdk'; const limiter = new Bottleneck({ maxConcurrent: 2, minTime: 6000, // 10 per minute = 1 every 6 seconds reservoir: 10, reservoirRefreshInterval: 60000, reservoirRefreshAmount: 10, }); const anima = new Anima({ auth: { token: process.env.ANIMA_TOKEN! } }); async function throttledGenerate(params: any) { return limiter.schedule(() => anima.generateCode(params)); } // Batch generate with automatic throttling async function batchGenerate(nodeIds: string[], settings: any) { const results = []; for (const nodeId of nodeIds) { const result = await throttledGenerate({ fileKey: process.env.FIGMA_FILE_KEY!, figmaToken: process.env.FIGMA_TOKEN!, nodesId: [nodeId], settings, }); results.push({ nodeId, files: result.files }); console.log(`Generated ${nodeId}: ${result.files.length} files`); } return results; } export...

Details

Author
jeremylongshore
Repository
jeremylongshore/claude-code-plugins-plus-skills
Created
1 years ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category