File manager - Edit - /usr/lib/mysqlsh/lib/python3.9/site-packages/oci/iot/iot_client.py
Back
# coding: utf-8 # Copyright (c) 2016, 2026, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. # NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20250531 from __future__ import absolute_import from oci._vendor import requests # noqa: F401 from oci._vendor import six from oci import retry, circuit_breaker # noqa: F401 from oci.base_client import BaseClient from oci.config import get_config_value_or_default, validate_config from oci.signer import Signer from oci.util import Sentinel, get_signer_from_authentication_type, AUTHENTICATION_TYPE_FIELD_NAME from oci.exceptions import InvalidDeveloperToolConfiguration from oci.developer_tool_configuration import OCI_SDK_ENABLED_SERVICES_SET from .models import iot_type_mapping missing = Sentinel("Missing") class IotClient(object): """ Use the Internet of Things (IoT) API to manage IoT domain groups, domains, and digital twin resources including models, adapters, instances, and relationships. For more information, see [Internet of Things](https://docs.oracle.com/iaas/Content/internet-of-things/home.htm). """ def __init__(self, config, **kwargs): """ Creates a new service client :param dict config: Configuration keys and values as per `SDK and Tool Configuration <https://docs.oracle.com/iaas/Content/API/Concepts/sdkconfig.htm>`__. The :py:meth:`~oci.config.from_file` method can be used to load configuration from a file. Alternatively, a ``dict`` can be passed. You can validate_config the dict using :py:meth:`~oci.config.validate_config` :param str service_endpoint: (optional) The endpoint of the service to call using this client. For example ``https://iaas.us-ashburn-1.oraclecloud.com``. If this keyword argument is not provided then it will be derived using the region in the config parameter. You should only provide this keyword argument if you have an explicit need to specify a service endpoint. :param timeout: (optional) The connection and read timeouts for the client. The default values are connection timeout 10 seconds and read timeout 60 seconds. This keyword argument can be provided as a single float, in which case the value provided is used for both the read and connection timeouts, or as a tuple of two floats. If a tuple is provided then the first value is used as the connection timeout and the second value as the read timeout. :type timeout: float or tuple(float, float) :param signer: (optional) The signer to use when signing requests made by the service client. The default is to use a :py:class:`~oci.signer.Signer` based on the values provided in the config parameter. One use case for this parameter is for `Instance Principals authentication <https://docs.oracle.com/iaas/Content/Identity/Tasks/callingservicesfrominstances.htm>`__ by passing an instance of :py:class:`~oci.auth.signers.InstancePrincipalsSecurityTokenSigner` as the value for this keyword argument :type signer: :py:class:`~oci.signer.AbstractBaseSigner` :param obj retry_strategy: (optional) A retry strategy to apply to all calls made by this service client (i.e. at the client level). There is no retry strategy applied by default. Retry strategies can also be applied at the operation level by passing a ``retry_strategy`` keyword argument as part of calling the operation. Any value provided at the operation level will override whatever is specified at the client level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. A convenience :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` is also available. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. :param obj circuit_breaker_strategy: (optional) A circuit breaker strategy to apply to all calls made by this service client (i.e. at the client level). This client uses :py:data:`~oci.circuit_breaker.DEFAULT_CIRCUIT_BREAKER_STRATEGY` as default if no circuit breaker strategy is provided. The specifics of circuit breaker strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/circuit_breakers.html>`__. :param function circuit_breaker_callback: (optional) Callback function to receive any exceptions triggerred by the circuit breaker. :param bool client_level_realm_specific_endpoint_template_enabled: (optional) A boolean flag to indicate whether or not this client should be created with realm specific endpoint template enabled or disable. By default, this will be set as None. :param allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this client should allow control characters in the response object. By default, the client will not allow control characters to be in the response object. :param enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this client should enable strict url encoding in path params of a request. By default, the client will not enable strict url encoding """ if not OCI_SDK_ENABLED_SERVICES_SET.is_service_enabled("iot"): raise InvalidDeveloperToolConfiguration("The Developer Tool Configuration has disabled this service, this behavior is controlled by OCI_SDK_ENABLED_SERVICES_SET variable. Please check if your local developer-tool-configuration file configured the service you're targeting or contact the cloud provider on the availability of this service") validate_config(config, signer=kwargs.get('signer')) if 'signer' in kwargs: signer = kwargs['signer'] elif AUTHENTICATION_TYPE_FIELD_NAME in config: signer = get_signer_from_authentication_type(config) else: signer = Signer( tenancy=config["tenancy"], user=config["user"], fingerprint=config["fingerprint"], private_key_file_location=config.get("key_file"), pass_phrase=get_config_value_or_default(config, "pass_phrase"), private_key_content=config.get("key_content") ) base_client_init_kwargs = { 'regional_client': True, 'service_endpoint': kwargs.get('service_endpoint'), 'base_path': '/20250531', 'service_endpoint_template': 'https://iot.{region}.oci.{secondLevelDomain}', 'service_endpoint_template_per_realm': { }, # noqa: E201 E202 'service_uses_dualstack_endpoints_by_default': False, 'skip_deserialization': kwargs.get('skip_deserialization', False), 'circuit_breaker_strategy': kwargs.get('circuit_breaker_strategy', circuit_breaker.GLOBAL_CIRCUIT_BREAKER_STRATEGY), 'client_level_realm_specific_endpoint_template_enabled': kwargs.get('client_level_realm_specific_endpoint_template_enabled'), 'client_level_dualstack_endpoints_enabled': kwargs.get('client_level_dualstack_endpoints_enabled') } if 'timeout' in kwargs: base_client_init_kwargs['timeout'] = kwargs.get('timeout') if base_client_init_kwargs.get('circuit_breaker_strategy') is None: base_client_init_kwargs['circuit_breaker_strategy'] = circuit_breaker.DEFAULT_CIRCUIT_BREAKER_STRATEGY if 'allow_control_chars' in kwargs: base_client_init_kwargs['allow_control_chars'] = kwargs.get('allow_control_chars') if 'enable_strict_url_encoding' in kwargs: base_client_init_kwargs['enable_strict_url_encoding'] = kwargs.get('enable_strict_url_encoding') self.base_client = BaseClient("iot", config, signer, iot_type_mapping, **base_client_init_kwargs) self.retry_strategy = kwargs.get('retry_strategy') self.circuit_breaker_callback = kwargs.get('circuit_breaker_callback') def change_iot_domain_compartment(self, iot_domain_id, change_iot_domain_compartment_details, **kwargs): """ Moves an IoT domain to a different compartment within the same tenancy. For information about moving resources between compartments, see `Moving Resources to a Different Compartment`__. __ https://docs.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes :param str iot_domain_id: (required) The `OCID`__ of the IoT domain. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.ChangeIotDomainCompartmentDetails change_iot_domain_compartment_details: (required) Details for changing the IoT domain compartment. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/change_iot_domain_compartment.py.html>`__ to see an example of how to use change_iot_domain_compartment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/iotDomains/{iotDomainId}/actions/changeCompartment" method = "POST" operation_name = "change_iot_domain_compartment" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/ChangeIotDomainCompartment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id", "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"change_iot_domain_compartment got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainId": iot_domain_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=change_iot_domain_compartment_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=change_iot_domain_compartment_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def change_iot_domain_data_retention_period(self, iot_domain_id, change_iot_domain_data_retention_period_details, **kwargs): """ Updates Data Retention Period of the IoT Domain. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.ChangeIotDomainDataRetentionPeriodDetails change_iot_domain_data_retention_period_details: (required) Details for changing data retention period of IoT domain data. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/change_iot_domain_data_retention_period.py.html>`__ to see an example of how to use change_iot_domain_data_retention_period API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/iotDomains/{iotDomainId}/actions/changeDataRetentionPeriod" method = "POST" operation_name = "change_iot_domain_data_retention_period" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/ChangeIotDomainDataRetentionPeriod" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id", "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"change_iot_domain_data_retention_period got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainId": iot_domain_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=change_iot_domain_data_retention_period_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=change_iot_domain_data_retention_period_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def change_iot_domain_group_compartment(self, iot_domain_group_id, change_iot_domain_group_compartment_details, **kwargs): """ Moves an IoT domain group to a different compartment within the same tenancy. For information about moving resources between compartments, see `Moving Resources to a Different Compartment`__. __ https://docs.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes :param str iot_domain_group_id: (required) The `OCID`__ of an IoT Domain Group. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.ChangeIotDomainGroupCompartmentDetails change_iot_domain_group_compartment_details: (required) Details for changing the IoT domain group compartment. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/change_iot_domain_group_compartment.py.html>`__ to see an example of how to use change_iot_domain_group_compartment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainGroupId'] resource_path = "/iotDomainGroups/{iotDomainGroupId}/actions/changeCompartment" method = "POST" operation_name = "change_iot_domain_group_compartment" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/ChangeIotDomainGroupCompartment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id", "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"change_iot_domain_group_compartment got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainGroupId": iot_domain_group_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=change_iot_domain_group_compartment_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=change_iot_domain_group_compartment_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def configure_iot_domain_data_access(self, iot_domain_id, configure_iot_domain_data_access_details, **kwargs): """ Updates an IoT domain Data Access. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.ConfigureIotDomainDataAccessDetails configure_iot_domain_data_access_details: (required) Details for configuring data access. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/configure_iot_domain_data_access.py.html>`__ to see an example of how to use configure_iot_domain_data_access API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/iotDomains/{iotDomainId}/actions/configureDataAccess" method = "POST" operation_name = "configure_iot_domain_data_access" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/ConfigureIotDomainDataAccess" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id", "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"configure_iot_domain_data_access got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainId": iot_domain_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=configure_iot_domain_data_access_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=configure_iot_domain_data_access_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def configure_iot_domain_group_data_access(self, iot_domain_group_id, configure_iot_domain_group_data_access_details, **kwargs): """ Updates an IoT domain Group Data Access. :param str iot_domain_group_id: (required) The `OCID`__ of an IoT Domain Group. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.ConfigureIotDomainGroupDataAccessDetails configure_iot_domain_group_data_access_details: (required) Details for configuring data access. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/configure_iot_domain_group_data_access.py.html>`__ to see an example of how to use configure_iot_domain_group_data_access API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainGroupId'] resource_path = "/iotDomainGroups/{iotDomainGroupId}/actions/configureDataAccess" method = "POST" operation_name = "configure_iot_domain_group_data_access" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/ConfigureIotDomainGroupDataAccess" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id", "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"configure_iot_domain_group_data_access got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainGroupId": iot_domain_group_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=configure_iot_domain_group_data_access_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=configure_iot_domain_group_data_access_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def create_digital_twin_adapter(self, create_digital_twin_adapter_details, **kwargs): """ Creates a new digital twin adapter. :param oci.iot.models.CreateDigitalTwinAdapterDetails create_digital_twin_adapter_details: (required) Details for the new digital twin adapter. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinAdapter` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/create_digital_twin_adapter.py.html>`__ to see an example of how to use create_digital_twin_adapter API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] resource_path = "/digitalTwinAdapters" method = "POST" operation_name = "create_digital_twin_adapter" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinAdapter/CreateDigitalTwinAdapter" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"create_digital_twin_adapter got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_adapter_details, response_type="DigitalTwinAdapter", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_adapter_details, response_type="DigitalTwinAdapter", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def create_digital_twin_instance(self, create_digital_twin_instance_details, **kwargs): """ Creates a new digital twin instance. :param oci.iot.models.CreateDigitalTwinInstanceDetails create_digital_twin_instance_details: (required) Details for the new digital twin instance. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinInstance` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/create_digital_twin_instance.py.html>`__ to see an example of how to use create_digital_twin_instance API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] resource_path = "/digitalTwinInstances" method = "POST" operation_name = "create_digital_twin_instance" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/CreateDigitalTwinInstance" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"create_digital_twin_instance got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_instance_details, response_type="DigitalTwinInstance", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_instance_details, response_type="DigitalTwinInstance", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def create_digital_twin_model(self, create_digital_twin_model_details, **kwargs): """ Creates a new digital twin model. :param oci.iot.models.CreateDigitalTwinModelDetails create_digital_twin_model_details: (required) Details for the new digital twin model. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinModel` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/create_digital_twin_model.py.html>`__ to see an example of how to use create_digital_twin_model API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] resource_path = "/digitalTwinModels" method = "POST" operation_name = "create_digital_twin_model" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinModel/CreateDigitalTwinModel" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"create_digital_twin_model got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_model_details, response_type="DigitalTwinModel", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_model_details, response_type="DigitalTwinModel", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def create_digital_twin_relationship(self, create_digital_twin_relationship_details, **kwargs): """ Creates a new digital twin relationship. :param oci.iot.models.CreateDigitalTwinRelationshipDetails create_digital_twin_relationship_details: (required) Details for the new digital twin relationship. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinRelationship` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/create_digital_twin_relationship.py.html>`__ to see an example of how to use create_digital_twin_relationship API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] resource_path = "/digitalTwinRelationships" method = "POST" operation_name = "create_digital_twin_relationship" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinRelationship/CreateDigitalTwinRelationship" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"create_digital_twin_relationship got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_relationship_details, response_type="DigitalTwinRelationship", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, header_params=header_params, body=create_digital_twin_relationship_details, response_type="DigitalTwinRelationship", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def create_iot_domain(self, create_iot_domain_details, **kwargs): """ Creates a new IoT domain. :param oci.iot.models.CreateIotDomainDetails create_iot_domain_details: (required) Details for the new IoT domain. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.IotDomain` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/create_iot_domain.py.html>`__ to see an example of how to use create_iot_domain API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] resource_path = "/iotDomains" method = "POST" operation_name = "create_iot_domain" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/CreateIotDomain" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"create_iot_domain got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, header_params=header_params, body=create_iot_domain_details, response_type="IotDomain", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, header_params=header_params, body=create_iot_domain_details, response_type="IotDomain", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def create_iot_domain_group(self, create_iot_domain_group_details, **kwargs): """ Creates a new IoT domain group. :param oci.iot.models.CreateIotDomainGroupDetails create_iot_domain_group_details: (required) Details for the new IoT domain group. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.IotDomainGroup` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/create_iot_domain_group.py.html>`__ to see an example of how to use create_iot_domain_group API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] resource_path = "/iotDomainGroups" method = "POST" operation_name = "create_iot_domain_group" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/CreateIotDomainGroup" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"create_iot_domain_group got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, header_params=header_params, body=create_iot_domain_group_details, response_type="IotDomainGroup", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, header_params=header_params, body=create_iot_domain_group_details, response_type="IotDomainGroup", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def delete_digital_twin_adapter(self, digital_twin_adapter_id, **kwargs): """ Deletes the digital twin adapter identified by the specified OCID. :param str digital_twin_adapter_id: (required) The `OCID`__ of the digital twin adapter. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/delete_digital_twin_adapter.py.html>`__ to see an example of how to use delete_digital_twin_adapter API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinAdapterId'] resource_path = "/digitalTwinAdapters/{digitalTwinAdapterId}" method = "DELETE" operation_name = "delete_digital_twin_adapter" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinAdapter/DeleteDigitalTwinAdapter" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"delete_digital_twin_adapter got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinAdapterId": digital_twin_adapter_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def delete_digital_twin_instance(self, digital_twin_instance_id, **kwargs): """ Deletes the digital twin instance identified by the specified OCID. :param str digital_twin_instance_id: (required) The `OCID`__ of digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/delete_digital_twin_instance.py.html>`__ to see an example of how to use delete_digital_twin_instance API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinInstanceId'] resource_path = "/digitalTwinInstances/{digitalTwinInstanceId}" method = "DELETE" operation_name = "delete_digital_twin_instance" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/DeleteDigitalTwinInstance" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"delete_digital_twin_instance got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinInstanceId": digital_twin_instance_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def delete_digital_twin_model(self, digital_twin_model_id, **kwargs): """ Deletes the digital twin model identified by the specified OCID. :param str digital_twin_model_id: (required) The `OCID`__ of digital twin model. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/delete_digital_twin_model.py.html>`__ to see an example of how to use delete_digital_twin_model API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinModelId'] resource_path = "/digitalTwinModels/{digitalTwinModelId}" method = "DELETE" operation_name = "delete_digital_twin_model" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinModel/DeleteDigitalTwinModel" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"delete_digital_twin_model got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinModelId": digital_twin_model_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def delete_digital_twin_relationship(self, digital_twin_relationship_id, **kwargs): """ Deletes the digital twin relationship identified by the specified OCID. :param str digital_twin_relationship_id: (required) The `OCID`__ of digital twin relationship. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/delete_digital_twin_relationship.py.html>`__ to see an example of how to use delete_digital_twin_relationship API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinRelationshipId'] resource_path = "/digitalTwinRelationships/{digitalTwinRelationshipId}" method = "DELETE" operation_name = "delete_digital_twin_relationship" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinRelationship/DeleteDigitalTwinRelationship" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"delete_digital_twin_relationship got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinRelationshipId": digital_twin_relationship_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def delete_iot_domain(self, iot_domain_id, **kwargs): """ Deletes the IoT domain identified by the specified OCID. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/delete_iot_domain.py.html>`__ to see an example of how to use delete_iot_domain API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/iotDomains/{iotDomainId}" method = "DELETE" operation_name = "delete_iot_domain" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/DeleteIotDomain" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"delete_iot_domain got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainId": iot_domain_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def delete_iot_domain_group(self, iot_domain_group_id, **kwargs): """ Deletes the IoT domain group identified by the specified OCID. :param str iot_domain_group_id: (required) The `OCID`__ of an IoT Domain Group. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/delete_iot_domain_group.py.html>`__ to see an example of how to use delete_iot_domain_group API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainGroupId'] resource_path = "/iotDomainGroups/{iotDomainGroupId}" method = "DELETE" operation_name = "delete_iot_domain_group" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/DeleteIotDomainGroup" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"delete_iot_domain_group got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainGroupId": iot_domain_group_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_digital_twin_adapter(self, digital_twin_adapter_id, **kwargs): """ Retrieves the digital twin adapter identified by the specified OCID. :param str digital_twin_adapter_id: (required) The `OCID`__ of the digital twin adapter. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinAdapter` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_digital_twin_adapter.py.html>`__ to see an example of how to use get_digital_twin_adapter API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinAdapterId'] resource_path = "/digitalTwinAdapters/{digitalTwinAdapterId}" method = "GET" operation_name = "get_digital_twin_adapter" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinAdapter/GetDigitalTwinAdapter" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_digital_twin_adapter got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinAdapterId": digital_twin_adapter_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinAdapter", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinAdapter", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_digital_twin_instance(self, digital_twin_instance_id, **kwargs): """ Retrieves the digital twin instance identified by the specified OCID. :param str digital_twin_instance_id: (required) The `OCID`__ of digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinInstance` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_digital_twin_instance.py.html>`__ to see an example of how to use get_digital_twin_instance API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinInstanceId'] resource_path = "/digitalTwinInstances/{digitalTwinInstanceId}" method = "GET" operation_name = "get_digital_twin_instance" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/GetDigitalTwinInstance" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_digital_twin_instance got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinInstanceId": digital_twin_instance_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinInstance", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinInstance", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_digital_twin_instance_content(self, digital_twin_instance_id, **kwargs): """ Retrieves the content associated with a digital twin instance identified by the specified OCID. The content can be retrieved only when a model is associated with the digital twin instance. :param str digital_twin_instance_id: (required) The `OCID`__ of digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param bool should_include_metadata: (optional) If set to true , digital twin instance metadata is included in the response. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type dict(str, object) :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_digital_twin_instance_content.py.html>`__ to see an example of how to use get_digital_twin_instance_content API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinInstanceId'] resource_path = "/digitalTwinInstances/{digitalTwinInstanceId}/content" method = "GET" operation_name = "get_digital_twin_instance_content" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/GetDigitalTwinInstanceContent" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id", "should_include_metadata" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_digital_twin_instance_content got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinInstanceId": digital_twin_instance_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') query_params = { "shouldIncludeMetadata": kwargs.get("should_include_metadata", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json, application/ld+json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, query_params=query_params, header_params=header_params, response_type="dict(str, object)", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, query_params=query_params, header_params=header_params, response_type="dict(str, object)", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_digital_twin_model(self, digital_twin_model_id, **kwargs): """ Retrieves the digital twin model identified by the specified OCID. :param str digital_twin_model_id: (required) The `OCID`__ of digital twin model. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinModel` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_digital_twin_model.py.html>`__ to see an example of how to use get_digital_twin_model API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinModelId'] resource_path = "/digitalTwinModels/{digitalTwinModelId}" method = "GET" operation_name = "get_digital_twin_model" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinModel/GetDigitalTwinModel" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_digital_twin_model got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinModelId": digital_twin_model_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinModel", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinModel", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_digital_twin_model_spec(self, digital_twin_model_id, **kwargs): """ Retrieves the spec of digital twin model identified by the specified OCID. :param str digital_twin_model_id: (required) The `OCID`__ of digital twin model. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type dict(str, object) :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_digital_twin_model_spec.py.html>`__ to see an example of how to use get_digital_twin_model_spec API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinModelId'] resource_path = "/digitalTwinModels/{digitalTwinModelId}/spec" method = "GET" operation_name = "get_digital_twin_model_spec" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinModel/GetDigitalTwinModelSpec" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_digital_twin_model_spec got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinModelId": digital_twin_model_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json, application/ld+json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="dict(str, object)", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="dict(str, object)", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_digital_twin_relationship(self, digital_twin_relationship_id, **kwargs): """ Retrieves the digital twin relationship identified by the specified OCID. :param str digital_twin_relationship_id: (required) The `OCID`__ of digital twin relationship. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinRelationship` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_digital_twin_relationship.py.html>`__ to see an example of how to use get_digital_twin_relationship API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinRelationshipId'] resource_path = "/digitalTwinRelationships/{digitalTwinRelationshipId}" method = "GET" operation_name = "get_digital_twin_relationship" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinRelationship/GetDigitalTwinRelationship" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_digital_twin_relationship got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinRelationshipId": digital_twin_relationship_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinRelationship", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="DigitalTwinRelationship", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_iot_domain(self, iot_domain_id, **kwargs): """ Retrieves the IoT domain identified by the specified OCID. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.IotDomain` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_iot_domain.py.html>`__ to see an example of how to use get_iot_domain API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/iotDomains/{iotDomainId}" method = "GET" operation_name = "get_iot_domain" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/GetIotDomain" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_iot_domain got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainId": iot_domain_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="IotDomain", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="IotDomain", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_iot_domain_group(self, iot_domain_group_id, **kwargs): """ Retrieves the IoT domain group identified by the specified OCID. :param str iot_domain_group_id: (required) The `OCID`__ of an IoT Domain Group. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.IotDomainGroup` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_iot_domain_group.py.html>`__ to see an example of how to use get_iot_domain_group API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainGroupId'] resource_path = "/iotDomainGroups/{iotDomainGroupId}" method = "GET" operation_name = "get_iot_domain_group" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/GetIotDomainGroup" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_iot_domain_group got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainGroupId": iot_domain_group_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="IotDomainGroup", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="IotDomainGroup", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def get_work_request(self, work_request_id, **kwargs): """ Retrieves the status of the work request with the given ID. :param str work_request_id: (required) The `OCID`__ of the asynchronous work request. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.WorkRequest` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/get_work_request.py.html>`__ to see an example of how to use get_work_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['workRequestId'] resource_path = "/workRequests/{workRequestId}" method = "GET" operation_name = "get_work_request" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/WorkRequest/GetWorkRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"get_work_request got unknown kwargs: {extra_kwargs!r}") path_params = { "workRequestId": work_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="WorkRequest", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, response_type="WorkRequest", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def invoke_raw_command(self, digital_twin_instance_id, invoke_raw_command_details, **kwargs): """ Invokes the raw command on the specified digital twin instance. :param str digital_twin_instance_id: (required) The `OCID`__ of digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.InvokeRawCommandDetails invoke_raw_command_details: (required) Details for the raw command invocation. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/invoke_raw_command.py.html>`__ to see an example of how to use invoke_raw_command API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinInstanceId'] resource_path = "/digitalTwinInstances/{digitalTwinInstanceId}/actions/invokeRawCommand" method = "POST" operation_name = "invoke_raw_command" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/InvokeRawCommand" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"invoke_raw_command got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinInstanceId": digital_twin_instance_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=invoke_raw_command_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=invoke_raw_command_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_digital_twin_adapters(self, iot_domain_id, **kwargs): """ Retrieves a list of digital twin adapters within the specified IoT domain. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain in which to list digital twin resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str id: (optional) Filter resources by `OCID`__. Must be a valid OCID of the resource type. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str digital_twin_model_spec_uri: (optional) Filter resources that match the specified URI (DTMI) of the digital twin model. :param str digital_twin_model_id: (optional) Filter resources that match the specified `OCID`__ of the digital twin model. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str display_name: (optional) Filter resources whose display name matches the specified value. :param str lifecycle_state: (optional) Filter resources whose lifecycleState matches the specified value. Allowed values are: "ACTIVE", "DELETED" :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str page: (optional) Page representing the requested page of items. :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. Allowed values are: "timeCreated", "displayName" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinAdapterCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_digital_twin_adapters.py.html>`__ to see an example of how to use list_digital_twin_adapters API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/digitalTwinAdapters" method = "GET" operation_name = "list_digital_twin_adapters" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinAdapter/ListDigitalTwinAdapters" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "id", "digital_twin_model_spec_uri", "digital_twin_model_id", "display_name", "lifecycle_state", "limit", "page", "sort_order", "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_digital_twin_adapters got unknown kwargs: {extra_kwargs!r}") if 'lifecycle_state' in kwargs: lifecycle_state_allowed_values = ["ACTIVE", "DELETED"] if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: raise ValueError( f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated", "displayName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "iotDomainId": iot_domain_id, "id": kwargs.get("id", missing), "digitalTwinModelSpecUri": kwargs.get("digital_twin_model_spec_uri", missing), "digitalTwinModelId": kwargs.get("digital_twin_model_id", missing), "displayName": kwargs.get("display_name", missing), "lifecycleState": kwargs.get("lifecycle_state", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinAdapterCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinAdapterCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_digital_twin_instances(self, iot_domain_id, **kwargs): """ Retrieves a list of digital twin instances within the specified IoT domain. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain in which to list digital twin resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str display_name: (optional) Filter resources whose display name matches the specified value. :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str page: (optional) Page representing the requested page of items. :param str lifecycle_state: (optional) Filter resources whose lifecycleState matches the specified value. Allowed values are: "ACTIVE", "DELETED" :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. Allowed values are: "timeCreated", "displayName" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str digital_twin_model_id: (optional) Filter resources that match the specified `OCID`__ of the digital twin model. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str digital_twin_model_spec_uri: (optional) Filter resources that match the specified URI (DTMI) of the digital twin model. :param str id: (optional) Filter resources by `OCID`__. Must be a valid OCID of the resource type. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinInstanceCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_digital_twin_instances.py.html>`__ to see an example of how to use list_digital_twin_instances API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/digitalTwinInstances" method = "GET" operation_name = "list_digital_twin_instances" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/ListDigitalTwinInstances" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "display_name", "limit", "page", "lifecycle_state", "sort_order", "sort_by", "opc_request_id", "digital_twin_model_id", "digital_twin_model_spec_uri", "id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_digital_twin_instances got unknown kwargs: {extra_kwargs!r}") if 'lifecycle_state' in kwargs: lifecycle_state_allowed_values = ["ACTIVE", "DELETED"] if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: raise ValueError( f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated", "displayName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "displayName": kwargs.get("display_name", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "lifecycleState": kwargs.get("lifecycle_state", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing), "digitalTwinModelId": kwargs.get("digital_twin_model_id", missing), "digitalTwinModelSpecUri": kwargs.get("digital_twin_model_spec_uri", missing), "iotDomainId": iot_domain_id, "id": kwargs.get("id", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinInstanceCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinInstanceCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_digital_twin_models(self, iot_domain_id, **kwargs): """ Retrieves a list of digital twin models within the specified IoT domain. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain in which to list digital twin resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str id: (optional) Filter resources by `OCID`__. Must be a valid OCID of the resource type. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str display_name: (optional) Filter resources whose display name matches the specified value. :param str spec_uri_starts_with: (optional) Filters resources by spec URI prefix. For example, to search all versions of the `dtmi:example:device;1` model, pass the prefix without the version: `dtmi:example:device`. :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str page: (optional) Page representing the requested page of items. :param str lifecycle_state: (optional) Filter resources whose lifecycleState matches the specified value. Allowed values are: "ACTIVE", "DELETED" :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. Allowed values are: "timeCreated", "displayName" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinModelCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_digital_twin_models.py.html>`__ to see an example of how to use list_digital_twin_models API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/digitalTwinModels" method = "GET" operation_name = "list_digital_twin_models" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinModel/ListDigitalTwinModels" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "id", "display_name", "spec_uri_starts_with", "limit", "page", "lifecycle_state", "sort_order", "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_digital_twin_models got unknown kwargs: {extra_kwargs!r}") if 'lifecycle_state' in kwargs: lifecycle_state_allowed_values = ["ACTIVE", "DELETED"] if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: raise ValueError( f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated", "displayName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "id": kwargs.get("id", missing), "iotDomainId": iot_domain_id, "displayName": kwargs.get("display_name", missing), "specUriStartsWith": kwargs.get("spec_uri_starts_with", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "lifecycleState": kwargs.get("lifecycle_state", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinModelCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinModelCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_digital_twin_relationships(self, iot_domain_id, **kwargs): """ Retrieves a list of digital twin relationships within the specified IoT domain. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain in which to list digital twin resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str display_name: (optional) Filter resources whose display name matches the specified value. :param str content_path: (optional) Filters resources that match the content path of the digital twin relationship. :param str source_digital_twin_instance_id: (optional) Filter resources that match the specified `OCID`__ of source digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str target_digital_twin_instance_id: (optional) Filter resources that match the specified `OCID`__ of target digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str lifecycle_state: (optional) Filter resources whose lifecycleState matches the specified value. Allowed values are: "ACTIVE", "DELETED" :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str page: (optional) Page representing the requested page of items. :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. Allowed values are: "timeCreated", "displayName" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str id: (optional) Filter resources by `OCID`__. Must be a valid OCID of the resource type. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinRelationshipCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_digital_twin_relationships.py.html>`__ to see an example of how to use list_digital_twin_relationships API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/digitalTwinRelationships" method = "GET" operation_name = "list_digital_twin_relationships" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinRelationship/ListDigitalTwinRelationships" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "display_name", "content_path", "source_digital_twin_instance_id", "target_digital_twin_instance_id", "lifecycle_state", "limit", "page", "sort_order", "sort_by", "opc_request_id", "id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_digital_twin_relationships got unknown kwargs: {extra_kwargs!r}") if 'lifecycle_state' in kwargs: lifecycle_state_allowed_values = ["ACTIVE", "DELETED"] if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: raise ValueError( f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated", "displayName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "displayName": kwargs.get("display_name", missing), "contentPath": kwargs.get("content_path", missing), "sourceDigitalTwinInstanceId": kwargs.get("source_digital_twin_instance_id", missing), "targetDigitalTwinInstanceId": kwargs.get("target_digital_twin_instance_id", missing), "lifecycleState": kwargs.get("lifecycle_state", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing), "iotDomainId": iot_domain_id, "id": kwargs.get("id", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinRelationshipCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="DigitalTwinRelationshipCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_iot_domain_groups(self, compartment_id, **kwargs): """ Retrieves a list of IoT domain groups within the specified compartment. :param str compartment_id: (required) The `OCID`__ of the compartment in which to list resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str id: (optional) Filter resources by `OCID`__. Must be a valid OCID of the resource type. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str display_name: (optional) Filter resources whose display name matches the specified value. :param str lifecycle_state: (optional) Filter resources whose lifecycleState matches the specified value. Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" :param str type: (optional) Filter resources by type. Valid values are LIGHTWEIGHT or STANDARD. Allowed values are: "STANDARD", "LIGHTWEIGHT" :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str page: (optional) For list pagination: The value of the opc-next-page response header from the previous \"List\" call. For important details on how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. Allowed values are: "timeCreated", "displayName" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.IotDomainGroupCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_iot_domain_groups.py.html>`__ to see an example of how to use list_iot_domain_groups API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['compartmentId'] resource_path = "/iotDomainGroups" method = "GET" operation_name = "list_iot_domain_groups" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/ListIotDomainGroups" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "id", "display_name", "lifecycle_state", "type", "limit", "page", "sort_order", "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_iot_domain_groups got unknown kwargs: {extra_kwargs!r}") if 'lifecycle_state' in kwargs: lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: raise ValueError( f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" ) if 'type' in kwargs: type_allowed_values = ["STANDARD", "LIGHTWEIGHT"] if kwargs['type'] not in type_allowed_values: raise ValueError( f"Invalid value for `type`, must be one of { type_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated", "displayName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "compartmentId": compartment_id, "id": kwargs.get("id", missing), "displayName": kwargs.get("display_name", missing), "lifecycleState": kwargs.get("lifecycle_state", missing), "type": kwargs.get("type", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="IotDomainGroupCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="IotDomainGroupCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_iot_domains(self, compartment_id, **kwargs): """ Retrieves a list of IoT domains within the specified compartment. :param str compartment_id: (required) The `OCID`__ of the compartment in which to list resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str id: (optional) Filter resources by `OCID`__. Must be a valid OCID of the resource type. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str iot_domain_group_id: (optional) Filter resources that match the specified `OCID`__ of the IoT domain group. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str display_name: (optional) Filter resources whose display name matches the specified value. :param str lifecycle_state: (optional) Filter resources whose lifecycleState matches the specified value. Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str page: (optional) For list pagination: The value of the opc-next-page response header from the previous \"List\" call. For important details on how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. Allowed values are: "timeCreated", "displayName" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.IotDomainCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_iot_domains.py.html>`__ to see an example of how to use list_iot_domains API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['compartmentId'] resource_path = "/iotDomains" method = "GET" operation_name = "list_iot_domains" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/ListIotDomains" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "id", "iot_domain_group_id", "display_name", "lifecycle_state", "limit", "page", "sort_order", "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_iot_domains got unknown kwargs: {extra_kwargs!r}") if 'lifecycle_state' in kwargs: lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: raise ValueError( f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated", "displayName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "compartmentId": compartment_id, "id": kwargs.get("id", missing), "iotDomainGroupId": kwargs.get("iot_domain_group_id", missing), "displayName": kwargs.get("display_name", missing), "lifecycleState": kwargs.get("lifecycle_state", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="IotDomainCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="IotDomainCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_work_request_errors(self, work_request_id, **kwargs): """ Lists errors associated with the specified work request. :param str work_request_id: (required) The `OCID`__ of the asynchronous work request. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str page: (optional) For list pagination: The value of the opc-next-page response header from the previous \"List\" call. For important details on how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str sort_by: (optional) The field to sort by. Only one sort order can be specified. The default order for `timeCreated` is descending. Allowed values are: "timeCreated" :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.WorkRequestErrorCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_work_request_errors.py.html>`__ to see an example of how to use list_work_request_errors API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['workRequestId'] resource_path = "/workRequests/{workRequestId}/errors" method = "GET" operation_name = "list_work_request_errors" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/WorkRequest/ListWorkRequestErrors" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id", "page", "limit", "sort_by", "sort_order" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_work_request_errors got unknown kwargs: {extra_kwargs!r}") path_params = { "workRequestId": work_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) query_params = { "page": kwargs.get("page", missing), "limit": kwargs.get("limit", missing), "sortBy": kwargs.get("sort_by", missing), "sortOrder": kwargs.get("sort_order", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, query_params=query_params, header_params=header_params, response_type="WorkRequestErrorCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, query_params=query_params, header_params=header_params, response_type="WorkRequestErrorCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_work_request_logs(self, work_request_id, **kwargs): """ Lists the logs associated with the specified work request. :param str work_request_id: (required) The `OCID`__ of the asynchronous work request. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str page: (optional) For list pagination: The value of the opc-next-page response header from the previous \"List\" call. For important details on how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str sort_by: (optional) The field to sort by. Only one sort order can be specified. The default order for `timeCreated` is descending. Allowed values are: "timeCreated" :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.WorkRequestLogEntryCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_work_request_logs.py.html>`__ to see an example of how to use list_work_request_logs API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['workRequestId'] resource_path = "/workRequests/{workRequestId}/logs" method = "GET" operation_name = "list_work_request_logs" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/WorkRequest/ListWorkRequestLogs" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "opc_request_id", "page", "limit", "sort_by", "sort_order" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_work_request_logs got unknown kwargs: {extra_kwargs!r}") path_params = { "workRequestId": work_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') if 'sort_by' in kwargs: sort_by_allowed_values = ["timeCreated"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) query_params = { "page": kwargs.get("page", missing), "limit": kwargs.get("limit", missing), "sortBy": kwargs.get("sort_by", missing), "sortOrder": kwargs.get("sort_order", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, query_params=query_params, header_params=header_params, response_type="WorkRequestLogEntryCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, query_params=query_params, header_params=header_params, response_type="WorkRequestLogEntryCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def list_work_requests(self, compartment_id, **kwargs): """ Lists work requests in the specified compartment. :param str compartment_id: (required) The `OCID`__ of the compartment in which to list resources. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str id: (optional) The `OCID`__ of the asynchronous work request. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str status: (optional) A filter to return only the resources that match the given lifecycle state. Allowed values are: "ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED" :param str resource_id: (optional) The `OCID`__ of the resource affected by the work request. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param str page: (optional) For list pagination: The value of the opc-next-page response header from the previous \"List\" call. For important details on how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param int limit: (optional) For list pagination. The maximum number of results per page, or items to return in a paginated \"List\" call. For important details about how pagination works, see `List Pagination`__. __ https://docs.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine :param str sort_order: (optional) Specifies sort order to use, either ASC (ascending) or DESC (descending). Allowed values are: "ASC", "DESC" :param str sort_by: (optional) The field to sort by. Only one sort order can be specified. Default order for `timeAccepted` is descending. Allowed values are: "timeAccepted" :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.WorkRequestSummaryCollection` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/list_work_requests.py.html>`__ to see an example of how to use list_work_requests API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['compartmentId'] resource_path = "/workRequests" method = "GET" operation_name = "list_work_requests" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/WorkRequest/ListWorkRequests" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "id", "status", "resource_id", "opc_request_id", "page", "limit", "sort_order", "sort_by" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_work_requests got unknown kwargs: {extra_kwargs!r}") if 'status' in kwargs: status_allowed_values = ["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED"] if kwargs['status'] not in status_allowed_values: raise ValueError( f"Invalid value for `status`, must be one of { status_allowed_values }" ) if 'sort_order' in kwargs: sort_order_allowed_values = ["ASC", "DESC"] if kwargs['sort_order'] not in sort_order_allowed_values: raise ValueError( f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" ) if 'sort_by' in kwargs: sort_by_allowed_values = ["timeAccepted"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { "compartmentId": compartment_id, "id": kwargs.get("id", missing), "status": kwargs.get("status", missing), "resourceId": kwargs.get("resource_id", missing), "page": kwargs.get("page", missing), "limit": kwargs.get("limit", missing), "sortOrder": kwargs.get("sort_order", missing), "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="WorkRequestSummaryCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, query_params=query_params, header_params=header_params, response_type="WorkRequestSummaryCollection", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def update_digital_twin_adapter(self, digital_twin_adapter_id, update_digital_twin_adapter_details, **kwargs): """ Updates the details of digital twin adapter identified by the specified OCID. :param str digital_twin_adapter_id: (required) The `OCID`__ of the digital twin adapter. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.UpdateDigitalTwinAdapterDetails update_digital_twin_adapter_details: (required) The digital twin adapter details to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinAdapter` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/update_digital_twin_adapter.py.html>`__ to see an example of how to use update_digital_twin_adapter API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinAdapterId'] resource_path = "/digitalTwinAdapters/{digitalTwinAdapterId}" method = "PUT" operation_name = "update_digital_twin_adapter" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinAdapter/UpdateDigitalTwinAdapter" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"update_digital_twin_adapter got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinAdapterId": digital_twin_adapter_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_adapter_details, response_type="DigitalTwinAdapter", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_adapter_details, response_type="DigitalTwinAdapter", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def update_digital_twin_instance(self, digital_twin_instance_id, update_digital_twin_instance_details, **kwargs): """ Updates the details of digital twin instance identified by the specified OCID. :param str digital_twin_instance_id: (required) The `OCID`__ of digital twin instance. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.UpdateDigitalTwinInstanceDetails update_digital_twin_instance_details: (required) The digital twin instance details to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinInstance` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/update_digital_twin_instance.py.html>`__ to see an example of how to use update_digital_twin_instance API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinInstanceId'] resource_path = "/digitalTwinInstances/{digitalTwinInstanceId}" method = "PUT" operation_name = "update_digital_twin_instance" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinInstance/UpdateDigitalTwinInstance" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"update_digital_twin_instance got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinInstanceId": digital_twin_instance_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_instance_details, response_type="DigitalTwinInstance", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_instance_details, response_type="DigitalTwinInstance", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def update_digital_twin_model(self, digital_twin_model_id, update_digital_twin_model_details, **kwargs): """ Updates the details of the digital twin model identified by the specified OCID. :param str digital_twin_model_id: (required) The `OCID`__ of digital twin model. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.UpdateDigitalTwinModelDetails update_digital_twin_model_details: (required) The digital twin model details to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinModel` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/update_digital_twin_model.py.html>`__ to see an example of how to use update_digital_twin_model API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinModelId'] resource_path = "/digitalTwinModels/{digitalTwinModelId}" method = "PUT" operation_name = "update_digital_twin_model" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinModel/UpdateDigitalTwinModel" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"update_digital_twin_model got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinModelId": digital_twin_model_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_model_details, response_type="DigitalTwinModel", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_model_details, response_type="DigitalTwinModel", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def update_digital_twin_relationship(self, digital_twin_relationship_id, update_digital_twin_relationship_details, **kwargs): """ Updates the details of digital twin relationship identified by the specified OCID. :param str digital_twin_relationship_id: (required) The `OCID`__ of digital twin relationship. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.UpdateDigitalTwinRelationshipDetails update_digital_twin_relationship_details: (required) The digital twin relationship details to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.iot.models.DigitalTwinRelationship` :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/update_digital_twin_relationship.py.html>`__ to see an example of how to use update_digital_twin_relationship API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['digitalTwinRelationshipId'] resource_path = "/digitalTwinRelationships/{digitalTwinRelationshipId}" method = "PUT" operation_name = "update_digital_twin_relationship" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/DigitalTwinRelationship/UpdateDigitalTwinRelationship" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"update_digital_twin_relationship got unknown kwargs: {extra_kwargs!r}") path_params = { "digitalTwinRelationshipId": digital_twin_relationship_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_relationship_details, response_type="DigitalTwinRelationship", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_digital_twin_relationship_details, response_type="DigitalTwinRelationship", allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def update_iot_domain(self, iot_domain_id, update_iot_domain_details, **kwargs): """ Updates the details of IoT domain identified by the specified OCID. :param str iot_domain_id: (required) The `OCID`__ of the IoT domain. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.UpdateIotDomainDetails update_iot_domain_details: (required) The IoT domain details to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/update_iot_domain.py.html>`__ to see an example of how to use update_iot_domain API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainId'] resource_path = "/iotDomains/{iotDomainId}" method = "PUT" operation_name = "update_iot_domain" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomain/UpdateIotDomain" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"update_iot_domain got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainId": iot_domain_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_iot_domain_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_iot_domain_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) def update_iot_domain_group(self, iot_domain_group_id, update_iot_domain_group_details, **kwargs): """ Updates the details of IoT domain group identified by the specified OCID. :param str iot_domain_group_id: (required) The `OCID`__ of an IoT Domain Group. __ https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param oci.iot.models.UpdateIotDomainGroupDetails update_iot_domain_group_details: (required) The IoT domain group details to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__. To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings :param bool enable_strict_url_encoding: (optional) enable_strict_url_encoding is a boolean to indicate whether or not this request should enable strict url encoding for path params. By default, strict url encoding for path params is disabled :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: Click `here <https://docs.oracle.com/en-us/iaas/tools/python-sdk-examples/latest/iot/update_iot_domain_group.py.html>`__ to see an example of how to use update_iot_domain_group API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['iotDomainGroupId'] resource_path = "/iotDomainGroups/{iotDomainGroupId}" method = "PUT" operation_name = "update_iot_domain_group" api_reference_link = "https://docs.oracle.com/iaas/api/#/en/iot/20250531/IotDomainGroup/UpdateIotDomainGroup" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "enable_strict_url_encoding", "retry_strategy", "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"update_iot_domain_group got unknown kwargs: {extra_kwargs!r}") path_params = { "iotDomainGroupId": iot_domain_group_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} for (k, v) in six.iteritems(path_params): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy ) if retry_strategy is None: retry_strategy = retry.DEFAULT_RETRY_STRATEGY if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_iot_domain_group_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) else: return self.base_client.call_api( resource_path=resource_path, method=method, path_params=path_params, header_params=header_params, body=update_iot_domain_group_details, allow_control_chars=kwargs.get('allow_control_chars'), enable_strict_url_encoding=kwargs.get('enable_strict_url_encoding'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments)
| ver. 1.4 |
Github
|
.
| PHP 8.2.32 | Generation time: 0.07 |
proxy
|
phpinfo
|
Settings