2016-08-01 11 views
1

Paypal Rest Api funktioniert nicht für Tizen TV, während es auf Rest-Client gut funktioniert. Weder Erfolg noch Fehlfunktion wird in Tizen TV genannt.Paypal Api funktioniert nicht für Tizen TV

Die URL anders als paypal geändert funktioniert gut. Auch mit Ajax wurden keine Änderungen gefunden.

hier ist der Beispielcode dafür.

Get:

var request = $http({ 
    method : "get", 
    url : "https://api.sandbox.paypal.com/v1/payments/payment", 
    headers : { 
     "Content-Type" : "application/json", 
     "Authorization": "Bearer A101.FfLKjOmGx-80JU9h9ACDqrm0-dSg5pvlUsMnz2Slsb9hbSZSNQXQ7c653uc0XEYS.dd1D0romSBOfYq_Q7dIh6KEQg0O" 
    } 
}); 
request.then(function(response){ 
console.log(response); 

},function(error){ 
console.log(error); 

}); 

Beitrag:

var request = $http({ 
    method : "POST", 
    url : 'http://api.sandbox.paypal.com/v1/oauth2/token', 
    data : 'grant_type=client_credentials', 
    headers : { 
      'Content-Type': 'application/x-www-form-urlencoded', 
      'Accept': 'application/x-www-form-urlencoded', 
      'Accept-Language': 'en_US', 
      "Authorization": "Basic QWVRWnpOanM5UGdrQVdyb1VkbjktZ1lhcmNzNUxST2hSN2QyN1VTLTAyb0lXNy1pcmhyMUFkWXhLdkpoY1Q5Y0JoUXlxeHJDZW5MV2JXQjI6RUR4Q3pwbmRkRHBHSVI4SFo2TUR6dzkxYjR6enZndXgwc1hDSFhfU0c5c0pmOHFDNmg4NWd3S3ctTktIbW1ObXNtMFZpT0FQOU84WHREZFc=" 
    } 
}); 
request.then(function(response){ 
    console.log(response); 

    },function(error){ 
console.log(error); 
}); 

Antwort