SpeakNotes API 오류 코드
모든 실패는 동일한 JSON 봉투(envelope)로 반환됩니다: 안정적인 코드, 사람이 읽을 수 있는 메시지, 이 페이지로의 링크, 그리고 오류 발생 시 문제가 된 필드 정보가 포함됩니다.
오류 형태
오류는 HTML로 반환되지 않습니다. 코드는 안정적이므로 분기 처리에 사용할 수 있으며, 메시지는 언제든 변경될 수 있습니다.
HTTP/1.1 402 Payment Required
X-Request-Id: 0f0a3f2c-6f1e-4a5e-9f1b-9d0b5a2c7e11
{
"error": {
"type": "billing_error",
"code": "insufficient_credits",
"message": "This operation costs 14 credits and the account has 3 left.",
"doc_url": "https://speaknotes.io/developers/errors#insufficient_credits",
"request_id": "0f0a3f2c-6f1e-4a5e-9f1b-9d0b5a2c7e11"
}
}코드
| 코드 | 상태 | 의미 |
|---|---|---|
invalid_request | 400 | The request was malformed or failed validation. |
invalid_token | 401 | The credential is missing, malformed, expired, or revoked. |
insufficient_scope | 403 | The credential is valid but lacks the scope this operation needs. |
not_found | 404 | The requested resource does not exist. |
method_not_allowed | 405 | That HTTP method is not supported on this path. |
conflict | 409 | The request conflicts with the current state of the resource. |
payload_too_large | 413 | The uploaded file exceeds the size limit. |
unsupported_media_type | 415 | The file format is not supported. |
insufficient_credits | 402 | The account has no credits left for this operation. |
rate_limited | 429 | Too many requests. Retry after the interval in the Retry-After header. |
upstream_failure | 502 | A provider SpeakNotes depends on failed. |
content_policy | 422 | The content was refused by the AI content policy. |
internal_error | 500 | SpeakNotes failed to process the request. |
요청 ID
모든 응답에는 X-Request-Id 헤더가 포함되며 오류 본문에도 반복됩니다. 지원팀에 이 ID를 전달하면 정확한 실패 원인을 찾을 수 있습니다.
재시도 가이드
rate_limited 오류는 Retry-After 간격 이후에, upstream_failure는 지수 백오프를 사용하여 한두 번 재시도하세요. invalid_request, insufficient_scope, content_policy 오류는 항상 동일하게 실패하므로 재시도하지 마세요.