Withdraw endpoint to off-ramp tokens to fiat

I’m trying to call the /withdraw endpoint and can’t seem to get it to work.

I’ve tried following the SIEWC docs but I’m hitting either an Authentication error or an invalid API key error. I’m using the trade API key (all perms enabled) and have tried calling via passing a bearer token and also via the legacy signature method as well.

Are there any code samples (typescript ideally) to follow?