Hi There I try to connect to Clockify with the HTTP Node. We need to fetch the endpoint TimeRecord per User. So I firstly fetch with the Clockify Node User and Workspace ID
After executing I receive the error:
ERROR: Authorization failed - please check your credentials
{“status”:“rejected”,“reason”:{“message”:“401 - "{\"message\":\"Api key does not exist\",\"code\":4003}"”,“name”:“Error”,“stack”:“Error: 401 - "{\"message\":\"Api key does not exist\",\"code\":4003}"\n at createError (/app/code/node_modules/axios/lib/core/createError.js:16:15)\n at settle (/app/code/node_modules/axios/lib/core/settle.js:17:12)\n at RedirectableRequest.handleResponse (/app/code/node_modules/axios/lib/adapters/http.js:238:9)\n at RedirectableRequest.emit (node:events:525:35)\n at RedirectableRequest.emit (node:domain:489:12)\n at RedirectableRequest._processResponse (/app/code/node_modules/follow-redirects/index.js:356:10)\n at ClientRequest.RedirectableRequest._onNativeResponse (/app/code/node_modules/follow-redirects/index.js:62:10)\n at Object.onceWrapper (node:events:628:26)\n at ClientRequest.emit (node:events:513:28)\n at ClientRequest.emit (node:domain:489:12)”}}
It tells me api key does not exist. But I have checked it 100 Times. It is the api Token generated in my clockify profile.
I also tried to use the predefined credentials from clockify for auth. I got the same error.
But when I try to use the same authorization with a clockify node it works without problems
I believe this isn’t a problem with n8n but with Clockify itself. Even when trying to send your example request using curl (without any n8n involvement) the request would fail, despite using a valid key:
However, after switching out the developer.clockify.me hostname in my URL and sending my request to https://api.clockify.me/api/v1/workspaces/64bf91a096d09222092cb53c/user/64bf91a096d09222092cb538/time-entries instead, this request works as expected:
Hi @MutedJam, Thank you very much!
Well especially I tried this too. It is interesting that it works on your site? Do you have the cloud Version of N8N?
In my case I use the on prem Version and I receive the following “White Label” Error:
I am also not seeing this on my test cloud instance or my self hosted instance, The error you are getting back though isn’t an n8n error it is coming back from whatever it is you are talking to which should be Clockify but it could be something else.
Under the options can you set it to Include the response headers and status and never error it will be interesting to see what Headers are coming back.