angularjs - $HTTP.DELETE not working local -
i want delete record (package track) api aftership
this code:
$scope.deltrack = function($slug, $code){ $http({ method: 'delete', url: 'https://api.aftership.com/v4/trackings/' + $slug + '/' + $code, headers: { 'access-control-allow-methods' : 'get, post, options, put, delete', 'aftership-api-key': 'apikey', 'content-type' : 'application/json' } }) .then(function (response) { }); }
this not work in webpage, when copy url network inspector , insert in www.hurl.it delete action works. i'm missing headers or configuration of angular, don't know what...
delete url: https://api.aftership.com/v4/trackings/bpost/rs775607677cn
api docs: https://www.aftership.com/docs/api/4/trackings/delete-trackings
my , post commands work api, delete not.
Comments
Post a Comment