NativeRest

Product details

Q: Pre-request script feature as in Postman (to sign requests)?

Hello, so I bought Nativerest and I'm trying to use it to build an integration to a service (https://developers.3commas.io/quick-start/signing-a-request-using-hmac-sha256). However, for this I need to generate a custom HMAC signature for each request based on my secret key.

With Postman I have the pre-request feature that can do this. However, how can I do this in NativeRest?

I can of course do this in the Mac terminal, but it's just quite a pain to work like this whenever you make requests.

0e0b0dd3f6754365b27f521786b3910bPLUSJun 26, 2025
Founder Team
uhaleks

uhaleks

Jun 26, 2025

A: Hello! πŸ‘‹
Thank you for purchasing NativeRest. ✨
Currently, NativeRest only has a sha256 hashing function with one parameter. It won't work in this case. I looked at the API on your link and understand what is required. In a few days, I will add the hmac-sha256 function with two parameters to NativeRest. I'll reply to you here additionally as soon as it appears in NativeRest. πŸ™Œ

Share
Helpful?
Log in to join the conversation
Verified Purchaser badge

Verified purchaser

Posted: Jun 26, 2025

Awesome man! Thank you and much appreciated! Really looking forward to your update!

Verified Purchaser badge

Verified purchaser

Posted: Jun 29, 2025

Hi, I'm curious if there's any updates on this?

Founder
Posted: Jun 29, 2025

Hi! Yes, I have great news!
Right now the new version of NativeRest 2.6.2 is available. I just finished the necessary release notes and wanted to write to you.
Now you need to use the new hmac.sha256 function to fill in the Signature header.
This function has 2 parameters: Data, Key.
In the first - payload, and in the second - secret.
Signature: {{hmac.sha256({{payload}},{{secret}})}}

Founder
Posted: Jun 29, 2025

This is a continuation of my answer:
In my example, 2 parameters are declared payload and secret, in which the values ​​are written:
payload = /public/api/ver1/users/change_mode?mode=paper
secret = NhqPtmdSJYdKjVHj...
In my opinion, variables are more convenient, but it is not necessary to use them.

Founder
Posted: Jun 29, 2025

See an example of using hmac.sha256 in NativeRest in this screenshot:
https://nativesoft.com/static/images/using-hmac-sha256-function.png