---
title: "Complete/update a leak event"
method: PUT
path: "/refrigeranttracking/leakrecord"
tags: ["RefrigerantTracking"]
---

# Complete/update a leak event

`PUT /refrigeranttracking/leakrecord`

## Request

- Base URL: `https://sb2api.servicechannel.com/v3`
- URL: `https://sb2api.servicechannel.com/v3/refrigeranttracking/leakrecord`
- Auth: OAuth 2
  - Authorization code: `https://sb2login.servicechannel.com/oauth/authorize`
  - Token URL: `https://sb2login.servicechannel.com/oauth/token`
- TypeScript: <https://skmtc.dev/servicechannel/apis/servicechannel-api-v-3/docs/refrigeranttracking/leakrecord/put.ts> (a function with typed inputs; its response is checked against the schema)

Allows users to close a leak event by setting the completion date. Other leak information can be updated as well for both in-progress and completed leak events. 
            <br />***Note:*** When the *RTMultiLeakFlow* feature flag is on, you can only add or update the completion date via this method. Other parameters cannot be modified. Note that at least one leak record should be associated with the event.

## Request body

- ServiceChannelServicesMessagingRefrigerantTrackingUpdateLeakRecordRequest: Object containing information about the leak event.
  - `Id` integer, required: Unique numeric identifier of the leak event. Leak event IDs can be found in the **Refrigerant Leak Events** report in Service Automation.
  - `Note` string: Leak record note.
  - `RepairDate` string, date-time: Date when the repair was completed. It cannot be earlier than the work order call date. The date format is `YYYY-MM-DDThh:mm:ss.sssZ`.
  - `InitialDate` string, date-time: Date when the first leak verification took place. The date format is `YYYY-MM-DDThh:mm:ss.sssZ`. ***Note:*** The initial verification date cannot be in the future. It should be either a current date or a date in the past.
  - `InitialMethod` integer: Method that was used during the first verification to make sure the leak had been fixed. <br />Possible values: • `0`: Unknown • `1`: Soap Bubble Test • `2`: Electronic Leak Detection • `3`: Ultrasonic Leak Detection • `4`: Pressure Test • `5`: Vacuum Test • `6`: Fluorescent Dye Test • `7`: Infrared Test • `8`: Near Infrared Test • `9`: Halon Gas Detection
  - `FollowUpDate` string, date-time: Date of the second verification. The date format is `YYYY-MM-DDThh:mm:ss.sssZ`. ***Note:*** The follow-up verification date cannot be earlier than the initial verification date and cannot be in the future. It should be either a current date or a date in the past.
  - `FollowUpMethod` integer: Method of the second verification. The list of available verification methods is the same as for the `InitialMethod`.
  - `LeakLocationId` integer: Unique numeric identifier of the location where the leak occurred: more specific place within the particular area, for example, *Level Indicator/Alarm*, *Splitting Valve*. Use the [GET/refrigeranttracking/{subscriberId}/leaklocations](https://developer.servicechannel.com/swagger/index.html#/RefrigerantTracking/GETv3_refrigeranttracking_%7BsubscriberId%7D_leaklocations) method to get the list of available leak locations.
  - `FaultCodeId` integer: Unique numeric identifier of the reason why the problem occurred. Use the [GET/refrigeranttracking/leakRecord/faultCodes](https://developer.servicechannel.com/swagger/index.html#/RefrigerantTracking/GETv3_refrigeranttracking_leakRecord_faultCodes) method to get available fault codes and their IDs. <br />Possible values: • `1`: Accidental Damage • `2`: Braze or Joint Failure • `3`: Corrosion • `4`: Defrost Heater Failure • `5`: Faulty Part • `6`: Forklift Damage • `7`: Gasket Seal Failure • `8`: Ice Build Up • `9`: Line Break • `10`: Manufacture Defect • `11`: Missing Part • `12`: Natural Disaster • `13`: Normal Mechanical Wear • `14`: Other(Must Explain in Comments) • `15`: Vandalism • `16`: Vibration Related • `17`: Project Related Loss
  - `ActionCodeId` integer: Unique numeric identifier of the action that a technician took to fix the leak. Use the [GET/refrigeranttracking/leakRecord/actionCodes](https://developer.servicechannel.com/swagger/index.html#/RefrigerantTracking/GETv3_refrigeranttracking_leakRecord_actionCodes) method to get available action codes and their IDs.
  - `LeakAreaId` integer: Unique numeric identifier of the area where the leak occurred: more general place, for example, *Receiver* or *Compressor*. Use the [GET/refrigeranttracking/leakareas](https://developer.servicechannel.com/swagger/index.html#/RefrigerantTracking/GETv3_refrigeranttracking_leakareas) method to get leak areas and their IDs.
  - `CurrentTrackingNumber` integer: Unique numeric identifier of the work order.
  - `CompletedDate` string, date-time: Date and time when the leak event was completed. The date format is `YYYY-MM-DDThh:mm:ss.sssZ`. ***Note:*** The leak event completion date cannot be earlier than the leak event repair date and later than the work order completion date.

## Response `200`

The specified leak event has been successfully updated.

## Other responses

- `400`: The request was not accepted due to bad syntax, missing parameters, insufficient data, etc. <br/>Error codes: 502 &mdash; Leak record was not updated 503 &mdash; Leak location ID is required 503 &mdash; Leak record is not found 503 &mdash; Follow-up verification date on the leak record cannot be less than the initial verification date + secondary verification delay time. Depending on the refrigerant tracking settings, it could be required to pass the follow-up verification not earlier than in several days after the initial verification. 503 &mdash; Completion date can't be less than the leak record repair date 503 &mdash; Completion date can't be less than the work order call date 503 &mdash; Completion date can't be more than the work order completion date 503 &mdash; Follow-up date and the completed date can't be earlier than the initial date 503 &mdash; Follow-up date and the completed date can't be earlier than the repair date 503 &mdash; Follow-up date and the completed date can't be earlier than the trigger date 503 &mdash; Repair date and the initial date should be entered 503 &mdash; Repair date is required 503 &mdash; Follow-up verification date and/or the completed date is earlier than the refrigerant removal date 503 &mdash; Repair date and the completion date can't be earlier than the work order call date 503 &mdash; Repair date and the completion date can't be more than the work order completion date 503 &mdash; Leak record completion date cannot be less than the refrigerant usage date 503 &mdash; Leak record repair and the verification date should be less than the next leak record triggered date 503 &mdash; Leak record initial date should be less than the next leak record triggered date 503 &mdash; Leak record repair and the verification date should be less than any refrigerant use related to the next leak record 503 &mdash; Leak record repair and the verification date should be more than the previous leak record completion date 503 &mdash; Initial date can't be earlier than the repair date 503 &mdash; Leak record completion date should not be out of the retrofit plan dates 503 &mdash; Work order is in the completed status. Only RT Admins can process 503 &mdash; Work order is already completed. Verification data cannot be removed 503 &mdash; Follow-up date must equal the completed date 503 &mdash; Leak event should contain at least one leak record
- `401`: The requested resource requires authentication. <br>Error codes: 504 &mdash; API call rejected by security permissions
- `500`: Something went wrong, and the server was unable to complete your request. <br>Error codes: 501 &mdash; Internal Error

---

[API](https://skmtc.dev/servicechannel/apis/servicechannel-api-v-3.md) - [All operations](https://skmtc.dev/servicechannel/apis/servicechannel-api-v-3/llms.txt) - [OpenAPI document](https://skmtc.dev/servicechannel/apis/servicechannel-api-v-3/revisions/d490d6596809?raw)
