Spaces:
Sleeping
Sleeping
Commit
·
f6d47a2
1
Parent(s):
938a5c7
update
Browse files
app/services/note_client.py
CHANGED
|
@@ -44,4 +44,13 @@ class NoteServiceClient:
|
|
| 44 |
json=payload,
|
| 45 |
)
|
| 46 |
r.raise_for_status()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 47 |
return r.json()
|
|
|
|
| 44 |
json=payload,
|
| 45 |
)
|
| 46 |
r.raise_for_status()
|
| 47 |
+
return r.json()
|
| 48 |
+
|
| 49 |
+
async def update_note_internal(self, note_id: str, payload: dict):
|
| 50 |
+
async with httpx.AsyncClient(timeout=30) as client:
|
| 51 |
+
r = await client.patch(
|
| 52 |
+
f"{NOTE_SERVICE_URL}/internal/notes/{note_id}",
|
| 53 |
+
json=payload,
|
| 54 |
+
)
|
| 55 |
+
r.raise_for_status()
|
| 56 |
return r.json()
|