Skip to content

provision_device

provision_device(
    name: DeviceName,
    *,
    config_overrides: Optional[PanoramaClientConfig] = None,
    description: Optional[Description] = None,
    tags: Optional[TagMap] = None,
    networking_configuration: Optional[NetworkPayload] = None,
) -> ProvisionDeviceResponse

Creates a device and returns a configuration archive. The configuration archive is a ZIP file that contains a provisioning certificate that is valid for 5 minutes. Name the configuration archive certificates-omni_device-name.zip and transfer it to the device within 5 minutes. Use the included USB storage device and connect it to the USB 3.0 port next to the HDMI output.

Parameters:

Raises:

Source code in docs_src/capo_panorama/_services/panorama.py
def provision_device(
    self,
    name: "capo_panorama.types.device_name.DeviceName",
    *,
    config_overrides: Optional[PanoramaClientConfig] = None,
    description: Optional["capo_panorama.types.description.Description"] = None,
    tags: Optional["capo_panorama.types.tag_map.TagMap"] = None,
    networking_configuration: Optional[
        "capo_panorama.types.network_payload.NetworkPayload"
    ] = None,
) -> "capo_panorama.types.provision_device_response.ProvisionDeviceResponse":
    """<p>Creates a device and returns a configuration archive. The configuration archive is a ZIP file that contains a provisioning certificate that is valid for 5 minutes. Name the configuration archive <code>certificates-omni_<i>device-name</i>.zip</code> and transfer it to the device within 5 minutes. Use the included USB storage device and connect it to the USB 3.0 port next to the HDMI output.</p>

    Args:
        name: <p>A name for the device.</p>
        description: <p>A description for the device.</p>
        tags: <p>Tags for the device.</p>
        networking_configuration: <p>A networking configuration for the device.</p>

    Raises:
        capo_panorama.errors.access_denied_exception.AccessDeniedException: <p>The requestor does not have permission to access the target action or resource.</p>
        capo_panorama.errors.conflict_exception.ConflictException: <p>The target resource is in use.</p>
        capo_panorama.errors.internal_server_exception.InternalServerException: <p>An internal error occurred.</p>
        capo_panorama.errors.service_quota_exceeded_exception.ServiceQuotaExceededException: <p>The request would cause a limit to be exceeded.</p>
        capo_panorama.errors.validation_exception.ValidationException: <p>The request contains an invalid parameter value.</p>
        capo_panorama.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_panorama.types.provision_device_request.ProvisionDeviceRequest]",
    ) -> OperationResponse[
        "capo_panorama.types.provision_device_response.ProvisionDeviceResponse"
    ]:
        import capo_panorama._operations.omni_cloud_service_lambda.provision_device

        output, http_response = (
            capo_panorama._operations.omni_cloud_service_lambda.provision_device.provision_device(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ProvisionDevice")
    )
    input_: capo_panorama.types.provision_device_request.ProvisionDeviceRequest = {
        "name": name
    }
    if description is not None:
        input_["description"] = description
    if tags is not None:
        input_["tags"] = tags
    if networking_configuration is not None:
        input_["networking_configuration"] = networking_configuration

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output