Record Models¶
- pydantic model pyil2.models.record.BaseRecordModel¶
Bases:
BaseCamelModel
Base record model.
- field application_id: int = 0 (alias 'applicationId')¶
Application id this record is associated with.
- field chain_id: str [Required] (alias 'chainId')¶
Chain id that owns this record.
- field created_at: datetime [Required] (alias 'createdAt')¶
Time of record creation.
- field network: str [Required]¶
Network name this chain is part.
- field payload_tag_id: int = 0 (alias 'payloadTagId')¶
The payload’s TagId.
- field reference: str [Required]¶
Universal reference of this record.
- field serial: int = 0¶
Block serial number. For the first record this value is zero (0).
- field type: RecordType = RecordType.ROOT¶
Block type. Most records are of the type ‘Data’.
- field version: int = 0¶
Version of this record structure.
- pydantic model pyil2.models.record.ForceInterlockModel¶
Bases:
BaseCamelModel
Force interlock parameter details.
- field hash_algorithm: HashAlgorithms = HashAlgorithms.COPY (alias 'hashAlgorithm')¶
Hash algorithm to use.
- field min_serial: int = 0 (alias 'minSerial')¶
Required minimum of the serial of the last record in target chain whose hash will be pulled.
- field target_chain: str [Required] (alias 'targetChain')¶
Id of chain to be interlocked.
- pydantic model pyil2.models.record.InterlockingRecordModel¶
Bases:
BaseRecordModel
Interlocking details.
- field application_id: int = 0 (alias 'applicationId')¶
Application id this record is associated with.
- field chain_id: str [Required] (alias 'chainId')¶
Chain id that owns this record.
- field created_at: datetime.datetime [Required] (alias 'createdAt')¶
Time of record creation.
- field interlocked_chain_id: str | None = None (alias 'interlockedChainId')¶
Interlocked Chain.
- field interlocked_record_hash: str | None = None (alias 'interlockedRecordHash')¶
Interlock Record Hash.
- field interlocked_record_offset: int = 0 (alias 'interlockedRecordOffset')¶
Interlocked Record Offset.
- field interlocked_record_serial: int = 0 (alias 'interlockedRecordSerial')¶
Interlocked Record Serial.
- field network: str [Required]¶
Network name this chain is part.
- field payload_bytes: str [Required] (alias 'payloadBytes')¶
Payload bytes.
- field payload_tag_id: int = 0 (alias 'payloadTagId')¶
The payload’s TagId.
- field reference: str [Required]¶
Universal reference of this record.
- field serial: int = 0¶
Block serial number. For the first record this value is zero (0).
- field type: RecordType = RecordType.ROOT¶
Block type. Most records are of the type ‘Data’.
- field version: int = 0¶
Version of this record structure.
- pydantic model pyil2.models.record.NewRecordModel¶
Bases:
BaseCamelModel
New record model to be added to the chain as raw bytes.
- field application_id: int = 0 (alias 'applicationId')¶
Application id this record is associated with.
- field payload_bytes: bytes [Required] (alias 'payloadBytes')¶
Payload bytes.
- field type: RecordType = RecordType.DATA¶
Block type. Most records are of the type ‘Data’.
- classmethod serialize_reserved_tags(value: bytes) str ¶
Serialize payload_bytes field.
- pydantic model pyil2.models.record.OpaqueRecordModel¶
Bases:
BaseCamelModel
Opaque record details.
- field application_id: int = 0 (alias 'applicationId')¶
Application id this record is associated with.
- field chain_id: str | None = None (alias 'chainId')¶
Chain id that owns this record.
- field created_at: datetime [Required] (alias 'createdAt')¶
Time of record creation.
- field network: str | None = None¶
Network name this chain is part.
- field payload: bytes | None = None¶
Opaque payload bytes.
- field payload_length: int = 0 (alias 'payloadLength')¶
The opaque payload length in bytes.
- field payload_type_id: int = 0 (alias 'payloadTypeId')¶
The payload’s TypeId.
- field serial: int = 0¶
Block serial number. For the first record this value is zero (0).
- pydantic model pyil2.models.record.RecordAsJsonModel¶
Bases:
BaseRecordModel
Record model as JSON.
- field application_id: int = 0 (alias 'applicationId')¶
Application id this record is associated with.
- field chain_id: str [Required] (alias 'chainId')¶
Chain id that owns this record.
- field created_at: datetime.datetime [Required] (alias 'createdAt')¶
Time of record creation.
- field network: str [Required]¶
Network name this chain is part.
- field payload: Dict[str, Any] [Required]¶
Payload as JSON.
- field payload_tag_id: int = 0 (alias 'payloadTagId')¶
The payload’s TagId.
- field reference: str [Required]¶
Universal reference of this record.
- field serial: int = 0¶
Block serial number. For the first record this value is zero (0).
- field type: RecordType = RecordType.ROOT¶
Block type. Most records are of the type ‘Data’.
- field version: int = 0¶
Version of this record structure.
- pydantic model pyil2.models.record.RecordModel¶
Bases:
BaseRecordModel
Record model.
- field application_id: int = 0 (alias 'applicationId')¶
Application id this record is associated with.
- field chain_id: str [Required] (alias 'chainId')¶
Chain id that owns this record.
- field created_at: datetime.datetime [Required] (alias 'createdAt')¶
Time of record creation.
- field network: str [Required]¶
Network name this chain is part.
- field payload_bytes: bytes | None = None (alias 'payloadBytes')¶
Payload bytes.
- field payload_tag_id: int = 0 (alias 'payloadTagId')¶
The payload’s TagId.
- field reference: str [Required]¶
Universal reference of this record.
- field serial: int = 0¶
Block serial number. For the first record this value is zero (0).
- field type: RecordType = RecordType.ROOT¶
Block type. Most records are of the type ‘Data’.
- field version: int = 0¶
Version of this record structure.