n8n-community-node / n8n-nodes-mastodon

MIT License
18 stars 3 forks source link

Cannot login on my GoToSocial instance #10

Open raspbeguy opened 1 year ago

raspbeguy commented 1 year ago

Hello, I'm having trouble to login on my GoToSocial instance from my n8n instance. I did the following POST request to my GtS instance to register the client:

curl -X POST -F 'client_name=n8n' -F 'redirect_uris=https://automation.gugod.fr/rest/oauth2-credential/callback' -F 'scopes=write' -F 'website=https://aut
omation.gugod.fr' https://social.gugod.fr/api/v1/apps

The redirect URI was given by my n8n instance. Here is the answer:

{
  "id": "01EQ5JNSDDM9AR6KGE4PXDETNZ",
  "name": "n8n",
  "website": "https://automation.gugod.fr",
  "redirect_uri": "https://automation.gugod.fr/rest/oauth2-credential/callback",
  "client_id": "01CJYYF9HNSEBCP7RWW1QAQ2G6",
  "client_secret": "xxxxxxx"
}

client_secret has been hidden of course.

I fill my credentials in n8n here:

image

When I click on "Connect my account" I get to the login page of GtS, then it forwards to the callback URL to n8n, and I get this:

image2

Am I missing something?

eXpl0it3r commented 11 months ago

Probably a mismatch in scopes see #13