Skip to main content

Error Handling

The Garmint API uses standard HTTP status codes and returns consistent JSON error responses.

Error Response Format

All errors follow this structure:

Error Codes

Authentication Errors

Request Errors

Rate & Usage Errors

Server Errors

HTTP Status Codes

Handling Errors in Code

TypeScript

Python

Debugging Tips

Ensure you’re sending:
  • Authorization: Bearer gm_live_xxx
  • Content-Type: application/json for POST requests
Design and garment URLs must be:
  • Publicly accessible (no auth required)
  • HTTPS preferred
  • Valid image formats (PNG, JPEG, WebP)
The X-Tokens-Remaining header shows your current balance in every response.
Monitor X-RateLimit-Remaining to avoid hitting limits.

Getting Help

If you encounter persistent errors:
  1. Check our status page
  2. Search Discord for similar issues
  3. Email api@garmint.app with:
    • Your request (redact API key)
    • The error response
    • Timestamp of the request