From 98816121987b6dd24283453df895f0756025adfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matis=20Andr=C3=A9?= <45696697+tismatis@users.noreply.github.com> Date: Fri, 12 Sep 2025 06:47:37 +0200 Subject: [PATCH] Fixed an invalid example in documentation The problem is in the documentation, there is no header and the wings will basically refuse to let connect the client without it. --- docs/api/client/servers.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/docs/api/client/servers.md b/docs/api/client/servers.md index 4459fcf..b23f04b 100644 --- a/docs/api/client/servers.md +++ b/docs/api/client/servers.md @@ -910,7 +910,11 @@ const response = await axios.get(\`https://your-panel.com/api/client/servers/\${ const { token, socket } = response.data.data; // Connect to WebSocket -const ws = new WebSocket(socket); +const ws = new WebSocket(socket, { + headers: { + "Origin": "https://your-panel.com" + } +}); ws.on('open', () => { // Authenticate @@ -2131,4 +2135,4 @@ Returns empty response body with status code 202 (Accepted). - Explore [File Management](./files) for server file operations - Check [Database Management](./databases) for server databases -- Review [Network Management](./network) for allocation management \ No newline at end of file +- Review [Network Management](./network) for allocation management