ионное приложение не может подключиться к API через HTTP-запрос - PullRequest
0 голосов
/ 01 июля 2019

ионное приложение не может подключиться к API через HTTP-запрос.

var headers = new HttpHeaders({'x-watchover-key': this.apiKey}); this.http.get('http://xxxxxxxxxxxxxx/api/users/44/unclaimed', {headers: headers}).subscribe(data => {this.unclaimed=data;console.log(data);}, error => {console.log(error);});

Ошибка приведена ниже

"headers":{:{},"lazyUpdate":null,"headers":{}},"status":0,"statusText":"Unknown Error","url":"http://api/users/authenticate","ok":false,"name":"HttpErrorResponse","message":"Http failure response for http://api.watchover247.com/api/users/authenticate: 0 Unknown Error","error":{"isTrusted":true}
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...