mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-24 23:51:48 +00:00
When the Feishu API returns a non-2xx response (e.g. 500 internal error), the body may be HTML or plain text instead of JSON, causing response.json() to throw a JSON parse error. This obscures the real HTTP error. Now checks response.ok and throws with the HTTP status before attempting JSON parsing, in both the token acquisition and card creation paths. Made-with: Cursor