claude-ws 0.3.91 → 0.3.92
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-ws",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.92",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "A beautifully crafted workspace interface for Claude Code with real-time streaming and local SQLite database",
|
|
6
6
|
"keywords": [
|
|
@@ -157,4 +157,4 @@
|
|
|
157
157
|
"devDependencies": {
|
|
158
158
|
"@types/js-yaml": "^4.0.9"
|
|
159
159
|
}
|
|
160
|
-
}
|
|
160
|
+
}
|
|
@@ -104,11 +104,13 @@ async function proxyRequest(
|
|
|
104
104
|
}
|
|
105
105
|
|
|
106
106
|
try {
|
|
107
|
+
log.trace({ targetUrl, requestBody: JSON.stringify(body) }, 'Start proxying request');
|
|
107
108
|
const response = await fetch(targetUrl, fetchOptions);
|
|
108
109
|
const contentType = response.headers.get('content-type') || '';
|
|
110
|
+
log.trace({ targetUrl, responseBody: JSON.stringify(response) }, 'End proxying request');
|
|
109
111
|
|
|
110
112
|
if (!response.ok) {
|
|
111
|
-
log.error({ targetUrl, status: response.status, statusText: response.statusText }, 'Anthropic API error');
|
|
113
|
+
log.error({ targetUrl, status: response.status, statusText: response.statusText, requestBody: JSON.stringify(body), responseBody: JSON.stringify(await response.text()) }, 'Anthropic API error');
|
|
112
114
|
}
|
|
113
115
|
const isStreaming = contentType.includes('text/event-stream');
|
|
114
116
|
|
|
@@ -160,7 +162,7 @@ async function proxyRequest(
|
|
|
160
162
|
headers: responseHeaders,
|
|
161
163
|
});
|
|
162
164
|
} catch (error) {
|
|
163
|
-
log.error({ error }, 'Error forwarding request');
|
|
165
|
+
log.error({ error, requestBody: JSON.stringify(body), targetUrl }, 'Error forwarding request');
|
|
164
166
|
return NextResponse.json(
|
|
165
167
|
{ error: 'Proxy error', message: error instanceof Error ? error.message : 'Unknown error' },
|
|
166
168
|
{ status: 502 }
|