diff --git a/src/components/api/scribearServer/scribearRecognizer.tsx b/src/components/api/scribearServer/scribearRecognizer.tsx index 0ae4508..5fb3503 100644 --- a/src/components/api/scribearServer/scribearRecognizer.tsx +++ b/src/components/api/scribearServer/scribearRecognizer.tsx @@ -76,7 +76,7 @@ export class ScribearRecognizer implements Recognizer { if (this.socket) { return; } const scribearURL = new URL(this.scribearServerStatus.scribearServerAddress) - if (scribearURL.pathname !== '/sink') { + if (scribearURL.pathname !== '/api/sink') { this._startRecording(); } diff --git a/src/components/navbars/topbar/apiDropdown.tsx b/src/components/navbars/topbar/apiDropdown.tsx index b5d1e60..7f0ef5a 100644 --- a/src/components/navbars/topbar/apiDropdown.tsx +++ b/src/components/navbars/topbar/apiDropdown.tsx @@ -63,10 +63,10 @@ export default function ApiDropdown(props) { } if (mode === 'kiosk') { - switchToScribeARServer(`ws://${kioskServerAddress}/sourcesink`, undefined); + switchToScribeARServer(`ws://${kioskServerAddress}/api/sourcesink`, undefined); } else if (mode === 'student') { console.log("Sending startSession POST with accessToken:", accessToken); - fetch(`http://${serverAddress}/startSession`, { + fetch(`http://${serverAddress}/api/startSession`, { method: 'POST', headers: { 'Content-Type': 'application/json' @@ -77,7 +77,7 @@ export default function ApiDropdown(props) { .then(data => { console.log('Session token:', data.sessionToken); - const scribearServerAddress = `ws://${serverAddress}/sink`; + const scribearServerAddress = `ws://${serverAddress}/api/sink`; switchToScribeARServer(scribearServerAddress, data.sessionToken); }) diff --git a/src/components/navbars/topbar/qrCodeScreen.tsx b/src/components/navbars/topbar/qrCodeScreen.tsx index 040c07f..6fc30e5 100644 --- a/src/components/navbars/topbar/qrCodeScreen.tsx +++ b/src/components/navbars/topbar/qrCodeScreen.tsx @@ -29,7 +29,7 @@ export default function QRCodeComponent() { let updateAccessTokenTimeout; function updateAccessToken() { - fetch(`http://${kioskServerAddress}/accessToken`, { + fetch(`http://${kioskServerAddress}/api/accessToken`, { method: 'POST', headers: { 'Content-Type': 'application/json' diff --git a/src/react-redux&middleware/redux/reducers/apiReducers.tsx b/src/react-redux&middleware/redux/reducers/apiReducers.tsx index 23abe2b..959b937 100644 --- a/src/react-redux&middleware/redux/reducers/apiReducers.tsx +++ b/src/react-redux&middleware/redux/reducers/apiReducers.tsx @@ -47,7 +47,7 @@ const initialPlaybackStatus: PlaybackStatus = { } const initialScribearServerState: ScribearServerStatus = { - scribearServerAddress: 'ws://localhost:8080/sourcesink', + scribearServerAddress: 'ws://localhost:8080/api/sourcesink', scribearServerKey: '', scribearServerSessionToken: undefined, }