Search code examples
apioauthtokentrello

Trello API: Getting invalid token on all calls


I have a weird situation, which I hope you can help with.

I am trying to setup a simple Trello application. What I do are the following:

  1. I go to https://trello.com/app-key and get my KEY
  2. I go to https://trello.com/1/authorize?expiration=never&name=SinglePurposeToken&key=MYKEY for a permanent server to server key
  3. I authorize
  4. I get a token

Now I'm ready, but then when I want to make a call such as:

https://api.trello.com/1/boards/BOARDID/actions/?limit=2&key=MYKEY&token=MYTOKEN

I get "invalid token".

Reason I post here on StackOverflow, and not Trello support, is because I assume there is something basic I am doing wrong!


Solution

  • I was wrong about step 2).

    I should use this link instead:

    https://trello.com/1/authorize?expiration=never&scope=read,write&response_type=token&name=APPNAME&key=KEY

    This gave the working token. All is well!