TypeError:Cannot read properties of undefined (reading 'sigBytes') HMAC

Plz any idea to resole TypeError:Cannot read properties of undefined (reading ‘sigBytes’ with HMAC? any think is set correctly in Env.

Thank you

Hey @aboudra-dca3a8e7 :waving_hand:

Welcome to the Postman Community! :postman:

Could you please provide more context and details of the full script, please?

I’m testing an api (trial version, API-KEy and API-SECRET given by the provider )using official doc from the provider, i have imported the env.json file and collection.json file from official website of the provider. I follow the instructions in the official website. So i have this error TypeError: Cannot read properties of undefined (reading ‘sigBytes’) Using HMAC authentication

What’s the script?

There must be something in a pre-request script that is generating that and causing the error.

It’s likely the data going into an function argument that it’s resolved correctly and causing something to be undefined.

Without any visual examples, code or links to the documentation you’re using, it’s extremely difficult to know what’s happening on your side.

Hey @aboudra-dca3a8e7, this kind of sigBytes error often happens when some input data or environment variable is undefined. Maybe double-check that your API-KEY and API-SECRET are correctly set and match the variable names in the collection.
Are you using any custom pre-request scripts from the collection, or just the default ones from the provider?