tbapi.api.interfaces.imetadata

 1from __future__ import annotations
 2from typing import TYPE_CHECKING
 3from tbapi.common.decorators import tb_interface
 4from tbapi.common.converters import to_python_datetime, to_net_datetime
 5from datetime import datetime
 6from Tickblaze.Scripts.Api.Interfaces import IMetadata as _IMetadata
 7from typing import Any, overload
 8from abc import ABC, abstractmethod
 9if TYPE_CHECKING:
10    from tbapi.api.models.metadata import Metadata
11
12@tb_interface(_IMetadata)
13class IMetadata():
14    """Defines metadata properties for a script, including name, description, and related metadata."""
15
16    @property
17    def name(self) -> str:
18        """The name of the script."""
19        val = self._value.Name
20        return val
21    @property
22    def short_name(self) -> str:
23        """The short name of the script."""
24        val = self._value.ShortName
25        return val
26    @property
27    def description(self) -> str:
28        """A description of the script."""
29        val = self._value.Description
30        return val
31    @property
32    def metadata(self) -> Metadata:
33        """Associated metadata for the script."""
34        from tbapi.api.models.metadata import Metadata
35        val = self._value.Metadata
36        return Metadata(_existing=val)
37    @property
38    def product_code_aliases(self) -> list[str]:
39        val = self._value.ProductCodeAliases
40        return val
@tb_interface(_IMetadata)
class IMetadata:
18@tb_interface(_IMetadata)
19class IMetadata():
20    """Defines metadata properties for a script, including name, description, and related metadata."""
21
22    @property
23    def name(self) -> str:
24        """The name of the script."""
25        val = self._value.Name
26        return val
27    @property
28    def short_name(self) -> str:
29        """The short name of the script."""
30        val = self._value.ShortName
31        return val
32    @property
33    def description(self) -> str:
34        """A description of the script."""
35        val = self._value.Description
36        return val
37    @property
38    def metadata(self) -> Metadata:
39        """Associated metadata for the script."""
40        from tbapi.api.models.metadata import Metadata
41        val = self._value.Metadata
42        return Metadata(_existing=val)
43    @property
44    def product_code_aliases(self) -> list[str]:
45        val = self._value.ProductCodeAliases
46        return val

Defines metadata properties for a script, including name, description, and related metadata.

IMetadata(*args, **kwargs)
199        def __init__(self, *args, **kwargs):
200            pass
name: str
22    @property
23    def name(self) -> str:
24        """The name of the script."""
25        val = self._value.Name
26        return val

The name of the script.

short_name: str
27    @property
28    def short_name(self) -> str:
29        """The short name of the script."""
30        val = self._value.ShortName
31        return val

The short name of the script.

description: str
32    @property
33    def description(self) -> str:
34        """A description of the script."""
35        val = self._value.Description
36        return val

A description of the script.

metadata: tbapi.api.models.metadata.Metadata
37    @property
38    def metadata(self) -> Metadata:
39        """Associated metadata for the script."""
40        from tbapi.api.models.metadata import Metadata
41        val = self._value.Metadata
42        return Metadata(_existing=val)

Associated metadata for the script.

product_code_aliases: list[str]
43    @property
44    def product_code_aliases(self) -> list[str]:
45        val = self._value.ProductCodeAliases
46        return val