Skip to content

describe_product_as_admin async

describe_product_as_admin(
    *,
    config_overrides: Optional[AsyncServiceCatalogClientConfig] = None,
    accept_language: Optional[AcceptLanguage] = None,
    id: Optional[Id] = None,
    name: Optional[ProductViewName] = None,
    source_portfolio_id: Optional[Id] = None,
) -> DescribeProductAsAdminOutput

Gets information about the specified product. This operation is run with administrator access.

Parameters:

  • accept_language (Optional[AcceptLanguage], default: None ) –

    The language code.

    • jp - Japanese

    • zh - Chinese

  • id (Optional[Id], default: None ) –

    The product identifier.

  • name (Optional[ProductViewName], default: None ) –

    The product name.

  • source_portfolio_id (Optional[Id], default: None ) –

    The unique identifier of the shared portfolio that the specified product is associated with.

    You can provide this parameter to retrieve the shared TagOptions associated with the product. If this parameter is provided and if TagOptions sharing is enabled in the portfolio share, the API returns both local and shared TagOptions associated with the product. Otherwise only local TagOptions will be returned.

Raises:

Source code in docs_src/capo_service_catalog/_services/async_service_catalog.py
async def describe_product_as_admin(
    self,
    *,
    config_overrides: Optional[AsyncServiceCatalogClientConfig] = None,
    accept_language: Optional[
        "capo_service_catalog.types.accept_language.AcceptLanguage"
    ] = None,
    id: Optional["capo_service_catalog.types.id.Id"] = None,
    name: Optional[
        "capo_service_catalog.types.product_view_name.ProductViewName"
    ] = None,
    source_portfolio_id: Optional["capo_service_catalog.types.id.Id"] = None,
) -> "capo_service_catalog.types.describe_product_as_admin_output.DescribeProductAsAdminOutput":
    """<p>Gets information about the specified product. This operation is run with administrator access.</p>

    Args:
        accept_language: <p>The language code.</p> <ul> <li> <p> <code>jp</code> - Japanese</p> </li> <li> <p> <code>zh</code> - Chinese</p> </li> </ul>
        id: <p>The product identifier.</p>
        name: <p>The product name.</p>
        source_portfolio_id: <p>The unique identifier of the shared portfolio that the specified product is associated with.</p> <p>You can provide this parameter to retrieve the shared TagOptions associated with the product. If this parameter is provided and if TagOptions sharing is enabled in the portfolio share, the API returns both local and shared TagOptions associated with the product. Otherwise only local TagOptions will be returned. </p>

    Raises:
        capo_service_catalog.errors.invalid_parameters_exception.InvalidParametersException: <p>One or more parameters provided to the operation are not valid.</p>
        capo_service_catalog.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource was not found.</p>
        capo_service_catalog.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_service_catalog.types.describe_product_as_admin_input.DescribeProductAsAdminInput]",
    ) -> AsyncOperationResponse[
        "capo_service_catalog.types.describe_product_as_admin_output.DescribeProductAsAdminOutput"
    ]:
        import capo_service_catalog._operations.aws242_service_catalog_service.describe_product_as_admin

        (
            output,
            http_response,
        ) = await capo_service_catalog._operations.aws242_service_catalog_service.describe_product_as_admin.async_describe_product_as_admin(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DescribeProductAsAdmin")
    )
    input_: capo_service_catalog.types.describe_product_as_admin_input.DescribeProductAsAdminInput = {}
    if accept_language is not None:
        input_["accept_language"] = accept_language
    if id is not None:
        input_["id"] = id
    if name is not None:
        input_["name"] = name
    if source_portfolio_id is not None:
        input_["source_portfolio_id"] = source_portfolio_id

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