InitialTadeedAlgoTransfer

Python pydantic class corresponding to json type `initial.tadeed.algo.transfer`.

class gwatn.types.InitialTadeedAlgoTransfer(*, MicroLat, MicroLon, ValidatorAddr, TaDaemonAddr, TaOwnerAddr, FirstDeedTransferMtx, TypeName='initial.tadeed.algo.transfer', Version='000')

TaValidator sends to GNodeFactory after validating Transactive Device.

Once the TaValidator has done the initial on-site inspection of the Transactive Device including its location and the type and quality of its power and energy metering, the TaValidator lets the GNodeFactory know by sending this message. Note the message also includes the lat/lon of the Transactive Device. On receiving and validating this message, the GNodeFactory will co-sign the transfer and send the TaDeed to the TaDaemon address. In addition, the GNodeFactory creates and sends a TaTradingRights certificate to the TaDaemon address. Only once the GNodeFactory has verified that the TaDaemon address owns the TaDeed and TaTradingRights will it change the GNodeStatus of the associated TerminalAsset from Pending to Active. [GNodeStatus](https://gridworks.readthedocs.io/en/latest/g-node-status.html) [TaDeed](https://gridworks.readthedocs.io/en/latest/ta-deed.html) [TaTradingRights](https://gridworks.readthedocs.io/en/latest/ta-trading-rights.html) [TaValidator](https://gridworks.readthedocs.io/en/latest/ta-validator.html) [TerminalAsset](https://gridworks.readthedocs.io/en/latest/terminal-asset.html) [Transactive Device](https://gridworks.readthedocs.io/en/latest/transactive-device.html)

Parameters:
  • MicroLat (int) –

  • MicroLon (int) –

  • ValidatorAddr (str) –

  • TaDaemonAddr (str) –

  • TaOwnerAddr (str) –

  • FirstDeedTransferMtx (str) –

  • TypeName (Literal['initial.tadeed.algo.transfer']) –

  • Version (str) –

classmethod check_axiom_1(v)

Axiom 1: Is correct Multisig. Decoded FirstDeedTransferMtx must have type MultisigTransaction from the 2-sig MultiAccount [GnfAdminAddr, ValidatorAddr]. [More info](https://gridworks.readthedocs.io/en/latest/g-node-factory.html#gnfadminaddr)

Parameters:

v (dict) –

Return type:

dict

classmethod check_axiom_2(v)

Axiom 2: TaDaemon funded by TaOwner. The TaDaemonAddr was created with funding from the TaOwnerAddr, and has sufficient funding according to the GNodeFactory.

Parameters:

v (dict) –

Return type:

dict

MicroLat:
  • Description: . The Latitude of the Transactive Device, times 10^6

MicroLon:
  • Description: . The Longitude of the Transactive Device, times 10^6

ValidatorAddr:
  • Description: . The Algoand address for the TaValidator who validated the location,

    metering and type of the Transactive Device.

  • Format: AlgoAddressStringFormat

TaDaemonAddr:
  • Description: . The Algorand address for the TaDaemon which will own the TaDeed

    and initially the TaTradingRights), as well as holding funds on

    behalf of the TaOwner.

  • Format: AlgoAddressStringFormat

TaOwnerAddr:
  • Description: . The Algorand address of the entity owning the Transactive Device, and

    thus also the TerminalAsset

  • Format: AlgoAddressStringFormat

FirstDeedTransferMtx:
  • Description: . The half-signed multi transaction for transferring the TaDeed to the

    TaDaemon.

  • Format: AlgoMsgPackEncoded

class gwatn.types.initial_tadeed_algo_transfer.check_is_algo_address_string_format(v)

AlgoAddressStringFormat format: The public key of a private/public Ed25519 key pair, transformed into an Algorand address, by adding a 4-byte checksum to the end of the public key and then encoding in base32.

Raises:

ValueError – if not AlgoAddressStringFormat format

Parameters:

v (str) –

class gwatn.types.initial_tadeed_algo_transfer.check_is_algo_msg_pack_encoded(v)

AlgoMSgPackEncoded format: the format of an transaction sent to the Algorand blockchain.

Raises:

ValueError – if not AlgoMSgPackEncoded format

Parameters:

v (str) –

class gwatn.types.InitialTadeedAlgoTransfer_Maker(micro_lat, micro_lon, validator_addr, ta_daemon_addr, ta_owner_addr, first_deed_transfer_mtx)
Parameters:
  • micro_lat (int) –

  • micro_lon (int) –

  • validator_addr (str) –

  • ta_daemon_addr (str) –

  • ta_owner_addr (str) –

  • first_deed_transfer_mtx (str) –

classmethod tuple_to_type(tuple)

Given a Python class object, returns the serialized JSON type object

Parameters:

tuple (InitialTadeedAlgoTransfer) –

Return type:

str

classmethod type_to_tuple(t)

Given a serialized JSON type object, returns the Python class object

Parameters:

t (str) –

Return type:

InitialTadeedAlgoTransfer