diff --git a/server/src/index.js b/server/src/index.js index 0ef91a3a2..aed90211f 100644 --- a/server/src/index.js +++ b/server/src/index.js @@ -18,12 +18,15 @@ async function getUserId (authId) { } const userData = await axios({ - url: process.env.GRAPHQL_API_URL, + url: process.env.USERS_API_URL, method: 'post', + headers: { + preshared: USERS_API_PRESHARED + }, data: { query: ` { - users_UserByAuthId(authId: "${authId}") + userByAuthId(authId: "${authId}") { id } @@ -31,7 +34,7 @@ async function getUserId (authId) { ` } }) - return userData.data.data.users_UserByAuthId.id + return userData.data.data.userByAuthId.id } catch (error) { return (error) }