Eve swagger return html code 200 on bad request


(shawn313) #1

the api call is using a old token and it return 200 code im using the code to see if i need a new token anyone else seeing this

here is the code if that helps

export const callingApiPre = () => (dispatch, getState) => {
fetch(‘https://esi.tech.ccp.is/v1/characters/’ + getState().ViewChr.Cid + ‘/medals/?datasource=tranquility&token=’ + getState().ViewChr.At)
.then(function (response) {
if (!response.ok) {
return fetch(‘http://localhost:8000/rf?rf=’ + getState().ViewChr.Rt + ‘&id=’ + getState().ViewChr.Id)
.then(response => response.json())
.then((json) => {
dispatch(updateAt(json));
dispatch(updatePf(‘pass’));
dispatch(callingEveSkill());
console.log(“Bad Api Fixed”);
})
.catch(err => {
console.log(“Theie is a issue with the api calls to both the eve and api sever” + err)
});
}
})
};


(shawn313) #2

and now its working