src/main/java/com/squareup/connect/api/ApplePayApi.java
public CompleteResponse<RegisterDomainResponse>registerDomainWithHttpInfo(RegisterDomainRequest body) throws ApiException {
    Object localVarPostBody = body;
    
    // verify the required parameter 'body' is set
    if (body == null) {
      throw new ApiException(400, "Missing the required parameter 'body' when calling registerDomain");
    }
    
    // create path and map variables
    String localVarPath = "/v2/apple-pay/domains";

    // 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");

    
    
    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<RegisterDomainResponse> localVarReturnType = new GenericType<RegisterDomainResponse>() {};
    return (CompleteResponse<RegisterDomainResponse>)apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
/**
   * RegisterDomain
   * Activates a domain for use with Web Apple Pay and Square. A validation will be performed on this domain by Apple to ensure is it properly set up as an Apple Pay enabled domain.  This endpoint provides an easy way for platform developers to bulk activate Web Apple Pay with Square for merchants using their platform.  To learn more about Apple Pay on Web see the Apple Pay section in the [Square Payment Form Walkthrough](/docs/payment-form/payment-form-walkthrough).
   * @param body An object containing the fields to POST for the request.  See the corresponding object definition for field details. (required)
   * @return CompleteResponse<RegisterDomainResponse>
   * @throws ApiException if fails to make API call
   */
RegisterDomain
Activates a domain for use with Web Apple Pay and Square. A validation will be performed on this domain by Apple to ensure is it properly set up as an Apple Pay enabled domain.  This endpoint provides an easy way for platform developers to bulk activate Web Apple Pay with Square for merchants using their platform.  To learn more about Apple Pay on Web see the Apple Pay section in the [Square Payment Form Walkthrough](/docs/payment-form/payment-form-walkthrough).
@param body An object containing the fields to POST for the request.  See the corresponding object definition for field details. (required)
@return CompleteResponse
@throws ApiException if fails to make API call
RegisterDomain Activates a domain for use with Web Apple Pay and Square . A validation will be performed on this domain by Apple to ensure is it properly set up as an Apple Pay enabled domain . This endpoint provides an easy way for platform developers to bulk activate Web Apple Pay with Square for merchants using their platform . To learn more about Apple Pay on Web see the Apple Pay section in the [ Square Payment Form Walkthrough ] ( / docs / payment - form / payment - form - walkthrough ) . @param body An object containing the fields to POST for the request . See the corresponding object definition for field details . ( required ) @return CompleteResponse @throws ApiException if fails to make API call
public CompleteResponse<RegisterDomainResponse>registerDomainWithHttpInfo(RegisterDomainRequest body) throws ApiException {
    Object localVarPostBody = body;
    if (body == null) {
      throw new ApiException(400, "Missing the required parameter 'body' when calling registerDomain");
    }
    String localVarPath = "/v2/apple-pay/domains";
    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");
    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<RegisterDomainResponse> localVarReturnType = new GenericType<RegisterDomainResponse>() {};
    return (CompleteResponse<RegisterDomainResponse>)apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
public CompleteResponse < RegisterDomainResponse > registerDomainWithHttpInfo ( RegisterDomainRequest body ) throws ApiException { Object localVarPostBody = body ; if ( body == null ) { throw new ApiException ( 400 , "Missing the required parameter 'body' when calling registerDomain" ) ; } String localVarPath = "/v2/apple-pay/domains" ; 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" ) ; 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 < RegisterDomainResponse > localVarReturnType = new GenericType < RegisterDomainResponse > ( ) { } ; return ( CompleteResponse < RegisterDomainResponse > ) apiClient . invokeAPI ( localVarPath , "POST" , localVarQueryParams , localVarPostBody , localVarHeaderParams , localVarFormParams , localVarAccept , localVarContentType , localVarAuthNames , localVarReturnType ) ; }
RegisterDomain
 Activates a domain for use with Web Apple Pay and Square.
RegisterDomain Activates a domain for use with Web Apple Pay and Square .
// verify the required parameter 'body' is set // create path and map variables // query params