Predefined Credential Type – Unfortunately, this didn’t work.
Research & Forum Posts – I read through many forum discussions on this topic (I’m fairly new and low-code) but still couldn’t get it to work.
The common recommendation was to use Generic Credential Type with OAuth2 API. I managed to set it up, but as soon as I save and connect, my Client Secret changes to: __n8n_BLANK_VALUE_e5362baf-c77…
Then, the node output gives me this error:
“response”: “There was an error: ‘Credentials not found’”
My Setup
Running on n8n Cloud
Has anyone successfully set this up? I’m completely stuck at this point. Any help would be greatly appreciated!
You might need to sort out whether you have the permissions set up for Application access or Delegated (single user) access? Sounds like maybe you want delegated (connecting as a specific user), but some of the permissions listed in your screenshot are “Application” permissions. Not sure how a mixture of permission types would work.
Hey, thanks, but unfortunately that didn’t work for me.
I switched to application-only authentication and implemented the client credentials, yet I still encounter the same error as before. Please see my changes below.
Just curious if the __n8n_BLANK_VALUE thing might be a red herring. There is code that uses that value to (I think) avoid sending the actual value back to the UI, and it should, perhaps, be masked anyway. Is the actual literal value you have masked out: __n8n_BLANK_VALUE_e5362baf-c777-4d57-a609-6eaf1f9e87f6 (which is the full constant “fake” value in the n8n source).
What version of n8n are you on? I’m not having this issue on 1.73.1 (for comparison). Just trying to narrow things down.
No, I already set it as fixed before. But as soon as I save and run it, I check the credentials and notice that the Client Secret length has changed. I then change it to ‘Expression’ because you can only see the text in that mode; otherwise, it’s not visible. I’m running [email protected] in the cloud. Either way if fixed or on expression the error doesnt change.
I started up a self hosted instance on version 1.81.4 to see if it misbehaves with the same exact setup that is working for me in 1.73.1. I didn’t see any difference, so maybe there’s a difference in the steps that led to the issue you’re having (aside from the self-host vs. cloud difference).
Sometimes n8n gets confused when you start with a particular configuration of a node or credential and then modify things, so, one more thing to try: Set up the credentials item from scratch.
Create a New credential item
Filter the types with “Oauth2 API”
Scroll all the way through the special ones to the one that is just called “OAuth2 API” (wish this would sort an exact match to the top, but… I digress)
Immediately change the Grant Type to Client Credential
Fill in other fields, and save.
Switch the HTTP Request (msgraph call) to the new credential item. (Generic Credential Type → Generic Auth Type = OAuth2 API → Select the one you just made.
FWIW, n8n is not echoing the actual secret back to the UI anyway, so even if you have it set to expression, you don’t gain anything from that. The UI should really restrict that field to fixed, but the n8n devs have many higher priority things to do.