Skip to content

create_connect_client_add_in async

create_connect_client_add_in(
    resource_id: DirectoryId,
    name: AddInName,
    url: AddInUrl,
    *,
    config_overrides: Optional[AsyncWorkSpacesClientConfig] = None,
) -> CreateConnectClientAddInResult

Creates a client-add-in for Connect Customer within a directory. You can create only one Connect Customer client add-in within a directory.

This client add-in allows WorkSpaces users to seamlessly connect to Connect Customer.

Parameters:

  • resource_id (DirectoryId) –

    The directory identifier for which to configure the client add-in.

  • name (AddInName) –

    The name of the client add-in.

  • url (AddInUrl) –

    The endpoint URL of the Connect Customer client add-in.

Raises:

Source code in docs_src/capo_workspaces/_services/async_work_spaces.py
async def create_connect_client_add_in(
    self,
    resource_id: "capo_workspaces.types.directory_id.DirectoryId",
    name: "capo_workspaces.types.add_in_name.AddInName",
    url: "capo_workspaces.types.add_in_url.AddInUrl",
    *,
    config_overrides: Optional[AsyncWorkSpacesClientConfig] = None,
) -> "capo_workspaces.types.create_connect_client_add_in_result.CreateConnectClientAddInResult":
    """<p>Creates a client-add-in for Connect Customer within a directory. You can create only one Connect Customer client add-in within a directory.</p> <p>This client add-in allows WorkSpaces users to seamlessly connect to Connect Customer.</p>

    Args:
        resource_id: <p>The directory identifier for which to configure the client add-in.</p>
        name: <p>The name of the client add-in.</p>
        url: <p>The endpoint URL of the Connect Customer client add-in.</p>

    Raises:
        capo_workspaces.errors.access_denied_exception.AccessDeniedException: <p>The user is not authorized to access a resource.</p>
        capo_workspaces.errors.invalid_parameter_values_exception.InvalidParameterValuesException: <p>One or more parameter values are not valid.</p>
        capo_workspaces.errors.resource_already_exists_exception.ResourceAlreadyExistsException: <p>The specified resource already exists.</p>
        capo_workspaces.errors.resource_creation_failed_exception.ResourceCreationFailedException: <p>The resource could not be created.</p>
        capo_workspaces.errors.resource_not_found_exception.ResourceNotFoundException: <p>The resource could not be found.</p>
        capo_workspaces.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_workspaces.types.create_connect_client_add_in_request.CreateConnectClientAddInRequest]",
    ) -> AsyncOperationResponse[
        "capo_workspaces.types.create_connect_client_add_in_result.CreateConnectClientAddInResult"
    ]:
        import capo_workspaces._operations.workspaces_service.create_connect_client_add_in

        (
            output,
            http_response,
        ) = await capo_workspaces._operations.workspaces_service.create_connect_client_add_in.async_create_connect_client_add_in(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("CreateConnectClientAddIn")
    )
    input_: capo_workspaces.types.create_connect_client_add_in_request.CreateConnectClientAddInRequest = {
        "resource_id": resource_id,
        "name": name,
        "url": url,
    }

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output