json - unexpected token : from angular $http.jsonp request to Instagram API -
i'm making request authorized instagram account display images on site. originally, running no 'access-control-allow-origin' when using angular's $http.get(... . from matt's answer in question , seems can use getjson , or angular $http.jsonp , bypass issue. that guy's answer says "jsonp trick overcome xmlhttprequest same domain policy". so, i'm no longer getting problem, , getting json payload: {"pagination":{"next_url":"https:\/\/api.instagram.com... etc but getting ambiguous error: uncaught syntaxerror: unexpected token : this response instagram api, i'm not sure why there'd syntax error on inbound json. also, it's hard locate error since jsonp response on single line... error reported. the preview shows i'm getting full payload: i found issue. unfortunately there no javascript libraries this, in instagram api docs , jsonp can wrap response callback json payload wrappe