Search in sources :

Example 1 with DeleteIdentityPoolRequest

use of software.amazon.awssdk.services.cognitoidentity.model.DeleteIdentityPoolRequest in project aws-doc-sdk-examples by awsdocs.

the class DeleteIdentityPool method deleteIdPool.

// snippet-start:[cognito.java2.deleteidpool.main]
public static void deleteIdPool(CognitoIdentityClient cognitoIdClient, String identityPoold) {
    try {
        DeleteIdentityPoolRequest identityPoolRequest = DeleteIdentityPoolRequest.builder().identityPoolId(identityPoold).build();
        cognitoIdClient.deleteIdentityPool(identityPoolRequest);
        System.out.println("Done");
    } catch (AwsServiceException e) {
        System.err.println(e.awsErrorDetails().errorMessage());
        System.exit(1);
    }
}
Also used : DeleteIdentityPoolRequest(software.amazon.awssdk.services.cognitoidentity.model.DeleteIdentityPoolRequest) AwsServiceException(software.amazon.awssdk.awscore.exception.AwsServiceException)

Aggregations

AwsServiceException (software.amazon.awssdk.awscore.exception.AwsServiceException)1 DeleteIdentityPoolRequest (software.amazon.awssdk.services.cognitoidentity.model.DeleteIdentityPoolRequest)1