Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5612278

Browse files
author
Kotsias, Panagiotis-Christos
committed
Finalized
1 parent010e525 commit5612278

File tree

3 files changed

+94
-3
lines changed

3 files changed

+94
-3
lines changed

‎etherscan/modules/contracts.py‎

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,30 @@
1+
frometherscan.utils.datatypesimportContractAddress
2+
frometherscan.enums.actions_enumimportActionsEnumasactions
3+
frometherscan.enums.fields_enumimportFieldsEnumasfields
4+
frometherscan.enums.modules_enumimportModulesEnumasmodules
5+
6+
17
classContracts:
2-
pass
8+
@staticmethod
9+
defget_contract_abi(contract:ContractAddress)->str:
10+
url= (
11+
f"{fields.MODULE}"
12+
f"{modules.CONTRACT}"
13+
f"{fields.ACTION}"
14+
f"{actions.GET_ABI}"
15+
f"{fields.ADDRESS}"
16+
f"{contract}"
17+
)
18+
returnurl
19+
20+
@staticmethod
21+
defget_contract_source_code(contract:ContractAddress)->str:
22+
url= (
23+
f"{fields.MODULE}"
24+
f"{modules.CONTRACT}"
25+
f"{fields.ACTION}"
26+
f"{actions.GET_SOURCE_CODE}"
27+
f"{fields.ADDRESS}"
28+
f"{contract}"
29+
)
30+
returnurl

‎etherscan/modules/tokens.py‎

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,37 @@
1+
frometherscan.utils.datatypesimportContractAddress,TokenAddress
2+
frometherscan.enums.actions_enumimportActionsEnumasactions
3+
frometherscan.enums.tags_enumimportTagsEnumastags
4+
frometherscan.enums.fields_enumimportFieldsEnumasfields
5+
frometherscan.enums.modules_enumimportModulesEnumasmodules
6+
7+
18
classTokens:
2-
pass
9+
@staticmethod
10+
defget_total_supply_by_contract_address(contract:ContractAddress)->str:
11+
url= (
12+
f"{fields.MODULE}"
13+
f"{modules.STATS}"
14+
f"{fields.ACTION}"
15+
f"{actions.TOKEN_SUPPLY}"
16+
f"{fields.CONTRACT_ADDRESS}"
17+
f"{contract}"
18+
)
19+
returnurl
20+
21+
@staticmethod
22+
defget_acc_balance_by_token_and_contract_address(
23+
contract:ContractAddress,token:TokenAddress
24+
)->str:
25+
url= (
26+
f"{fields.MODULE}"
27+
f"{modules.ACCOUNT}"
28+
f"{fields.ACTION}"
29+
f"{actions.TOKEN_BALANCE}"
30+
f"{fields.CONTRACT_ADDRESS}"
31+
f"{contract}"
32+
f"{fields.ADDRESS}"
33+
f"{token}"
34+
f"{fields.TAG}"
35+
f"{tags.LATEST}"
36+
)
37+
returnurl

‎etherscan/modules/transactions.py‎

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,30 @@
1+
frometherscan.utils.datatypesimportTxHash
2+
frometherscan.enums.actions_enumimportActionsEnumasactions
3+
frometherscan.enums.fields_enumimportFieldsEnumasfields
4+
frometherscan.enums.modules_enumimportModulesEnumasmodules
5+
6+
17
classTransactions:
2-
pass
8+
@staticmethod
9+
defcheck_contract_execution_status(txhash:TxHash)->str:
10+
url= (
11+
f"{fields.MODULE}"
12+
f"{modules.TRANSACTION}"
13+
f"{fields.ACTION}"
14+
f"{actions.GET_STATUS}"
15+
f"{fields.TXHASH}"
16+
f"{txhash}"
17+
)
18+
returnurl
19+
20+
@staticmethod
21+
defcheck_tx_receipt_status(txhash:TxHash)->str:
22+
url= (
23+
f"{fields.MODULE}"
24+
f"{modules.TRANSACTION}"
25+
f"{fields.ACTION}"
26+
f"{actions.GET_TX_RECEIPT_STATUS}"
27+
f"{fields.TXHASH}"
28+
f"{txhash}"
29+
)
30+
returnurl

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp