Getting error in api call unauthorize
hiii
iam new in constant contact i requested api call using react js for testing the contact constant but iam getting error of network error in browser console, when i run on postman it show unauthorize can any one help me to fix where i miss the steps
and did i passes the apikey and token correctly??
useEffect(() => {
const axios = require('axios');
let config = {
method: 'get',
headers: {
'ACCESS_TOKEN': 'Bearer {epf**********AHqAFw}',
'API_KEY': '09********1ce5c',
'Accept':'application/json',
}
};
axios(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
}, [])
one last one- is the secret key i got is the bearer token ??
1 reply