Adapting team verification calls to go through gateway

This commit is contained in:
Nikola Bjelo committed 2018-11-02 22:54:49 +01:00
1 parent b85dcb474f
commit 895eb3c475
3 files changed
+5 -7

No files matched your search

+1 -1
View File
@@ -7,4 +7,4 @@ DB_DOMAIN=example.com:1234/example_name
SENTRY_DNS=https://some-val@sentry.io/some-id
TEAMS_ENDPOINT=https://teams-api.advancedalgos.net/graphql/
GATEWAY_ENDPOINT=https://app-api.advancedalgos.net/graphql/
@@ -28,19 +28,18 @@ const resolve = (parent, {
}
return new Promise((res, rej) => {
axios({
url: process.env.TEAMS_ENDPOINT,
url: process.env.GATEWAY_ENDPOINT,
method: 'post',
data: {
query: `
{
teamsByRole{
teams_TeamsByRole{
id
}
}
`,
},
headers: {
userid,
authorization: context.authorization,
},
}).then(
@@ -29,19 +29,18 @@ const resolve = (parent, {
}
return new Promise((res, rej) => {
axios({
url: process.env.TEAMS_ENDPOINT,
url: process.env.GATEWAY_ENDPOINT,
method: 'post',
data: {
query: `
{
teamsByRole{
teams_TeamsByRole{
id
}
}
`,
},
headers: {
userid,
authorization: context.authorization,
},
}).then(