Closed danie1k closed 3 years ago
Second parameter of _post_request() is body, not a idempotency_key: https://github.com/fireblocks/fireblocks-sdk-py/blob/7a70d374f4e20f1ca347b432217fba41971eee77/fireblocks_sdk/sdk.py#L1105
_post_request()
body
idempotency_key
So the following code is invalid: https://github.com/fireblocks/fireblocks-sdk-py/blob/7a70d374f4e20f1ca347b432217fba41971eee77/fireblocks_sdk/sdk.py#L549
There should be either:
return self._post_request(f"/v1/vault/accounts/{vault_account_id}/{asset_id}", {}, idempotency_key)
or
return self._post_request(f"/v1/vault/accounts/{vault_account_id}/{asset_id}", idempotency_key=idempotency_key)
For the record, fixed in https://github.com/fireblocks/fireblocks-sdk-py/commit/c638e92eaca11b41701c985b9194f3d36468c45d & https://github.com/fireblocks/fireblocks-sdk-py/releases/tag/v1.6.7
Second parameter of
_post_request()
isbody
, not aidempotency_key
: https://github.com/fireblocks/fireblocks-sdk-py/blob/7a70d374f4e20f1ca347b432217fba41971eee77/fireblocks_sdk/sdk.py#L1105So the following code is invalid: https://github.com/fireblocks/fireblocks-sdk-py/blob/7a70d374f4e20f1ca347b432217fba41971eee77/fireblocks_sdk/sdk.py#L549
There should be either:
or