Aller au contenu principal

Error Handling

JSON-RPC error format

{
"jsonrpc": "2.0",
"id": 1,
"error": {
"code": 200,
"message": "Ekomium Server Error",
"data": {
"name": "ekomium.exceptions.AccessError",
"message": "Access Denied",
"debug": "..."
}
}
}

Common errors

ErrorCauseSolution
Access DeniedInsufficient permissionsRequest elevated access from Ekomium
Authentication failedWrong login/passwordVerify credentials
Invalid fieldField not available on modelCheck platform version & field list with Ekomium
Connection refusedInstance downCheck instance status with Ekomium

HTTP status codes

Ekomium JSON-RPC always returns HTTP 200. Check the error key in the response body.

Retry strategy

import time

def ekomium_call_with_retry(fn, max_retries=3):
for attempt in range(max_retries):
try:
return fn()
except Exception as e:
if attempt == max_retries - 1:
raise
time.sleep(2 ** attempt)

Rate limiting

Recommended limits for integrations:

  • Authentication: max 10/min
  • Read endpoints: max 60/min
  • Batch size: max 200 records per request

Exceeding limits may result in temporary IP blocking by Cloudflare.