Skip to content

Commit e878a28

Browse files
committed
outbout bittrex memos implemented
1 parent f3e4508 commit e878a28

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

rpc.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def get_dynamic_globals():
6969

7070

7171
# RPC POST WITHDRAWALS
72-
def post_withdrawal_bittrex(amount, nominator, api, keys):
72+
def post_withdrawal_bittrex(amount, nominator, api, keys, memo=""):
7373
"""
7474
send funds using the bittrex api
7575
bittrex sends the amount requested less the tx fee, so tx fee is added
@@ -95,6 +95,8 @@ def post_withdrawal_bittrex(amount, nominator, api, keys):
9595
"quantity": str(float(amount)),
9696
"cryptoAddress": str(nominator),
9797
}
98+
if memo:
99+
params.update({"cryptoAddressTag": str(memo)})
98100
# returns response.json() as dict or list python object
99101
ret = json_dumps(bittrex_api.post_withdrawal(**params))
100102
if isinstance(ret, dict):

stake_bitshares.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,12 @@ def serve_admin(params, keys):
455455
msg["api"] = api
456456
msg["memo"] = memo
457457
msg["response"] = json_loads(
458-
post_withdrawal_bittrex(transfer_amount, nominator, api, keys)
458+
post_withdrawal_bittrex(
459+
transfer_amount,
460+
nominator,
461+
api,
462+
keys,
463+
memo="loan_to_bmg")
459464
)
460465
msg[
461466
"status"

0 commit comments

Comments
 (0)