Skip to content

put_identity_provider_config

put_identity_provider_config(
    app_name: AppName,
    identity_provider_name: IdentityProviderName,
    identity_provider_config: IdentityProviderConfigRequest,
    *,
    config_overrides: Optional[AmplifyGen3ClientConfig] = None,
    client_token: Optional[ClientToken] = None,
) -> PutIdentityProviderConfigResponse

Updates the identity provider configuration for a Gen 3 app.

Parameters:

  • app_name (AppName) –

    The name of the app.

  • identity_provider_name (IdentityProviderName) –

    The name of the identity provider.

  • identity_provider_config (IdentityProviderConfigRequest) –

    The identity provider configuration.

  • client_token (Optional[ClientToken], default: None ) –

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.

Raises:

Source code in docs_src/capo_amplifygen3/_services/amplify_gen3.py
def put_identity_provider_config(
    self,
    app_name: "capo_amplifygen3.types.app_name.AppName",
    identity_provider_name: "capo_amplifygen3.types.identity_provider_name.IdentityProviderName",
    identity_provider_config: "capo_amplifygen3.types.identity_provider_config_request.IdentityProviderConfigRequest",
    *,
    config_overrides: Optional[AmplifyGen3ClientConfig] = None,
    client_token: Optional[
        "capo_amplifygen3.types.client_token.ClientToken"
    ] = None,
) -> "capo_amplifygen3.types.put_identity_provider_config_response.PutIdentityProviderConfigResponse":
    """<p>Updates the identity provider configuration for a Gen 3 app.</p>

    Args:
        app_name: <p>The name of the app.</p>
        identity_provider_name: <p>The name of the identity provider.</p>
        identity_provider_config: <p>The identity provider configuration.</p>
        client_token: <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>

    Raises:
        capo_amplifygen3.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient permissions to perform this action.</p>
        capo_amplifygen3.errors.conflict_exception.ConflictException: <p>The request conflicts with the current state of the resource.</p>
        capo_amplifygen3.errors.internal_server_exception.InternalServerException: <p>An internal error occurred. Retry the request.</p>
        capo_amplifygen3.errors.resource_not_found_exception.ResourceNotFoundException: <p>The requested resource was not found.</p>
        capo_amplifygen3.errors.throttling_exception.ThrottlingException: <p>The request was denied because the request rate exceeds the allowed limit.</p>
        capo_amplifygen3.errors.validation_exception.ValidationException: <p>The request contains invalid parameters or is otherwise malformed.</p>
        capo_amplifygen3.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_amplifygen3.types.put_identity_provider_config_request.PutIdentityProviderConfigRequest]",
    ) -> OperationResponse[
        "capo_amplifygen3.types.put_identity_provider_config_response.PutIdentityProviderConfigResponse"
    ]:
        import capo_amplifygen3._operations.omega.put_identity_provider_config

        output, http_response = (
            capo_amplifygen3._operations.omega.put_identity_provider_config.put_identity_provider_config(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_amplifygen3.types.put_identity_provider_config_request.PutIdentityProviderConfigRequest",
    ) -> dict[str, Any]:
        import capo_amplifygen3.types.put_identity_provider_config_request

        return capo_amplifygen3.types.put_identity_provider_config_request.redact_sensitive(
            input_
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging("PutIdentityProviderConfig", redact_input=_redact_input),
    )
    input_: capo_amplifygen3.types.put_identity_provider_config_request.PutIdentityProviderConfigRequest = {
        "app_name": app_name,
        "identity_provider_name": identity_provider_name,
        "identity_provider_config": identity_provider_config,
    }
    if client_token is not None:
        input_["client_token"] = client_token

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