Apps Models

pydantic model pyil2.models.apps.AppsModel

Bases: BaseCamelModel

List of valid apps in the network.

field network: str | None = None

Network name.

field valid_apps: List[InterlockAppTraitsModel] [Optional] (alias 'validApps')

Currently valid apps for this network.

pydantic model pyil2.models.apps.DataFieldEnumeration

Bases: BaseCamelModel

Data field enumeration model.

field description: str | None = None

Description of the data field enumeration.

field id: int [Required]

Data field enumeration ID.

field name: str [Required]

Name of the data field enumeration.

classmethod from_concatenated_string(value: str) List[Self]

Parse a string with concatenated DataFieldEnumeration in the format: #<int>|<str>|[<str>|].

Parameters:

value (str) – A string with concatenated DataFieldEnumerations in string format.

Returns:

List of data field enumerations.

Return type:

[DataFieldEnumeration]

to_il2_string() str

str: IL2 string representation of the DataFieldEnumeration: #<int>|<str>|[<str>|].

pydantic model pyil2.models.apps.DataFieldModel

Bases: BaseCamelModel

Data field model.

Validators:
field cast: DataFieldCast | None = None

Type of the data field.

field description: str | None = None

Data field description.

field element_tag_id: int | None = None (alias 'elementTagId')

The type of the field in case it is an array.

field enumeration: List[DataFieldEnumeration] [Optional]

A list of data field enumerations.

Validated by:
field enumeration_as_flags: bool | None = None (alias 'enumerationAsFlags')

If True, the enumerations can be combined using bitwise-or. If False, only one value can be used.

field is_dreprecated: bool | None = None (alias 'isDreprecated')

If True the field is deprecated.

field is_opaque: bool | None = None (alias 'isOpaque')

If True the field is stored in raw bytes.

field name: str | None = None

Name of the data field.

field sub_data_fields: List[DataFieldModel] [Optional] (alias 'subDataFields')

If the data field in composed of more fields, indicates the metadata of the subdata fields.

field tag_id: int = 0 (alias 'tagId')

Type of the field. (see tags in the InterlockLedger node documentation)

field version: int = 0

Version of the data field.

validator pre_process_enumeration  »  enumeration

Deserialize from string.

classmethod serialize_enumeration(value: List[DataFieldEnumeration])

Serialize DataField enumeration.

pydantic model pyil2.models.apps.DataIndexElementModel

Bases: BaseCamelModel

Data index element.

field descending_order: bool | None = None (alias 'descendingOrder')

Indicate if the field is ordered in descending order.

field field_path: str | None = None (alias 'fieldPath')

Path of the data field to be indexed.

field function: str | None = None

To be defined.

pydantic model pyil2.models.apps.DataIndexModel

Bases: BaseCamelModel

Index of the data model.

field elements: List[DataIndexElementModel] [Optional]

Elements of the index.

field is_unique: bool | None = None (alias 'isUnique')

Indicate if the data field is unique.

field name: str | None = None

Name of the index.

pydantic model pyil2.models.apps.DataModel

Bases: BaseCamelModel

Data model for the payloads and actions for the records the application stores in the chains.

field data_fields: List[DataFieldModel] [Optional] (alias 'dataFields')

The list of data fields.

field description: str | None = None

Description of the data model.

field indexes: List[DataIndexModel] [Optional]

List of indexes for records of this type.

field payload_name: str | None = None (alias 'payloadName')

Name of the record model.

field payload_tag_id: int = 0 (alias 'payloadTagId')

Tag id for this payload type. It must be a number in the reserved ranges.

field version: int = 0

Version of this data model, should start from 1.

pydantic model pyil2.models.apps.InterlockAppTraitsModel

Bases: BaseCamelModel

Interlock App details model.

Validators:
field app_version: str [Required] (alias 'appVersion')

Application semantic version, with four numeric parts.

field data_models: List[DataModel] [Required] (alias 'dataModels')

The list of data models for the payloads of the records stored in the chains.

field description: str [Required]

Description of the application.

field id: int = 0

Unique ID for the application.

field name: str [Required]

Application name.

field publisher_id: str [Required] (alias 'publisherId')

Publisher ID, which is the identifier for the key the publisher uses to sign the workflow requests in its own chain. It should match the publisher_name

field publisher_name: str [Required] (alias 'publisherName')

Publisher name as registered in the Genesis chain of the network.

field reserved_il_tag_ids: List[LimitedRange] [Required] (alias 'reservedILTagIds')

The list of ranges of ILTagIds to reserve for the application.

Validated by:
field start: datetime [Required]

The start date for the validity of the app, but if prior to the effective publication of the app will be overridden with the publication date and time.

field version: int = 0

Version of the application.

validator pre_process_reserved_tags  »  reserved_il_tag_ids

Deserialize reserved tags from list of strings.

classmethod serialize_reserved_tags(value: List[LimitedRange])

Serialize reseved tags.