java.lang.Object
org.opensearch.client.opensearch.generic.Requests

public final class Requests extends Object
Helper class to construct requests instances
  • Method Details

    • builder

      public static Requests.JsonBodyBuilder builder()
      Creates a new builder for requests with JSON body
      Returns:
      a new builder for requests with JSON body
    • create

      public static Request create(String method, String endpoint, Collection<Map.Entry<String,String>> headers, Map<String,String> parameters, @Nullable Body body)
      Create request instance
      Parameters:
      method - the HTTP method
      endpoint - the path of the request (without scheme, host, port, or prefix)
      headers - list of headers
      parameters - query parameters
      body - optional body
      Returns:
      request instance