Use DeleteEventTracker with an AWS SDK or command line tool - AWS SDK Code Examples

There are more AWS SDK examples available in the AWS Doc SDK Examples GitHub repo.

Use DeleteEventTracker with an AWS SDK or command line tool

The following code example shows how to use DeleteEventTracker.

Java
SDK for Java 2.x
Note

There's more on GitHub. Find the complete example and learn how to set up and run in the AWS Code Examples Repository.

public static void deleteEventTracker(PersonalizeClient personalizeClient, String eventTrackerArn) { try { DeleteEventTrackerRequest deleteEventTrackerRequest = DeleteEventTrackerRequest.builder() .eventTrackerArn(eventTrackerArn) .build(); int status = personalizeClient.deleteEventTracker(deleteEventTrackerRequest).sdkHttpResponse().statusCode(); System.out.println("Status code:" + status); } catch (PersonalizeException e) { System.err.println(e.awsErrorDetails().errorMessage()); System.exit(1); } }