src/main/java/com/squareup/connect/api/CustomersApi.java
public CompleteResponse<ListCustomersResponse>listCustomersWithHttpInfo(String cursor, String sortField, String sortOrder) throws ApiException {
    Object localVarPostBody = null;
    
    // create path and map variables
    String localVarPath = "/v2/customers";

    // query params
    List<Pair> localVarQueryParams = new ArrayList<Pair>();
    Map<String, String> localVarHeaderParams = new HashMap<String, String>();
    Map<String, Object> localVarFormParams = new HashMap<String, Object>();
    localVarHeaderParams.put("Square-Version", "2019-11-20");
    localVarQueryParams.addAll(apiClient.parameterToPairs("", "cursor", cursor));
    localVarQueryParams.addAll(apiClient.parameterToPairs("", "sort_field", sortField));
    localVarQueryParams.addAll(apiClient.parameterToPairs("", "sort_order", sortOrder));

    
    
    final String[] localVarAccepts = {
      "application/json"
    };
    final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);

    final String[] localVarContentTypes = {
      "application/json"
    };
    final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);

    String[] localVarAuthNames = new String[] { "oauth2" };

    GenericType<ListCustomersResponse> localVarReturnType = new GenericType<ListCustomersResponse>() {};
    return (CompleteResponse<ListCustomersResponse>)apiClient.invokeAPI(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
/**
   * ListCustomers
   * Lists a business&#39;s customers.
   * @param cursor A pagination cursor returned by a previous call to this endpoint. Provide this to retrieve the next set of results for your original query.  See the [Pagination guide](https://developer.squareup.com/docs/working-with-apis/pagination) for more information. (optional)
   * @param sortField Indicates how Customers should be sorted.  Default: &#x60;DEFAULT&#x60;. (optional)
   * @param sortOrder Indicates whether Customers should be sorted in ascending (&#x60;ASC&#x60;) or descending (&#x60;DESC&#x60;) order.  Default: &#x60;ASC&#x60;. (optional)
   * @return CompleteResponse<ListCustomersResponse>
   * @throws ApiException if fails to make API call
   */
ListCustomers
Lists a business's customers.
@param cursor A pagination cursor returned by a previous call to this endpoint. Provide this to retrieve the next set of results for your original query.  See the [Pagination guide] for more information. (optional)
@param sortField Indicates how Customers should be sorted.  Default: `DEFAULT`. (optional)
@param sortOrder Indicates whether Customers should be sorted in ascending (`ASC`) or descending (`DESC`) order.  Default: `ASC`. (optional)
@return CompleteResponse
@throws ApiException if fails to make API call
ListCustomers Lists a business ' s customers . @param cursor A pagination cursor returned by a previous call to this endpoint . Provide this to retrieve the next set of results for your original query . See the [ Pagination guide ] for more information . ( optional ) @param sortField Indicates how Customers should be sorted . Default : ` DEFAULT ` . ( optional ) @param sortOrder Indicates whether Customers should be sorted in ascending ( ` ASC ` ) or descending ( ` DESC ` ) order . Default : ` ASC ` . ( optional ) @return CompleteResponse @throws ApiException if fails to make API call
public CompleteResponse<ListCustomersResponse>listCustomersWithHttpInfo(String cursor, String sortField, String sortOrder) throws ApiException {
    Object localVarPostBody = null;
    String localVarPath = "/v2/customers";
    List<Pair> localVarQueryParams = new ArrayList<Pair>();
    Map<String, String> localVarHeaderParams = new HashMap<String, String>();
    Map<String, Object> localVarFormParams = new HashMap<String, Object>();
    localVarHeaderParams.put("Square-Version", "2019-11-20");
    localVarQueryParams.addAll(apiClient.parameterToPairs("", "cursor", cursor));
    localVarQueryParams.addAll(apiClient.parameterToPairs("", "sort_field", sortField));
    localVarQueryParams.addAll(apiClient.parameterToPairs("", "sort_order", sortOrder));
    final String[] localVarAccepts = {
      "application/json"
    };
    final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
    final String[] localVarContentTypes = {
      "application/json"
    };
    final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
    String[] localVarAuthNames = new String[] { "oauth2" };
    GenericType<ListCustomersResponse> localVarReturnType = new GenericType<ListCustomersResponse>() {};
    return (CompleteResponse<ListCustomersResponse>)apiClient.invokeAPI(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
public CompleteResponse < ListCustomersResponse > listCustomersWithHttpInfo ( String cursor , String sortField , String sortOrder ) throws ApiException { Object localVarPostBody = null ; String localVarPath = "/v2/customers" ; List < Pair > localVarQueryParams = new ArrayList < Pair > ( ) ; Map < String , String > localVarHeaderParams = new HashMap < String , String > ( ) ; Map < String , Object > localVarFormParams = new HashMap < String , Object > ( ) ; localVarHeaderParams . put ( "Square-Version" , "2019-11-20" ) ; localVarQueryParams . addAll ( apiClient . parameterToPairs ( "" , "cursor" , cursor ) ) ; localVarQueryParams . addAll ( apiClient . parameterToPairs ( "" , "sort_field" , sortField ) ) ; localVarQueryParams . addAll ( apiClient . parameterToPairs ( "" , "sort_order" , sortOrder ) ) ; final String [ ] localVarAccepts = { "application/json" } ; final String localVarAccept = apiClient . selectHeaderAccept ( localVarAccepts ) ; final String [ ] localVarContentTypes = { "application/json" } ; final String localVarContentType = apiClient . selectHeaderContentType ( localVarContentTypes ) ; String [ ] localVarAuthNames = new String [ ] { "oauth2" } ; GenericType < ListCustomersResponse > localVarReturnType = new GenericType < ListCustomersResponse > ( ) { } ; return ( CompleteResponse < ListCustomersResponse > ) apiClient . invokeAPI ( localVarPath , "GET" , localVarQueryParams , localVarPostBody , localVarHeaderParams , localVarFormParams , localVarAccept , localVarContentType , localVarAuthNames , localVarReturnType ) ; }
ListCustomers
 Lists a business&#39;s customers.
ListCustomers Lists a business&#39 ; s customers .
// create path and map variables // query params