From aff9d36104f1ce7c31fef3759860bced5659c7f7 Mon Sep 17 00:00:00 2001 From: MaxPovver Date: Fri, 14 May 2021 20:44:54 +0300 Subject: [PATCH 1/2] fix headers --- cfRestApiV3.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cfRestApiV3.py b/cfRestApiV3.py index 6c71fc7..ff0437d 100644 --- a/cfRestApiV3.py +++ b/cfRestApiV3.py @@ -276,9 +276,9 @@ def make_request_raw(self, requestType, endpoint, postUrl="", postBody=""): if self.useNonce: nonce = self.get_nonce() signature = self.sign_message(endpoint, postData, nonce=nonce) - authentHeaders = {"APIKey": self.apiPublicKey, - "Nonce": nonce, "Authent": signature} - else: + authentHeaders = {"apiKey": self.apiPublicKey, + "nonce": nonce, "authent": signature} + else signature = self.sign_message(endpoint, postData) authentHeaders = { "APIKey": self.apiPublicKey, "Authent": signature} From d0c4d1e9a37d86cfd33094954e92a8b8783e57fd Mon Sep 17 00:00:00 2001 From: MaxPovver Date: Fri, 14 May 2021 20:45:34 +0300 Subject: [PATCH 2/2] update api url --- cfRestApiV3Examples.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cfRestApiV3Examples.py b/cfRestApiV3Examples.py index 541ef21..24f6936 100644 --- a/cfRestApiV3Examples.py +++ b/cfRestApiV3Examples.py @@ -28,7 +28,7 @@ apiPrivateKey = "..." # use "api.cryptofacilities.com" if your IP is whitelisted (Settings -> API Keys -> IP Whitelist) -apiPath = "https://www.cryptofacilities.com" +apiPath = "https://futures.kraken.com" timeout = 20 checkCertificate = True # when using the test environment, this must be set to "False" useNonce = False # nonce is optional