Error Handling
The VibePeak API uses standard HTTP status codes and returns detailed error information to help you diagnose and resolve issues.Error Response Format
All errors follow a consistent structure:| Field | Description |
|---|---|
code | Machine-readable error code for programmatic handling |
message | Human-readable description of the error |
request_id | Unique identifier for support reference |
details | Additional context about the error (when available) |
HTTP Status Codes
| Status Code | Description |
|---|---|
200 | Success |
202 | Accepted - Task created successfully |
400 | Bad Request - Invalid parameters |
401 | Unauthorized - Invalid or missing API key |
403 | Forbidden - Plan doesn’t include API access |
404 | Not Found - Resource doesn’t exist |
429 | Too Many Requests - Rate limit exceeded |
500 | Internal Server Error - Something went wrong |
Error Codes Reference
Authentication Errors
INVALID_API_KEY
INVALID_API_KEY
Status: 401 UnauthorizedThe provided API key is invalid or doesn’t exist.Solution: Check that your API key is correct and properly formatted (
vpk_live_xxxxx or vpk_test_xxxxx).MISSING_API_KEY
MISSING_API_KEY
Status: 401 UnauthorizedNo API key was provided in the request.Solution: Add the
Authorization: Bearer vpk_live_xxxxx header to your request.Authorization Errors
PLAN_NOT_ALLOWED
PLAN_NOT_ALLOWED
Status: 403 ForbiddenYour subscription plan doesn’t include API access. Only Plus and Pro plans have API access.Solution: Upgrade your plan to Plus or Pro.
INSUFFICIENT_CREDITS
INSUFFICIENT_CREDITS
Status: 403 ForbiddenYour account doesn’t have enough credits for this operation.Solution: Purchase more credits or wait for your monthly credit refresh.
AVATAR_ACCESS_DENIED
AVATAR_ACCESS_DENIED
Status: 403 ForbiddenYou don’t have permission to use this avatar.Solution: Use a public avatar or one of your custom avatars. Custom avatars can only be accessed by their owner.
VOICE_ACCESS_DENIED
VOICE_ACCESS_DENIED
Status: 403 ForbiddenYou don’t have permission to use this voice.Solution: Use a public voice or one of your cloned voices. Cloned voices can only be accessed by their owner.
VOICE_EXPIRED
VOICE_EXPIRED
Status: 403 ForbiddenThe cloned voice has expired.Solution: Create a new cloned voice or use a public voice.
Internal Service Errors
AVATAR_URL_ERROR
AVATAR_URL_ERROR
Status: 500 Internal Server ErrorFailed to generate a secure URL for the avatar image.Solution: This is a server-side issue. Retry your request. If the issue persists, contact support with the request_id.
Rate Limiting Errors
CONCURRENCY_LIMIT_EXCEEDED
CONCURRENCY_LIMIT_EXCEEDED
Status: 429 Too Many RequestsYou’ve reached your concurrent task limit.Solution: Wait for existing tasks to complete, or upgrade your plan for higher limits.
Validation Errors
INVALID_JSON
INVALID_JSON
Status: 400 Bad RequestThe request body contains invalid JSON that cannot be parsed.Solution: Validate your JSON before sending. Common issues include:
- Missing or extra commas
- Unquoted property names
- Single quotes instead of double quotes
- Trailing commas in arrays or objects
- Unescaped special characters in strings
VALIDATION_ERROR
VALIDATION_ERROR
Status: 400 Bad RequestThe request parameters are invalid.Solution: Review the error message and fix the invalid parameters.
INVALID_AVATAR_ID
INVALID_AVATAR_ID
Status: 400 Bad RequestThe avatar ID format is invalid.Solution: Ensure the avatar ID is a valid UUID format (e.g.,
a1b2c3d4-e5f6-7890-abcd-ef1234567890).INVALID_VOICE_ID
INVALID_VOICE_ID
Status: 400 Bad RequestThe voice ID format is invalid.Solution: Use a valid voice ID from the List Voices endpoint or a cloned voice ID.
IMAGE_INACCESSIBLE
IMAGE_INACCESSIBLE
Status: 400 Bad RequestOne or more image URLs are not accessible.Solution: Ensure all image URLs are publicly accessible HTTPS URLs.
IMAGE_TIMEOUT
IMAGE_TIMEOUT
Status: 400 Bad RequestImage validation timed out.Solution: Use images hosted on fast, reliable servers.
MIXED_ORIENTATIONS
MIXED_ORIENTATIONS
Status: 400 Bad RequestImages have mixed orientations.Solution: Ensure all images are either portrait or landscape orientation. See our Image Requirements Guide for more details.
SSRF_BLOCKED
SSRF_BLOCKED
Status: 400 Bad RequestImage URL points to a private network.Solution: Use publicly accessible image URLs. Private/internal network URLs (localhost, 192.168.x.x, etc.) are not allowed.
Not Found Errors
USER_NOT_FOUND
USER_NOT_FOUND
Status: 404 Not FoundThe user account was not found.Solution: Ensure your API key is associated with a valid user account.
AVATAR_NOT_FOUND
AVATAR_NOT_FOUND
Status: 404 Not FoundThe specified avatar was not found.Solution: Use a valid avatar ID from the public avatars list or your custom avatars.
VOICE_NOT_FOUND
VOICE_NOT_FOUND
Status: 404 Not FoundThe specified voice was not found.Solution: Use a valid voice ID from the List Voices endpoint or a cloned voice ID.
TASK_NOT_FOUND
TASK_NOT_FOUND
Status: 404 Not FoundThe requested task doesn’t exist.Solution: Verify the task ID is correct.
Task Errors
IMAGE_PROCESSING_FAILED
IMAGE_PROCESSING_FAILED
Status: Returned in task status (not HTTP error)One or more images couldn’t be processed.Solution: Ensure all images are accessible URLs with supported formats (JPEG, PNG, WebP).
INVALID_IMAGE_URL
INVALID_IMAGE_URL
Status: 400 Bad RequestOne or more image URLs are inaccessible, invalid, or point to private networks.Solution: Verify all image URLs are publicly accessible HTTPS URLs.
Service Errors
SERVICE_UNAVAILABLE
SERVICE_UNAVAILABLE
SERVICE_TIMEOUT
SERVICE_TIMEOUT
Status: 504 Gateway TimeoutThe service request timed out.Solution: Retry your request. If the issue persists, contact support.
SERVICE_ERROR
SERVICE_ERROR
Status: 503 Service UnavailableAn internal service error occurred.Solution: Retry your request. If the issue persists, contact support with the request_id.
TTS_ERROR
TTS_ERROR
Status: 503 Service UnavailableText-to-speech generation failed.Solution: Retry your request. The TTS service uses a circuit breaker that may temporarily block requests after repeated failures.
QUEUE_ERROR
QUEUE_ERROR
Status: 503 Service UnavailableFailed to queue the video generation job.Solution: Retry your request after a few seconds.
Handling Errors
Retry Strategy
For transient errors, implement exponential backoff:Getting Support
When contacting support, include:- Request ID - Found in every error response
- Error code - The machine-readable error code
- Timestamp - When the error occurred
- Request details - The endpoint and parameters used

