Skip to content

Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia

fix: use hoppscotch's realtime echo servers - resolved #1913

liyasthomas8f04f0758bab
diff --git a/packages/hoppscotch-app/components/realtime/Socketio.vue b/packages/hoppscotch-app/components/realtime/Socketio.vue
index 490216aaf..bd367a4ce 100644
--- a/packages/hoppscotch-app/components/realtime/Socketio.vue
+++ b/packages/hoppscotch-app/components/realtime/Socketio.vue
@@ -242,7 +242,7 @@ export default defineComponent({
return {
// default version is set to v4
clientVersion: "v4",
- url: "wss://main-daxrc78qyb411dls-gtw.qovery.io",
+ url: "wss://hoppscotch-socketio.herokuapp.com",
path: "/socket.io",
isUrlValid: true,
connectingState: false,
diff --git a/packages/hoppscotch-app/components/realtime/Websocket.vue b/packages/hoppscotch-app/components/realtime/Websocket.vue
index 8ae56f1b6..81bd55358 100644
--- a/packages/hoppscotch-app/components/realtime/Websocket.vue
+++ b/packages/hoppscotch-app/components/realtime/Websocket.vue
@@ -228,7 +228,7 @@ export default defineComponent({
return {
connectionState: false,
connectingState: false,
- url: "wss://echo.websocket.org",
+ url: "wss://hoppscotch-websocket.herokuapp.com",
isUrlValid: true,
socket: null,
communication: {
diff --git a/packages/hoppscotch-app/helpers/utils/__tests__/valid.spec.js b/packages/hoppscotch-app/helpers/utils/__tests__/valid.spec.js
index 2a447d7f4..413cb915d 100644
--- a/packages/hoppscotch-app/helpers/utils/__tests__/valid.spec.js
+++ b/packages/hoppscotch-app/helpers/utils/__tests__/valid.spec.js
@@ -7,8 +7,8 @@ describe("wsValid", () => {
})
test("returns true for valid URL with Hostname", () => {
- expect(wsValid("wss://echo.websocket.org/")).toBe(true)
- expect(wsValid("wss://echo.websocket.org")).toBe(true)
+ expect(wsValid("wss://hoppscotch-websocket.herokuapp.com/")).toBe(true)
+ expect(wsValid("wss://hoppscotch-websocket.herokuapp.com")).toBe(true)
})
test("returns false for invalid URL with IP address", () => {
@@ -29,8 +29,8 @@ describe("wsValid", () => {
})
test("returns true for wss protocol URLs", () => {
- expect(wsValid("wss://echo.websocket.org/")).toBe(true)
- expect(wsValid("wss://echo.websocket.org")).toBe(true)
+ expect(wsValid("wss://hoppscotch-websocket.herokuapp.com/")).toBe(true)
+ expect(wsValid("wss://hoppscotch-websocket.herokuapp.com")).toBe(true)
expect(wsValid("wss://174.129.224.73/")).toBe(true)
expect(wsValid("wss://174.129.224.73")).toBe(true)
})
@@ -65,8 +65,8 @@ describe("httpValid", () => {
})
test("returns false for non-http(s) protocol URLs", () => {
- expect(httpValid("wss://echo.websocket.org/")).toBe(false)
- expect(httpValid("wss://echo.websocket.org")).toBe(false)
+ expect(httpValid("wss://hoppscotch-websocket.herokuapp.com/")).toBe(false)
+ expect(httpValid("wss://hoppscotch-websocket.herokuapp.com")).toBe(false)
expect(httpValid("wss://174.129.224.73/")).toBe(false)
expect(httpValid("wss://174.129.224.73")).toBe(false)
})
@@ -129,8 +129,10 @@ describe("socketioValid", () => {
})
test("returns true for wss protocol URLs", () => {
- expect(socketioValid("wss://echo.websocket.org/")).toBe(true)
- expect(socketioValid("wss://echo.websocket.org")).toBe(true)
+ expect(socketioValid("wss://hoppscotch-websocket.herokuapp.com/")).toBe(
+ true
+ )
+ expect(socketioValid("wss://hoppscotch-websocket.herokuapp.com")).toBe(true)
expect(socketioValid("wss://174.129.224.73/")).toBe(true)
expect(socketioValid("wss://174.129.224.73")).toBe(true)
})