feat: Implement Akte webhook for EspoCRM to queue entity IDs for synchronization
fix: Refactor Akte sync logic to handle multiple Redis queues and improve logging refactor: Enhance parameter flattening for EspoCRM API calls
This commit is contained in:
@@ -150,12 +150,16 @@ class AdvowareService:
|
||||
try:
|
||||
endpoint = f"api/v1/advonet/Akten/{akte_id}"
|
||||
result = await self.api.api_call(endpoint, method='GET')
|
||||
|
||||
|
||||
# API may return a list (batch response) or a single dict
|
||||
if isinstance(result, list):
|
||||
result = result[0] if result else None
|
||||
|
||||
if result:
|
||||
self._log(f"[ADVO] ✅ Fetched Akte {akte_id}: {result.get('az', 'N/A')}")
|
||||
|
||||
|
||||
return result
|
||||
|
||||
|
||||
except Exception as e:
|
||||
self._log(f"[ADVO] Error loading Akte {akte_id}: {e}", level='error')
|
||||
return None
|
||||
|
||||
Reference in New Issue
Block a user