Implement releasing funds

pull/1/head
Mark Veidemanis 3 years ago
parent d1252a1d42
commit bdd7921bc0
Signed by: m
GPG Key ID: 5ACFCEED46C0904F

@ -283,4 +283,16 @@ class Agora(object):
rtrn = self.create_ad(countrycode, currency) rtrn = self.create_ad(countrycode, currency)
if not rtrn: if not rtrn:
return False return False
return True yield rtrn
def release_funds(self, contact_id):
"""
Release funds for a contact_id.
:param contact_id: trade/contact ID
:type contact_id: string
:return: response dict
:rtype: dict
"""
payload = {"tradeId": contact_id, "password": settings.Agora.Pass}
rtrn = self.agora._api_call(api_method=f"contact_release/{contact_id}", http_method="POST", query_values=payload)
return rtrn

Loading…
Cancel
Save