> For the complete documentation index, see [llms.txt](https://spice.docs.medtroniclabs.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://spice.docs.medtroniclabs.org/engineering/api-documentation/admin-services/lab-test-customization/lab-test-update.md).

# Lab Test Update

| **API URL**     | {{url}}/admin-service/lab-test-customization/update |
| --------------- | --------------------------------------------------- |
| **Method**      | POST                                                |
| **Description** | Updation of Lab test customization.                 |

#### **Sample Input** <a href="#labtestupdate-v2-sampleinput" id="labtestupdate-v2-sampleinput"></a>

| **Field Name**         | **Type** | **Mandatory** | **Example**                                                                                                                             |
| ---------------------- | -------- | ------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| codeDetails            | String   | Yes           | Code Details of lab test                                                                                                                |
| code                   | String   | Yes           | Lab test Code                                                                                                                           |
| url                    | String   | Yes           | Url for lab test                                                                                                                        |
| id                     | Bigint   | Yes           | Lab test id                                                                                                                             |
| countryId              | Bigint   | Yes           | Country id                                                                                                                              |
| displayOrder           | Bigint   | Yes           | Display Order                                                                                                                           |
| formInput              | String   | Yes           | Form Input                                                                                                                              |
| tenantId               | Bigint   | Yes           | Tenant Id                                                                                                                               |
| testName               | String   | Yes           | Lab Test Name                                                                                                                           |
| uniqueName             | String   | Yes           | Lab Test Unique Name                                                                                                                    |
| Authorization (Header) | String   | Yes           | Bearer 1ba363a1edf54402b51f58060aa52b11d30f99a490295adec900fdabf2b472181c0bfb165be18f4f5c430c7218a244bd29b9300d3471acc08197ccfb996118f6 |
| client                 | String   | Yes           | web                                                                                                                                     |

```
{
  "codeDetails": {
    "code": "testone",
    "url": "https://com/region/1/1/lab-test"
  },
  "countryId": 1, 
  "formInput": "{\"time\":1737612623991,\"formLayout\":[{\"id\":\"testone1737612553423\",\"viewType\":\"CardView\",\"title\":\"Testone\",\"familyOrder\":0},{\"id\":\"TestedOn\",\"viewType\":\"DatePicker\",\"title\":\"Tested On\",\"fieldName\":\"TestedOn\",\"family\":\"testone1737612553423\",\"isMandatory\":true,\"isEnabled\":true,\"visibility\":\"visible\",\"isDefault\":false,\"disableFutureDate\":true,\"minDays\":null,\"maxDays\":null,\"isDeletable\":false,\"orderId\":1},{\"id\":\"Tested\",\"viewType\":\"EditText\",\"title\":\"Tested\",\"fieldName\":\"Tested\",\"family\":\"testone1737612553423\",\"isMandatory\":true,\"isEnabled\":true,\"isResult\":true,\"visibility\":\"visible\",\"hint\":\"\",\"errorMessage\":\"\",\"inputType\":-1,\"isDefault\":false,\"minLength\":\"1\",\"maxLength\":\"111\",\"orderId\":2,\"code\":null,\"url\":null,\"resource\":\"String\",\"condition\":null}]}",
  "id": 187,
  "index": 0,
  "tenantId": "77",
  "testName": "Testone",
  
```

#### **Sample Output** <a href="#labtestupdate-v2-sampleoutput" id="labtestupdate-v2-sampleoutput"></a>

| **Field Name** | **Type** | **Example**                       |
| -------------- | -------- | --------------------------------- |
| message        | String   | LabTest was updated successfully. |
| id             | Bigint   | Lab test id                       |
| codeDetails    | String   | Code Details of lab test          |
| code           | String   | Lab test Code                     |
| url            | String   | Url for lab test                  |
| countryId      | Bigint   | Country id                        |
| displayOrder   | Bigint   | Display Order                     |
| formInput      | String   | Form Input                        |
| tenantId       | Bigint   | Tenant Id                         |
| testName       | String   | Lab Test Name                     |
| uniqueName     | String   | Lab Test Unique Name              |
| updatedAt      | Date     | Lab test updated at               |
| status         | Boolean  | Entity status for request         |

```
{
  "message": "LabTest updated successfully.",
  "entity": {
      "id": 187,
      "uniqueName": "testone1737612553249",
      "testName": "Testone",
      "formInput": "{\"time\":1737612623991,\"formLayout\":[{\"id\":\"testone1737612553423\",\"viewType\":\"CardView\",\"title\":\"Testone\",\"familyOrder\":0},{\"id\":\"TestedOn\",\"viewType\":\"DatePicker\",\"title\":\"Tested On\",\"fieldName\":\"TestedOn\",\"family\":\"testone1737612553423\",\"isMandatory\":true,\"isEnabled\":true,\"visibility\":\"visible\",\"isDefault\":false,\"disableFutureDate\":true,\"minDays\":null,\"maxDays\":null,\"isDeletable\":false,\"orderId\":1},{\"id\":\"Tested\",\"viewType\":\"EditText\",\"title\":\"Tested\",\"fieldName\":\"Tested\",\"family\":\"testone1737612553423\",\"isMandatory\":true,\"isEnabled\":true,\"isResult\":true,\"visibility\":\"visible\",\"hint\":\"\",\"errorMessage\":\"\",\"inputType\":-1,\"isDefault\":false,\"minLength\":\"1\",\"maxLength\":\"111\",\"orderId\":2,\"code\":null,\"url\":null,\"resource\":\"String\",\"condition\":null}]}",
      "countryId": 1,
      "tenantId": "77",
      "codeDetails": {
          "code": "testone",
          "url": "https://spice-dev.sl.labsplatform.com/region/1/1/lab-test"
      },
      "updatedAt": "2025-01-23T11:40:24+05:30"
  },
  "status": true,
  "entityList": null,
  "responseCode": 201,
  "totalCount": null
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://spice.docs.medtroniclabs.org/engineering/api-documentation/admin-services/lab-test-customization/lab-test-update.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
