removed gov gateway references

This commit is contained in:
2022-10-18 11:51:30 +01:00
parent 5f7908c0c2
commit 8c5b299412
17 changed files with 87 additions and 191 deletions
-31
View File
@@ -31,37 +31,6 @@ export const getProviderConfig = () => {
});
};
export const getGGToken = (tokenURL, authCode, redirectUri) => {
const tokenBody =
"grant_type=authorization_code" +
"&code=" +
authCode +
"&redirect_uri=" +
redirectUri;
const basicAuthBase64 = (ggClientID + ":" + ggClientSecret).toString();
//console.log("base64 " + Base64.encode(basicAuthBase64));
const tokenConfig = {
headers: {
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Basic " + Base64.encode(basicAuthBase64),
},
};
return axios
.post(tokenURL, tokenBody, tokenConfig)
.then((res) => res.data)
.catch((error) => {
// if (error.response) {
// console.log(error.response.data);
// console.log(error.response.status);
// console.log(error.response.headers);
// }
return error.response;
});
};
export const getUserInfo = (userInfoURL, authToken) => {
const tokenConfig = {
headers: {