kopia lustrzana https://github.com/bugout-dev/moonstream
made it work
rodzic
1e55e987b4
commit
8e27fb0a76
|
@ -120,13 +120,13 @@ def get_ethereum_address_info(
|
|||
.one_or_none()
|
||||
)
|
||||
if erc721_label is not None:
|
||||
address_info.nft = data.EthereumSmartContractDetails(
|
||||
address_info.nft = data.EthereumNFTDetails(
|
||||
name=erc721_label.label_data.get("name"),
|
||||
symbol=erc721_label.label_data.get("symbol"),
|
||||
total_supplly=erc721_label.label_data.get("totalSupply"),
|
||||
total_supply=erc721_label.label_data.get("totalSupply"),
|
||||
external_url=[etherscan_token_url, blockchain_com_url],
|
||||
)
|
||||
|
||||
breakpoint()
|
||||
return address_info
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,6 @@ Pydantic schemas for the Moonstream HTTP API
|
|||
"""
|
||||
from typing import List, Optional, Dict, Any
|
||||
|
||||
from sqlalchemy.sql.selectable import alias
|
||||
|
||||
from pydantic import BaseModel, Field
|
||||
|
||||
|
@ -171,7 +170,7 @@ class EthereumSmartContractDetails(BaseModel):
|
|||
|
||||
|
||||
class EthereumNFTDetails(EthereumTokenDetails):
|
||||
total_supply: Optional[int] = Field(alias="totalSupply")
|
||||
total_supply: Optional[int]
|
||||
|
||||
|
||||
class EthereumAddressInfo(BaseModel):
|
||||
|
|
Ładowanie…
Reference in New Issue