Error Handling
Learn how to handle errors from the Shortify API.
Error Response Format
Error responses always include success: false. Depending on endpoint, the message may be returned in msg or error.
400
Example Error Response (msg){
"success": false,
"msg": "ShortLink is Required"
}400
Example Error Response (error){
"success": false,
"error": "Header Key is Required"
}HTTP Status Codes
The Shortify API uses standard HTTP status codes to indicate success/failure. Some validation cases currently return success: false with HTTP 200 (for example, slug conflicts).
| Status Code | Description |
|---|---|
| 200 | OK - Request successful, or endpoint-specific validation failure |
| 400 | Bad Request - Missing required fields |
| 401 | Unauthorized - API key missing/blocked by gateway |
| 404 | Not Found - Workspace/app/link not found |
| 500 | Internal Server Error - Unhandled parsing/validation errors |