code: public static int checkAction(@Nonnull org.dasein.cloud.digitalocean.DigitalOcean provider, String actionUrl) throws CloudException, InternalException {
          if( logger.isTraceEnabled() ) {
              logger.trace("ENTER - " + DigitalOceanModelFactory.class.getName() + ".checkAction(" + provider.getCloudName() + ")");
          }
  
          String token = (String) provider.getContext().getConfigurationValue("token");
  
          try {
              return sendRequest(provider, RESTMethod.HEAD, token,  getApiUrl(provider) + "v2/" + actionUrl, null).getStatusLine().getStatusCode();
          } finally {
              if( logger.isTraceEnabled() ) {
                  logger.trace("EXIT - " + DigitalOceanModelFactory.class.getName() + ".checkAction(" + provider.getCloudName() + ")");
              }
          }
      }
docs: Return HTTP status code for an action request sent via HEAD method
  @param provider
  @param actionUrl
  @return status code
  @throws InternalException
  @throws CloudException