I’ll try to make it as clean as I can, so maybe it will be helpful for someone in future. If there is already thread that could help me, please link it because can’t find it.
-
I have registered new app at Asana profile and I get from there CLIENT ID & CLIENT SECRET
-
I have registered/allowed new app at AUTHORIZATION ENDPOINT, but I have no idea where I should put this key in my app (is it username or password?)
-
At my app based on ajax/jquery I use:
$.ajax({ type : "PUT", url : "https://app.asana.com/api/1.0/tasks/464883008651853", username: 'CLIENT ID', password: 'CLIENT SECRET', data: {"completed":true}, success : function(){ console.log("test"); } });
As an response I get 401 at dev console - authorization failed.
Could someone make it clear for me and maybe more people in future how to integrate && autehnticate APP corectly?