SystemDeviceFamilyAddRequest
Bases: OCIRequest
Request to add a device family. When the optional element resellerId is specified, the device family created is at reseller level. Device family name should be unique throughout the system including all the reseller level device families. The response is either a SuccessResponse or an ErrorResponse.
The following elements are only used in AS data mode and ignored in the XS data mode:
resellerId
Attributes:
device_family_name (str):
reseller_id (Optional[str]):
assign_device_type (Optional[List[str]]):
assign_tag_set (Optional[List[str]]):
Source code in src/mercury_ocip_fast/commands/commands.py
| @dataclass(kw_only=True)
class SystemDeviceFamilyAddRequest(OCIRequest):
"""Request to add a device family.
When the optional element resellerId is specified, the device family created is at reseller level. Device family name
should be unique throughout the system including all the reseller level device families.
The response is either a SuccessResponse or an ErrorResponse.
The following elements are only used in AS data mode and ignored in the XS data mode:
resellerId
Attributes:
device_family_name (str):
reseller_id (Optional[str]):
assign_device_type (Optional[List[str]]):
assign_tag_set (Optional[List[str]]):
"""
device_family_name: str = field(metadata={"alias": "deviceFamilyName"})
reseller_id: Optional[str] = field(default=None, metadata={"alias": "resellerId"})
assign_device_type: Optional[List[str]] = field(
default=None, metadata={"alias": "assignDeviceType"}
)
assign_tag_set: Optional[List[str]] = field(
default=None, metadata={"alias": "assignTagSet"}
)
|
Responses
Bases: OCIResponseSource code in src/mercury_ocip_fast/commands/base_command.py
| class SuccessResponse(OCIResponse):
pass
|
Bases: OCIResponseSource code in src/mercury_ocip_fast/commands/base_command.py
| class ErrorResponse(OCIResponse):
errorCode: Optional[int] = None
summary: str
summaryEnglish: str
detail: Optional[str] = None
|
Example Usage
from mercury_ocip_fast.client import Client
from mercury_ocip_fast.commands import SystemDeviceFamilyAddRequest
client = Client()
command = SystemDeviceFamilyAddRequest(
device_family_name=...,
reseller_id=...,
assign_device_type=...,
assign_tag_set=...,
)
response = client.command(command)
print(response)
Example 2 with Raw Command
from mercury_ocip_fast.client import Client
client = Client()
response = client.raw_command("SystemDeviceFamilyAddRequest",
device_family_name=...,
reseller_id=...,
assign_device_type=...,
assign_tag_set=...,
)
print(response)