BLACKFRIDAY 来了!

    领取40%优惠
    Armox
    Armox Academy 📚
    介绍
    快速入门指南
    理解Brain
    节点
    AI模型
    画布编辑器
    训练 LoRA
    Train MiniMax H3 LoRA
    提示词工程
    Nano Banana ProFlux模型视频提示词音频提示词
    文本节点
    图像节点
    视频节点
    音频节点
    上传节点
    工具节点
    Academy.canvas3dNodes
    连接节点
    运行工作流
    什么是应用?
    创建您的第一个应用
    运行应用
    创意人士的应用创意
    API 参考入门
    身份验证模型端点应用端点任务端点账户端点Webhook错误与速率限制
    图库
    下载与导出
    使用AI聊天
    与AI进行头脑风暴
    文本模型
    GPT-5.4Gemini 3.1 ProClaude Opus 4.6GPT-5Gemini 2.5 FlashClaude 4.5 SonnetDeepSeek V3.1Grok 4Llama 3 70BLlama 3 8B
    图像模型
    Nano BananaNano Banana 2Nano Banana ProGPT Image 2.5Flux 2 ProKrea 2 LargeKrea 2 MediumFlux 2 FlexFlux 2 DevFlux 1.1 Pro UltraGrok ImagineFlux Kontext MaxFlux Kontext ProSeedream 4Seedream 4.5Wan 2.2 ImageQwen ImageQwen Image Edit AnglesStable Diffusion XLGrok 2 ImageGen4 Image
    视频模型
    Kling V2.5 Turbo ProKling 2.6 ProGrok VideoVeo 3.1Veo 3.1 FastSeedance 1 ProSeedance 1 Pro FastSeedance 1 LiteSeedance 2.0Wan 2.6 I2VWan 2.6 T2VWan 2.5 I2VWan 2.5 T2VSora 2 ProSora 2Hailuo 2.3Hailuo 2.3 FastVideo-01 DirectorGen4 Aleph
    音频模型
    MusicGenMusic 1.5Music-01Lyria 2Speech-02 TurboSpeech-02 HDVoice CloningXTTS-v2
    工具模型
    Topaz Image UpscalerPrunaAI UpscaleCrystal UpscalerRemove BackgroundFace SwapImage FiltersProfessional HeadshotText RemovalInpaintAdd WatermarkVideo Upscale (Runway)Video Upscale (Topaz)Video Upscale (Bytedance)Lip Sync ProAuto CaptionReplace CharacterMotion Transfer
    Academy.models3d
    Hunyuan3D V3
    社交媒体内容
    产品摄影
    营销活动
    视频制作
    音频与音乐
    多步骤工作流
    图像到图像
    一致风格
    积分优化
    常见错误
    键盘快捷键
    示例画廊
    提示词库
    Seedance 2.0 for AEC
    企业版概述
    管理员控制台
    申请积分
    常见问题
    理解积分
    故障排除
    API 参考API 参考入门错误与速率限制
    Copy to LLM

    Errors & Rate Limits

    The Armox Public API uses standard HTTP status codes and a consistent JSON error shape.

    Error Response Format

    { "error": "Human-readable message" }
    

    Examples:

    { "error": "Invalid API key" }
    
    { "error": "Insufficient credits. Required 1000, available 200" }
    

    Error Codes

    CodeMeaningTypical Cause
    400Bad RequestInvalid payload, missing required field, invalid model
    401UnauthorizedMissing or invalid Bearer API key
    402Payment RequiredInsufficient credits
    403ForbiddenPlan/access restrictions
    404Not FoundResource/job/app not found
    409ConflictJob cannot be cancelled in current state
    429Too Many RequestsPer-key rate limit exceeded
    500Internal Server ErrorUnexpected backend failure

    Rate Limits

    Rate limiting is enforced per API key using a rolling 60-second window.

    Every successful authenticated response includes:

    • X-RateLimit-Limit
    • X-RateLimit-Remaining
    • X-RateLimit-Reset

    If limit is exceeded, API returns:

    • status 429
    • error body { "error": "Rate limit exceeded" }
    • Retry-After: 60 header

    Handling 429 Responses

    Recommended strategy:

    1. read Retry-After header
    2. wait before retrying
    3. use exponential backoff with jitter for repeated 429s
    4. avoid synchronized retries across workers

    Common trigger:

    • Polling GET /api/v1/jobs/:id too aggressively (for example every 2-4 seconds) on low-RPM API keys.
    • Safer default is polling every 10-15 seconds and honoring Retry-After.

    JavaScript Retry Example

    async function requestWithRetry(url, options, retries = 3) {
      for (let attempt = 0; attempt <= retries; attempt += 1) {
        const response = await fetch(url, options);
        if (response.status !== 429) return response;
    
        const retryAfter = Number(response.headers.get("Retry-After") || 60);
        await new Promise((resolve) => setTimeout(resolve, retryAfter * 1000));
      }
    
      throw new Error("Exceeded retry attempts");
    }
    

    Polling Jobs Without Rate-Limit Errors

    Prompt Template
    async function waitForJob(jobId, apiKey) {
      while (true) {
        const response = await fetch(`https://armox.ai/api/v1/jobs/${jobId}`, {
          headers: { Authorization: `Bearer ${apiKey}` },
        });
    
        if (response.status === 429) {
          const retryAfter = Number(response.headers.get("Retry-After") || 60);
          await new Promise((resolve) => setTimeout(resolve, retryAfter * 1000));
          continue;
        }
    
        const job = await response.json();
        if (["completed", "failed", "cancelled"].includes(job.status)) return job;
    
        await new Promise((resolve) => setTimeout(resolve, 10000));
      }
    }

    Credits and Billing Behavior

    • credits are charged when a run is accepted
    • failed jobs are refunded by the execution flow
    • monitor usage via GET /api/v1/account

    Common Production Errors

    • Invalid API key: wrong/expired/revoked key
    • Insufficient credits ...: top up credits or reduce run cost
    • Rate limit exceeded: add backoff + queueing

    Debugging Checklist

    • verify Authorization: Bearer ... is present
    • verify endpoint path and method
    • log request IDs/job IDs in your app
    • capture response headers for rate-limit observability
    • persist failed payloads for replay

    Related Pages

    • Authentication
    • Jobs Endpoint
    • Account Endpoint
    上一页Webhook
    下一页图库

    准备好转变 您的创意工作流了吗?

    无需信用卡500免费积分

    本页内容

    Error Response FormatError CodesRate LimitsHandling 429 ResponsesJavaScript Retry ExamplePolling Jobs Without Rate-Limit ErrorsCredits and Billing BehaviorCommon Production ErrorsDebugging ChecklistRelated Pages