Skip to content

Commit e3bb793

Browse files
authored
Merge pull request #24 from Safeheron/dev
Updates Related to the Gas Service Feature
2 parents 3247d81 + 55256fb commit e3bb793

File tree

2 files changed

+27
-2
lines changed

2 files changed

+27
-2
lines changed

safeheron_api_sdk_python/api/account_api.py

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,15 @@ def __init__(self):
1212
# False: retrieve displayed wallet accounts
1313
# Default: retrieve all wallet accounts
1414
self.hiddenOnUI = None
15+
# Filter wallets based on autoFuel setting:
16+
# Default: Ignore this query parameter
17+
# true: Only query wallets where autoFuel is set to true
18+
# false: Only query wallets where autoFuel is set to false
19+
self.autoFuel = None
20+
# Wallet's archive status in Safeheron App and Web Console
21+
# True: Archived
22+
# False: Unarchived
23+
self.archived = None
1524
# Filter the response based on this account name prefix
1625
self.namePrefix = None
1726
# Filter the response based on this account name suffix
@@ -36,11 +45,13 @@ def __init__(self):
3645
# Merchant unique business ID (100 characters max)
3746
# The customerRefId uniquely represents a wallet. In the case of duplicate customerRefId values (for example, when resubmitting due to request timeouts or other errors), the data returned by the interface will remain consistent
3847
self.customerRefId = None
39-
# Whether display in Safeheron Console
48+
# Whether display in Safeheron Console
4049
# True: not display
4150
# False: display
4251
# Default: false
4352
self.hiddenOnUI = None
53+
# Auto-refuel. If set to true, the Gas Service will automatically supplement the Gas fee for the wallet when a transaction is initiated. The default value is false
54+
self.autoFuel = None
4455
# Account tag
4556
self.accountTag = None
4657
# Coin key list, 20 array elements max
@@ -56,6 +67,8 @@ def __init__(self):
5667
# False: display
5768
# Default: true
5869
self.hiddenOnUI = None
70+
# Auto-refuel. If set to true, the Gas Service will automatically supplement the Gas fee for the wallet when a transaction is initiated. The default value is false
71+
self.autoFuel = None
5972
# Number of wallets to be created, greater than 0, less than 100
6073
self.count = None
6174
# Account tag
@@ -79,6 +92,13 @@ def __init__(self):
7992
# Account tag
8093
self.accountTag = None
8194

95+
class BatchUpdateAccountFuelRequest:
96+
def __init__(self):
97+
# Account key, max is 100
98+
self.accountKeyList = None
99+
# If set to true, Gas Service will automatically supplement the transaction fee (Gas) for the wallet when a transaction is initiated
100+
self.autoFuel = None
101+
82102

83103
class CreateAccountCoinRequest:
84104
def __init__(self):
@@ -211,6 +231,11 @@ def update_account_show_state(self, request: UpdateAccountShowStateRequest):
211231
def batch_update_account_tag(self, request: BatchUpdateAccountTagRequest):
212232
return self.api_client.send_request(request, '/v1/account/batch/update/tag')
213233

234+
# Batch Set Auto-Fuel
235+
# Set the autoFuel property for a batch of wallet accounts. Setting it to true means that the Gas Service will automatically supplement the transaction fee (Gas) for that wallet when a transaction is initiated; setting it to false means the Gas Service will no longer supplement the transaction fee for the wallet.
236+
def batch_update_account_autofuel(self, request: BatchUpdateAccountFuelRequest):
237+
return self.api_client.send_request(request, '/v1/account/batch/update/autofuel')
238+
214239
# Add Coins to a Wallet Account V1
215240
# Add a new coin to your wallet account, while generating the default address group for the added coin. Once successfully completed, it will return the address information of the newly created default address group. In case the added currency already exists within the account, it will promptly return the existing default address group information for that coin.
216241
# In a wallet account, UTXO-based cryptocurrencies can have multiple address groups, while other types of cryptocurrencies usually have only one. To check whether a particular cryptocurrency supports the addition of multiple address groups, simply check the 'isMultipleAddress' parameter through the Coin List.

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
with open("README.rst", "r") as f:
44
long_description = f.read()
55
setup(name='safeheron_api_sdk_python',
6-
version='1.1.19',
6+
version='1.1.20',
77
description='Python for Safeheron API',
88
long_description=long_description,
99
author='safeheron',

0 commit comments

Comments
 (0)