code: static ConfirmSubscriptionResult confirmSubscription(HttpClient httpClient, String subscribeUrl) {
          try {
              HttpGet request = new HttpGet(subscribeUrl);
              HttpResponse response = httpClient.execute(request);
              if (ApacheUtils.isRequestSuccessful(response)) {
                  return new StaxResponseHandler<ConfirmSubscriptionResult>(ConfirmSubscriptionResultStaxUnmarshaller.getInstance())
                      .handle(ApacheUtils.createResponse(null, request, response, null)).getResult();
              } else {
                  throw new HttpException("Could not confirm subscription", response);
              }
          } catch (Exception e) {
              throw new SdkClientException(e);
          }
      }
docs: Confirms a subscription by visiting the provided URL.
  
  @param httpClient Client to use to visit URL.
  @param subscribeUrl Confirmation URL.
  @return Result of subscription confirmation.