Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work with new Asana API "Personal Access Token" #1

Open
mannieschumpert opened this issue Dec 18, 2016 · 7 comments
Open

Doesn't work with new Asana API "Personal Access Token" #1

mannieschumpert opened this issue Dec 18, 2016 · 7 comments
Labels

Comments

@mannieschumpert
Copy link
Owner

No description provided.

@therealscottcarlow
Copy link

It does work with the new Personal Access token. Using Alfred 3, after changing the calls to Alfred 2 directories in workflow.php to the Alfred 3 directories, a personal access token functions fine with this workflow.

@dan300
Copy link

dan300 commented Mar 15, 2017

I can confirm what @therealscottcarlow suggested, I just set it up with the personal access token and it works fine.

Check the resolution of this issue to change the calls from Alfred 2 to Alfred 3.

@therealscottcarlow
Copy link

therealscottcarlow commented Mar 15, 2017

@mannieschumpert Was there a particular issue you were having that you hadn't the time to troubleshoot? I'd be happy to see if I can reproduce it. All's green over here, though.

There are some changes you should probably make, though, because Asana's going to stop supporting basic auth at some point. The new way Asana wants you to pass the token in the Authorization header. e.x.:

curl -H "Authorization: Bearer <Personal_Access_Token>" https://app.asana.com/api/1.0/users/me.

I'll submit a PR when I have the chance. I won't submit a PR for the Alfred 2 directory references, though, because that will break compatibility with Alfred 2. I'll let you figure out how you want to handle organizing that in your Github first.

@dan300 Glad that worked for you. Thanks for confirming.

@alper
Copy link

alper commented Jun 4, 2017

Mine just stopped working so I quickly fixed it by changing all occurrences in asana.php to:

exec('curl -H "Authorization: Bearer' . $apikey . '" https://app.asana.com/api/1.0/users/me', $return);

And filling in the personal access token into akey.

It is late and I really needed to get this to work again quickly. If there's interest I can submit a cleaned up change.

@rogiervw
Copy link

rogiervw commented Jun 7, 2017

@alper Would be really grateful if you could fix and update the core files. Use it all the time!

@ialexryan
Copy link

Just stopped working for me, but I generated a Personal Access Token and filled it into akey and everything is working again. No code changes necessary. Evidently the PAT's work as a drop-in replacement for the API Key!

@rogiervw
Copy link

Thanks @ialexryan - works perfect!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants