-
Notifications
You must be signed in to change notification settings - Fork 28
Open
Description
Hi, I've been unable to authenticate using websockets (to access account streams). Is there any example of this being done in python? I'm building the signature as below and I'm receiving the error message "authentication failed. authentications failed. invalid signature" Any advice?
nowInMilisecond = str(int(time.time() * 1000))
path = "/users/self/subscribe"
stringToSign = path + "\n" + nowInMilisecond
update_param__str = stringToSign
update_param_byteencoded = update_param_str.encode()
new_hmac = hmac.new(
secret_byteencoded,
msg=update_param__byteencoded,
digestmod=hashlib.sha512,
)
new_hmac_updated_hexdigested = new_hmac.hexdigest()
return nowInMilisecond, new_hmac_updated_hexdigested
Metadata
Metadata
Assignees
Labels
No labels