## `/api/clinics/options`
### New options for service flows:
"option" should be an array of all the pharmacies services, including an array for keywords.
The database will be updated based on "option" e.g. if a flow is in the database but missing from "option" it will be removed from the database. The same applies for keywords.

BODY:
```js
{
    "setting": "services",
    "option": [
	    {
		    name: "service_1",
		    is_enabled: true,
		    keywords: ["keyword_1","keyword_2"]
	    },
	    {
		    name: "service_2",
		    is_enabled: false,
		    keywords: ["keyword_1","keyword_2"]
	    }
    ]
}
```


### New options for adding/removing keywords:
Any keywords in the database that are not in the options array will be removed.
Any keywords in the options array that are not in the database will be added.

BODY:
```js
{
    "setting": "keywords",
    "option": [ "Doctor", "Asthma", "Prescribed" ] // array of all keywords
}
```


### New options for updating pharmacy details:
BODY:
```js
{
    "setting": "pharmacy_details",
    "option": {
        "name":"TWC Test Pharmacy",
        "address":"123 Street Name",
        "phone_number":"021 234 5678",
        "email":"test@pharmacy.com",
    }
}
```


### New options for updating pharmacy greeting:
BODY:
```js
{
    "setting": "greeting",
    "option": "Hello {CALLER_NAME}, welcome to TWC Pharmacy."
}
```


### New options for updating location instructions:
BODY:
```js
{
    "setting": "location_instructions",
    "option": "We are located at 123 street name. Go down the drive and you will find parking to the right."
}
```


## `/api/clinics/keywords`
Gets the array of keywords used to set verification to required


### New options for holiday hours message:
Add holiday hours message that will be appended to the greeting message. 

BODY:
```js
{
    "setting": "holiday_hours",
    "option": "We are closed on christmas day."
}
```

#### Notes:
- If holiday hours is disabled on dashboard, option should be null e.g.
```js
{
    "setting": "holiday_hours",
    "option": null
}
```

METHOD: GET
AUTH: Bearer Token
HEADER: Client-Public-Key

Returns
```js
[
  'Prescriptions',
  'Medicines',
  'Diagnosed',
  'Doctor',
  'Asthma',
  'Prescribed',
  'Dispense',
  'Pills'
]
```

## `/api/clinics/services`
Gets the current services the pharmacy has

METHOD: GET
AUTH: Bearer Token
HEADER: Client-Public-Key

Returns
```js
[
	{
		name: "service_1",
		is_enabled: true,
		keywords: ["keyword_1","keyword_2"]
	},
	{
		name: "service_2",
		is_enabled: false,
		keywords: ["keyword_1","keyword_2"]
	}
]
```


## `/api/clinics/greeting`
Gets the current greeting the pharmacy has

METHOD: GET
AUTH: Bearer Token
HEADER: Client-Public-Key

Returns
```js
"Hello {CALLER_NAME}, welcome to TWC Pharmacy."
```


## `/api/clinics/get/:option`
METHOD: GET
AUTH: Bearer Token
HEADER: Client-Public-Key

Use to get the current value of settings that can be updated with clinics/options, including:
- services
- keywords
- opening_hours
- pharmacy_details
- holiday_hours
- greeting
- location_instructions

### Example:
`clinics/get/pharmacy_details`
Returns
```js
{
    "name":"TWC Test Pharmacy",
    "address":"123 Street Name",
    "phone_number":"021 234 5678",
    "email":"test@pharmacy.com",
}
```