src/main/java/com/squareup/connect/api/V1EmployeesApi.java
public CompleteResponse<V1Timecard>updateTimecardWithHttpInfo(String timecardId, V1Timecard body) throws ApiException {
    Object localVarPostBody = body;
    
    // verify the required parameter 'timecardId' is set
    if (timecardId == null) {
      throw new ApiException(400, "Missing the required parameter 'timecardId' when calling updateTimecard");
    }
    
    // verify the required parameter 'body' is set
    if (body == null) {
      throw new ApiException(400, "Missing the required parameter 'body' when calling updateTimecard");
    }
    
    // create path and map variables
    String localVarPath = "/v1/me/timecards/{timecard_id}"
      .replaceAll("\\{" + "timecard_id" + "\\}", apiClient.escapeString(timecardId.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<V1Timecard> localVarReturnType = new GenericType<V1Timecard>() {};
    return (CompleteResponse<V1Timecard>)apiClient.invokeAPI(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
/**
   * UpdateTimecard
   * Modifies the details of a timecard with an &#x60;API_EDIT&#x60; event for the timecard. Updating an active timecard with a &#x60;clockout_time&#x60; clocks the employee out.
   * @param timecardId TThe ID of the timecard to modify. (required)
   * @param body An object containing the fields to POST for the request. See the corresponding object definition for field details. (required)
   * @return CompleteResponse<V1Timecard>
   * @throws ApiException if fails to make API call
   */
UpdateTimecard
Modifies the details of a timecard with an `API_EDIT` event for the timecard. Updating an active timecard with a `clockout_time` clocks the employee out.
@param timecardId TThe ID of the timecard to modify. (required)
@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
UpdateTimecard Modifies the details of a timecard with an ` API_EDIT ` event for the timecard . Updating an active timecard with a ` clockout_time ` clocks the employee out . @param timecardId TThe ID of the timecard to modify . ( required ) @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<V1Timecard>updateTimecardWithHttpInfo(String timecardId, V1Timecard body) throws ApiException {
    Object localVarPostBody = body;
    if (timecardId == null) {
      throw new ApiException(400, "Missing the required parameter 'timecardId' when calling updateTimecard");
    }
    if (body == null) {
      throw new ApiException(400, "Missing the required parameter 'body' when calling updateTimecard");
    }
    String localVarPath = "/v1/me/timecards/{timecard_id}"
      .replaceAll("\\{" + "timecard_id" + "\\}", apiClient.escapeString(timecardId.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<V1Timecard> localVarReturnType = new GenericType<V1Timecard>() {};
    return (CompleteResponse<V1Timecard>)apiClient.invokeAPI(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
  }
public CompleteResponse < V1Timecard > updateTimecardWithHttpInfo ( String timecardId , V1Timecard body ) throws ApiException { Object localVarPostBody = body ; if ( timecardId == null ) { throw new ApiException ( 400 , "Missing the required parameter 'timecardId' when calling updateTimecard" ) ; } if ( body == null ) { throw new ApiException ( 400 , "Missing the required parameter 'body' when calling updateTimecard" ) ; } String localVarPath = "/v1/me/timecards/{timecard_id}" . replaceAll ( "\\{" + "timecard_id" + "\\}" , apiClient . escapeString ( timecardId . 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 < V1Timecard > localVarReturnType = new GenericType < V1Timecard > ( ) { } ; return ( CompleteResponse < V1Timecard > ) apiClient . invokeAPI ( localVarPath , "PUT" , localVarQueryParams , localVarPostBody , localVarHeaderParams , localVarFormParams , localVarAccept , localVarContentType , localVarAuthNames , localVarReturnType ) ; }
UpdateTimecard
 Modifies the details of a timecard with an &#x60;API_EDIT&#x60; event for the timecard.
UpdateTimecard Modifies the details of a timecard with an &#x60 ; API_EDIT&#x60 ; event for the timecard .
// verify the required parameter 'timecardId' is set // verify the required parameter 'body' is set // create path and map variables // query params