# Medication List

| **API URL**     | {{url}}/admin-service/medication/list |
| --------------- | ------------------------------------- |
| **Method**      | POST                                  |
| **Description** | Get the medication list               |

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

| **Field Name**         | **Type** | **Mandatory** | **Example**                                                                                                                             |
| ---------------------- | -------- | ------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| skip                   | Integer  | No            | Skip data to filter data                                                                                                                |
| classificationIds      | Bigint   | Yes           | List of Classification IDs                                                                                                              |
| brandIds               | Bigint   | Yes           | List of brand IDs                                                                                                                       |
| dosageFormIds          | Bigint   | Yes           | List of dosage form IDs                                                                                                                 |
| limit                  | Integer  | Yes           | Limit to fetching data                                                                                                                  |
| searchTerm             | String   | No            | Search Term to filter data                                                                                                              |
| countryId              | Integer  | Yes           | Country id                                                                                                                              |
| Authorization (Header) | String   | Yes           | Bearer 1ba363a1edf54402b51f58060aa52b11d30f99a490295adec900fdabf2b472181c0bfb165be18f4f5c430c7218a244bd29b9300d3471acc08197ccfb996118f6 |
| client                 | String   | Yes           | web                                                                                                                                     |

```
{
  "skip": 0,
  "limit": 10,
  "searchTerm": "",
  "countryId": "1"
}
```

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

| **Field Name**     | **Type** | **Comments**         |
| ------------------ | -------- | -------------------- |
| message            | String   | Got All Medications. |
| status             | String   | Menu status          |
| entityList         | String   | Entity List          |
| id                 | Bigint   | Medication id        |
| name               | String   | Name of Medication   |
| classificationId   | Bigint   | Classification Id    |
| dosageFormId       | Bigint   | DosageForm Id        |
| brandId            | Bigint   | Brand Id             |
| classificationName | String   | Classification Name  |
| brandName          | String   | Brand Name           |
| dosageFormName     | String   | Dosage Form Name     |
| countryid          | Bigint   | Country id           |
| tenantId           | Bigint   | Tenant Id            |
| codeDetails        | String   | Code Details         |
| code               | Bigint   | Labtest code         |
| url                | String   | Lab test url         |

```
{
  "message": "Got All Medications.",
  "entity": null,
  "status": true,
  "entityList": [
      {
          "id": 1,
          "name": "Calaptin 120mg",
          "classificationId": 1,
          "dosageFormId": 1,
          "brandId": 2,
          "classificationName": "ACE inhibitor",
          "brandName": "Biomet",
          "dosageFormName": "Tablet",
          "countryId": 1,
          "tenantId": null,
          "codeDetails": {
              "code": "1",
              "url": "http://purl.org/ontology/SNOMEDCT/6456007"
          },
          "category": null
      },
      {
          "id": 2,
          "name": "Test",
          "classificationId": 1,
          "dosageFormId": 1,
          "brandId": 1,
          "classificationName": "ACE inhibitor",
          "brandName": "Antibiotics",
          "dosageFormName": "Tablet",
          "countryId": 1,
          "tenantId": null,
          "codeDetails": {
              "code": "aaa",
              "url": "nnnn"
          },
          "category": null
      }
  ],
  "responseCode": 200,
  "totalCount": 1
}
```
