When I deploy my project on the test site it is impossible to retrieve data from the API. Locally the problem does not arise.
api.siren.service.ts:29 Erreur API détectée:
HttpErrorResponse {headers: _HttpHeaders, status: 200, statusText: 'OK', url: '::8000/xxxx/', ok: false, …}
(anonymous) @ api.siren.service.ts:29
Zone - XMLHttpRequest.addEventListener:load
searchSiret @ headerponent.ts:1122
HeaderComponent_div_55_div_17_Template_button_click_2_listener @ headerponent.html:548
Zone - HTMLButtonElement.addEventListener:click
HeaderComponent_div_55_div_17_Template @ headerponent.html:548
HeaderComponent_div_55_Template @ headerponent.html:543
Zone - Promise.then
(anonymous) @ main.ts:5
headerponent.ts:1132 Erreur API SIREN: Error: Erreur API (HTTP 200): Http failure during parsing for :8000/xxx/
at api.siren.service.ts:39:37
at _Observable.init [as _subscribe] (throwError.js:5:51)
at _Observable._trySubscribe (Observable.js:37:25)
at Observable.js:31:30
at errorContext (errorContext.js:19:9)
at _Observable.subscribe (Observable.js:22:9)
at catchError.js:14:31
at OperatorSubscriber._error (OperatorSubscriber.js:23:21)
at OperatorSubscriber.error (Subscriber.js:40:18)
at OperatorSubscriber._error (Subscriber.js:64:30)
{
"/api-sirene/": {
"target": ";,
"secure": true,
"changeOrigin": true,
"logLevel": "debug",
"pathRewrite": {
"^/api-sirene": "/api-sirene/3.11/siren"
}
}
}
I thought I needed the SSL certificate, but even with that nothing changed. I think the problem may be with the proxy configuration. I thank you in advance for your help.