In Postman,this get request works perfectly fine,and returns expected result,but when requesting in Angular,it keeps throwing this error.
const headerDict = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'Access-Control-Allow-Headers': '*',
'Control-Allow-Origin':'*',
"Authorization":"my-auth"
}
const requestOptions = {
headers: new HttpHeaders(headerDict),
};
this.http.get('https://geo.konkurs2022.digitalcube.dev/api/countries/?fields=id,capital_id,name,capital_name&format=csv&no_paginate=true&order_by=-capital_name',requestOptions)