Need some help connecting to OVH Api

Hi everyone,
I'm new on Retool (which looks really promising for our needs!).
I could create an API resource for my CRM and my ticket system quite easily but i'm facing a problem creating an API REST resource for OVH. I've been able to connect to the OVH API through Postman but i have no idea how to proceed with Retool as API requests on OVH have to be signed (with this formula: "$1$" + SHA1_HEX(AS+"+"+CK+"+"+METHOD+"+"+QUERY+"+"+BODY+"+"+TSTAMP) OVH help ).
I'm guessing that i'll probably need to use the Custom Authentication but i'm a bit lost to be honest...
Let me know if you need some screenshots of the Postman setting that made the API call successfull.
Thank's for reading and have a nice day
PS: forgive my english...

Hey @Julien_PASQUIERS!

Unfortunately, Retool doesn't support JavaScript in the resource setup page at the moment, though it is a known feature request and I can follow up with you here if it is supported!

That means that, if you want to sign your requests, you'd need your Application Secret and Client Key available as variables in your app, in which case you could sign the request from the app itself with something the following in a JavaScript query:

const url = "https://ca.api.ovh.com/1.0/auth/details";
const body = "";
const httpMethod = "GET";
const timestamp = Math.round(Date.now() / 1000);
const crypto = CryptoJS;

const signRequest = () => {
  let s = [
    APPLICATION_SECRET,
    CONSUMER_KEY,
    httpMethod,
    url,
    body || "",
    timestamp,
  ];
  
  return "$1$" + crypto.SHA1(s.join("+")).toString();
};

ovh.trigger({additionalScope: {url, body, timestamp, signature: signRequest()}});

I've attached an app you can use to play around with things!
ovh-20test.json

Hey @Kabirdas !
Thank's a lot for the reply! I'm going to try and play around with the app you attached!
I'll keep you in touch :wink:
Have a great day.

Sounds. good! For reference - the CryptoJS library can be imported from here using preloaded JavaScript!

Thanks for the tip, i've already done this steps during my previous tests :wink:
Didn't tried yet your solution but be sure that i'll keep you in touch.
Thanks again for everything