updateMachineWithHttpInfo method

Future<Response> updateMachineWithHttpInfo(
  1. String machineId, {
  2. UpdateMachineRequest? updateMachineRequest,
})

Update a machine

Updates an existing machine. Only the provided fields will be updated.

Note: This method returns the HTTP Response.

Parameters:

Implementation

Future<http.Response> updateMachineWithHttpInfo(
  String machineId, {
  UpdateMachineRequest? updateMachineRequest,
}) async {
  // ignore: prefer_const_declarations
  final path =
      r'/machines/{machine_id}'.replaceAll('{machine_id}', machineId);

  // ignore: prefer_final_locals
  Object? postBody = updateMachineRequest;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  const contentTypes = <String>['application/json'];

  return apiClient.invokeAPI(
    path,
    'PATCH',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes.first,
  );
}