Claude Opus 5.5 が SeedRouter で利用できます
SeedRouter Docs
API Reference

エラー

リクエストエラーと失敗した画像タスクを読み解きます。

View Markdown

エラーの読み方

HTTP ステータスは API へのリクエストについての情報であり、error.code は失敗の理由を表します。両者は別のフィールドです: HTTP 200 はビジネスエラーコードではありません。

  • 拒否された送信は、HTTP エラーステータスと error オブジェクトを返します。
  • 成功したタスク照会は HTTP 200 を返します。生成が processing、completed、failed のいずれであるかは status で判断してください。
  • 失敗したタスクでは、message の文言ではなく error.code で分岐してください。失敗理由が異なればコードも異なり、同じ理由にはモデルをまたいで同じコードが使われます。
  • より具体的な公開可能な原因を特定できない場合は 60002 にフォールバックします。今後追加される未知のコードは、一般的な失敗として処理してください。

以下の表のエラーコードとメッセージは API がそのまま返す文字列のため、英語のまま記載しています。クライアントが実際に受け取る error.message と一字一句同じです。

Request errors

These HTTP statuses describe a rejected or unconfirmed submission, or a failed task query. A submission timeout does not prove that no task was created.

Error code (error.code)HTTP statusMeaningNext step
10001401The API key is missing or invalid.Check the Authorization header and API key.
10002403You do not have permission to make this request.Check access permissions.
20001400, 413, 422The request was rejected. Check the parameters against the API documentation.Correct the request parameters before retrying.
20002400The requested model is not available.Select a model listed in the model catalog.
30001402Not enough credits to run this request.Add credits before submitting.
30002429Too many requests. Please wait and try again.Wait and retry with backoff. Do not repeat accepted submissions.
50001404Task not found.Check the task ID and use the owning account’s key.
50002503Submission could not be confirmed. Check your tasks before submitting again.Check task history before submitting again; the request may have been accepted.
90001503The service is temporarily unavailable.Back off; retain any task ID already received.

Task failures

A successful task query returns HTTP 200 even when generation failed. Check status: "failed" and error.code in the response. These codes describe the task outcome, not the HTTP request. Failed tasks are not charged.

Error code (error.code)MeaningNext step
20001The request was rejected. Check the parameters against the API documentation.Correct the request parameters before retrying.
50003The task did not complete within the allowed time. Please try again.The task is not charged. You may submit a new task.
60001The request was rejected by the content policy. Please revise the prompt or input images.Revise the prompt or media input.
60002Generation could not be completed. Please try again.The task is not charged. You may submit a new task.
60003No output was generated. Please revise the prompt or try again.Revise the input or submit a new task.
60004The generated output could not be delivered. Please try again.The task is not charged. Try again later.
90001The service is temporarily unavailable.Back off; retain any task ID already received.
{
  "id": "task_...",
  "status": "failed",
  "error": {
    "code": 60002,
    "message": "Generation could not be completed. Please try again."
  }
}

送信自体がタイムアウトした場合は、再送信の前にタスク履歴を確認してください。最初のリクエストが受理されている可能性があります。