Does anyone know how to make calls with a certificat?

Does anyone know how to make calls with a certificate?

tags changed: → http-request

Does anyone know how to make a call with a digital certificate on Postiman? You have the option of putting the certificate and the calls work. I went to make it on the N8n and got this error ERROR: Bad request - please check your parameters
400 - “\r\n400 No required SSL certificate was sent\r\n\r\n400 Bad Request\r\nNo required SSL certificate was sent\r\nserver\r\n\r\n\r\n”

Hey @tray_corp,

We don’t have support for sending a certificate for authentication with the http request node, the only workaround I can think of would involve using a code node and making the http request from there using your library of choice.

Can you give me an example of how to do it via code with any library, the curl that support gave me as an example was this curl --location ‘ grant_type=client_credentials’ \ –header ‘Content-Type: application/x-www-form-urlencoded’ \ –header ‘Authorization: Basic ZkFpZ3RvNUhvOHB0R2N3YVhOUVdEU1ZqYkwxRERwN0c6UHVpUVVKcGgxVUFKakxJcQ==’ \ –cert /path/to/your/certificate.pem \ –data-urlencode ‘client_id=fAigto5Ho8ptGcwaXNQWDSVjbL1DDp7G’ \ –data-urlencode ‘client_secret=PuiQUJph1UAJjLIq’

Make sure to replace /path/to/your/certificate.pem with the actual path of your PEM certificate file.

If you require certificate and password authentication, you can add the --cert-type option followed by the certificate type (e.g. P12) and the --cert-password option followed by the certificate password.

Hey @tray_corp,

Have you configured yout n8n instance to be allowed to use Axios by setting the NODE_FUNCTION_ALLOW_BUILTIN env option?

no! I don’t know how to do this, I use Vultr and Cloudrom

How do you normally set environment options in Cloudron? I am not a Cloudron user so I have no idea how that part of it works but I suspect you may have had to set the environment options for WEBHOOK_URL so it would be in the same place.

I don’t know how it works so I installed n8n

How did you install n8n? There is no need to install axios as well as we use it internally so it is just a case of setting the Environment Variable and you should be good to go.

on this site I bought a virtual machine and already installed clodron and the n8n application on cloudron I just did some domain configurations so this is an easier way to install n8n

seria isso aqui

would it be this

Hey @tray_corp,

It could be but it all depends on how you have installed n8n, If you have installed n8n using Cloudron there is possibly an option in Cloudron to set this. The file you have found may do the trick but you would need to restart n8n I am also not sure if that file is read by Cloudron.

Please don’t forget that self hosting n8n is an advanced feature and we kind of expect you to know how you have set up n8n and how your chosen installation method works as there are so many platforms out there we can’t possibly know all of them.

RROR: Code doesn’t return items properly

Please return an array of objects, one for each item you would like to output.

ERROR: Code doesn’t return items properly

Please return an array of objects, one for each item you would like to output.

Hey @tray_corp,

That error is saying that you need to amke sure you are returning data in the format we expect in your code. You can find some information on this here: Code | n8n Docs

I adjusted it and I am now receiving this error
“error:0480006C:PEM routines::no start line”

Hey @tray_corp,

I suspect that is coming from back Axios, I have seen similar in the past and it tends to mean that your certificate files are not in the correct format and don’t contain the starting line which is normally something like --begin certificate---