src/main/java/com/squareup/connect/api/V1TransactionsApi.java
public CompleteResponse<V1Settlement>retrieveSettlementWithHttpInfo(String locationId, String settlementId) throws ApiException {
    Object localVarPostBody = null;
    
    // verify the required parameter 'locationId' is set
    if (locationId == null) {
      throw new ApiException(400, "Missing the required parameter 'locationId' when calling retrieveSettlement");
    }
    
    // verify the required parameter 'settlementId' is set
    if (settlementId == null) {
      throw new ApiException(400, "Missing the required parameter 'settlementId' when calling retrieveSettlement");
    }
    
    // create path and map variables
    String localVarPath = "/v1/{location_id}/settlements/{settlement_id}"
      .replaceAll("\\{" + "location_id" + "\\}", apiClient.escapeString(locationId.toString()))
      .replaceAll("\\{" + "settlement_id" + "\\}", apiClient.escapeString(settlementId.toString()));

    // 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<V1Settlement> localVarReturnType = new GenericType<V1Settlement>() {};
    return (CompleteResponse<V1Settlement>)apiClient.invokeAPI(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
/**
   * RetrieveSettlement
   * Provides comprehensive information for a single settlement.  The returned &#x60;Settlement&#x60; objects include an &#x60;entries&#x60; field that lists the transactions that contribute to the settlement total. Most settlement entries correspond to a payment payout, but settlement entries are also generated for less common events, like refunds, manual adjustments, or chargeback holds.  Square initiates its regular deposits as indicated in the [Deposit Options with Square](https://squareup.com/help/us/en/article/3807) help article. Details for a regular deposit are usually not available from Connect API endpoints before 10 p.m. PST the same day.  Square does not know when an initiated settlement **completes**, only whether it has failed. A completed settlement is typically reflected in a bank account within 3 business days, but in exceptional cases it may take longer.
   * @param locationId The ID of the settlements&#39;s associated location. (required)
   * @param settlementId The settlement&#39;s Square-issued ID. You obtain this value from Settlement objects returned by the List Settlements endpoint. (required)
   * @return CompleteResponse<V1Settlement>
   * @throws ApiException if fails to make API call
   */
RetrieveSettlement
Provides comprehensive information for a single settlement.  The returned `Settlement` objects include an `entries` field that lists the transactions that contribute to the settlement total. Most settlement entries correspond to a payment payout, but settlement entries are also generated for less common events, like refunds, manual adjustments, or chargeback holds.  Square initiates its regular deposits as indicated in the [Deposit Options with Square] help article. Details for a regular deposit are usually not available from Connect API endpoints before 10 p.m. PST the same day.  Square does not know when an initiated settlement **completes**, only whether it has failed. A completed settlement is typically reflected in a bank account within 3 business days, but in exceptional cases it may take longer.
@param locationId The ID of the settlements's associated location. (required)
@param settlementId The settlement's Square-issued ID. You obtain this value from Settlement objects returned by the List Settlements endpoint. (required)
@return CompleteResponse
@throws ApiException if fails to make API call
RetrieveSettlement Provides comprehensive information for a single settlement . The returned ` Settlement ` objects include an ` entries ` field that lists the transactions that contribute to the settlement total . Most settlement entries correspond to a payment payout but settlement entries are also generated for less common events like refunds manual adjustments or chargeback holds . Square initiates its regular deposits as indicated in the [ Deposit Options with Square ] help article . Details for a regular deposit are usually not available from Connect API endpoints before 10 p . m . PST the same day . Square does not know when an initiated settlement ** completes ** only whether it has failed . A completed settlement is typically reflected in a bank account within 3 business days but in exceptional cases it may take longer . @param locationId The ID of the settlements ' s associated location . ( required ) @param settlementId The settlement ' s Square - issued ID . You obtain this value from Settlement objects returned by the List Settlements endpoint . ( required ) @return CompleteResponse @throws ApiException if fails to make API call
public CompleteResponse<V1Settlement>retrieveSettlementWithHttpInfo(String locationId, String settlementId) throws ApiException {
    Object localVarPostBody = null;
    if (locationId == null) {
      throw new ApiException(400, "Missing the required parameter 'locationId' when calling retrieveSettlement");
    }
    if (settlementId == null) {
      throw new ApiException(400, "Missing the required parameter 'settlementId' when calling retrieveSettlement");
    }
    String localVarPath = "/v1/{location_id}/settlements/{settlement_id}"
      .replaceAll("\\{" + "location_id" + "\\}", apiClient.escapeString(locationId.toString()))
      .replaceAll("\\{" + "settlement_id" + "\\}", apiClient.escapeString(settlementId.toString()));
    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<V1Settlement> localVarReturnType = new GenericType<V1Settlement>() {};
    return (CompleteResponse<V1Settlement>)apiClient.invokeAPI(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
public CompleteResponse < V1Settlement > retrieveSettlementWithHttpInfo ( String locationId , String settlementId ) throws ApiException { Object localVarPostBody = null ; if ( locationId == null ) { throw new ApiException ( 400 , "Missing the required parameter 'locationId' when calling retrieveSettlement" ) ; } if ( settlementId == null ) { throw new ApiException ( 400 , "Missing the required parameter 'settlementId' when calling retrieveSettlement" ) ; } String localVarPath = "/v1/{location_id}/settlements/{settlement_id}" . replaceAll ( "\\{" + "location_id" + "\\}" , apiClient . escapeString ( locationId . toString ( ) ) ) . replaceAll ( "\\{" + "settlement_id" + "\\}" , apiClient . escapeString ( settlementId . toString ( ) ) ) ; 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 < V1Settlement > localVarReturnType = new GenericType < V1Settlement > ( ) { } ; return ( CompleteResponse < V1Settlement > ) apiClient . invokeAPI ( localVarPath , "GET" , localVarQueryParams , localVarPostBody , localVarHeaderParams , localVarFormParams , localVarAccept , localVarContentType , localVarAuthNames , localVarReturnType ) ; }
RetrieveSettlement
 Provides comprehensive information for a single settlement.
RetrieveSettlement Provides comprehensive information for a single settlement .
// verify the required parameter 'locationId' is set // verify the required parameter 'settlementId' is set // create path and map variables // query params