TavalidatorcertAlgoCreate

Python pydantic class corresponding to json type `tavalidatorcert.algo.create`.

class gwatn.types.TavalidatorcertAlgoCreate(*, ValidatorAddr, HalfSignedCertCreationMtx, TypeName='tavalidatorcert.algo.create', Version='000')

Used for Step 1 of TaValidator certification.

Meant to be sent from a pending TaValidator to the GNodeFactory (Gnf), to initiate the process of certifying the pending TaValidator. [More info](https://gridworks.readthedocs.io/en/latest/ta-validator.html).

Parameters:
  • ValidatorAddr (str) –

  • HalfSignedCertCreationMtx (str) –

  • TypeName (Literal['tavalidatorcert.algo.create']) –

  • Version (str) –

classmethod check_axiom_1(v)

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

Parameters:

v (dict) –

Return type:

dict

classmethod check_half_signed_cert_creation_mtx(v)

Axioms 2, 3:

Axiom 2: Is AssetConfigTxn. The transaction must have type AssetConfigTxn.

Axiom 3: Is ValidatorCert. For the asset getting created: Total is 1, Decimals is 0, UnitName is VLDTR, Manager is GnfAdminAddr, AssetName is not blank. [More info](https://gridworks.readthedocs.io/en/latest/ta-validator.html#tavalidator-certificate)

Parameters:

v (str) –

Return type:

str

classmethod check_validator_addr(v)

Axiom 5: Uniqueness. There must not already be a TaValidatorCert belonging to the 2-sig [GnfAdminAddr, ValidatorAddr] address.

Parameters:

v (str) –

Return type:

str

ValidatorAddr:
  • Description: The address of the pending TaValidator

  • Format: AlgoAddressStringFormat

HalfSignedCertCreationMtx:
  • Description: Algo multi-transaction for certificate creation, with 1 of 2 signatures

  • Format: AlgoMsgPackEncoded

class gwatn.types.tavalidatorcert_algo_create.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.tavalidatorcert_algo_create.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.TavalidatorcertAlgoCreate_Maker(validator_addr, half_signed_cert_creation_mtx)
Parameters:
  • validator_addr (str) –

  • half_signed_cert_creation_mtx (str) –

classmethod tuple_to_type(tuple)

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

Parameters:

tuple (TavalidatorcertAlgoCreate) –

Return type:

str

classmethod type_to_tuple(t)

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

Parameters:

t (str) –

Return type:

TavalidatorcertAlgoCreate