Airtable Oauth2 credential setup failing (due to PKCE error with "code_verifier")

Given that Airtable is deprecating their API keys, I was trying to set up new Airtable OAuth2 credentials. When I tried to connect, the credential callback reported this error:

  "error": "invalid_request",
  "error_description": "The \"code_verifier\" must only contain characters that are in: [A-Z] / [a-z] / [0-9] / \"-\" / \".\" / \"_\""

I see that PKCE support was added earlier this summer (feat(core): Add PKCE for OAuth2 by agobrech · Pull Request #6324 · n8n-io/n8n · GitHub), and suspect that this error highlights a refinement that may be necessary for the Airtable Auth2 credentials to be created.

  • n8n version: 1.4.1

Hi @ari, I am very sorry you’re having trouble.

I was able to reproduce this, however, this error came up only occasionally, ~2 out of 3 attempts were successful. So I suspect this is simply a case of Airtable rejecting a character (usually supported by other services implementing OAuth2) in the code_verifier field. Retrying the connection would generate a new code_verifier.

Can you give this another go on your end and let me know if the problem disappears for you as well when retrying?

Interesting. I tried a few more times, and on the fourth time it worked.

I believe the root cause of this issue is [email protected], which removed the ~ character to address a Twitter-specific issue. Relevant discussion about this in PR #6324.

1 Like

Hey @ari,

We also found the same thing and will look at getting it resolved soon.

I am now having the same issue.
I just tried to run a workflow and realised that the Airtable auth was not working. I generated new Oauth, I can connect in the credentials screen but the nodes tell me to check my credential