Skip to content

Commit a96677b

Browse files
authored
Removed references to ‘Common Health Questions’ (#142)
1 parent eebcdb5 commit a96677b

14 files changed

Lines changed: 301 additions & 1774 deletions

proxies/live/apiproxy/resources/jsc/SearchAndReplaceResponse.js

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -192,40 +192,6 @@ var searchAndReplaceStrings = [
192192
searchForRegex: /href=\\"\/pregnancy\//gm,
193193
replaceWithStr: 'href=\\"https://www.nhs.uk/pregnancy/',
194194
},
195-
{
196-
comment1: "=============================================================",
197-
comment2: "Common health questions ",
198-
comment3: "=============================================================",
199-
},
200-
{
201-
searchForRegex: /:\s?"https:\/\/api.nhs.uk\/common-health-questions\//gm,
202-
replaceWithStr:
203-
': "https://' +
204-
requestHostnameEnv +
205-
"/nhs-website-content/common-health-questions/",
206-
},
207-
{
208-
searchForRegex: /:\s?"https:\/\/www.nhs.uk\/common-health-questions\//gm,
209-
replaceWithStr:
210-
': "https://' +
211-
requestHostnameEnv +
212-
"/nhs-website-content/common-health-questions/",
213-
},
214-
{
215-
searchForRegex: /:\s?"\/common-health-questions\//gm,
216-
replaceWithStr:
217-
': "https://' +
218-
requestHostnameEnv +
219-
"/nhs-website-content/common-health-questions/",
220-
},
221-
{
222-
searchForRegex: /href=\\"https:\/\/api.nhs.uk\/common-health-questions\//gm,
223-
replaceWithStr: 'href=\\"https://www.nhs.uk/common-health-questions/',
224-
},
225-
{
226-
searchForRegex: /href=\\"\/common-health-questions\//gm,
227-
replaceWithStr: 'href=\\"https://www.nhs.uk/common-health-questions/',
228-
},
229195
{
230196
comment1: "=============================================================",
231197
comment2: "Contraception ",

proxies/sandbox/apiproxy/resources/jsc/SearchAndReplaceResponse.js

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -145,33 +145,6 @@
145145
// },
146146
// {
147147
// comment1: "=============================================================",
148-
// comment2: "Common health questions ",
149-
// comment3: "=============================================================",
150-
// },
151-
// {
152-
// searchForRegex: /:\s?"https:\/\/api.nhs.uk\/common-health-questions\//gm,
153-
// replaceWithStr:
154-
// ': "https://' +
155-
// requestHostnameEnv +
156-
// "/nhs-website-content/common-health-questions/",
157-
// },
158-
// {
159-
// searchForRegex: /:\s?"https:\/\/www.nhs.uk\/common-health-questions\//gm,
160-
// replaceWithStr:
161-
// ': "https://' +
162-
// requestHostnameEnv +
163-
// "/nhs-website-content/common-health-questions/",
164-
// },
165-
// {
166-
// searchForRegex: /href=\\"https:\/\/api.nhs.uk\/common-health-questions\//gm,
167-
// replaceWithStr: 'href=\\"https://www.nhs.uk/common-health-questions/',
168-
// },
169-
// {
170-
// searchForRegex: /href=\\"\/common-health-questions\//gm,
171-
// replaceWithStr: 'href=\\"https://www.nhs.uk/common-health-questions/',
172-
// },
173-
// {
174-
// comment1: "=============================================================",
175148
// comment2: "Contraception ",
176149
// comment3: "=============================================================",
177150
// },

sandbox/Sandbox endpoints - localhost.md

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,6 @@
44

55
[API Root](http://localhost:9000/)
66

7-
## Common Health Questions
8-
9-
[Common Health Questions Root](http://localhost:9000/common-health-questions/)
10-
11-
[Accidents, first aid and treatments](http://localhost:9000/common-health-questions/accidents-first-aid-and-treatments/)
12-
13-
[Caring, carers and long-term conditions](http://localhost:9000/common-health-questions/caring-carers-and-long-term-conditions/)
14-
15-
[Children's health - Can my baby go swimming before or after vaccinations?](http://localhost:9000/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/)
16-
177
## Conditions
188

199
[Conditions Root](http://localhost:9000/conditions/)

sandbox/app.js

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -131,23 +131,6 @@ app.get('/_status', handlers.status)
131131
// ******************************************************************
132132
app.all('/', handlers.root)
133133

134-
// ******************************************************************
135-
// ** Common Health Questions pages
136-
// ******************************************************************
137-
app.all('/common-health-questions/', handlers.commonHealthQuestionsRoot)
138-
app.all(
139-
'/common-health-questions/accidents-first-aid-and-treatments/',
140-
handlers.commonHealthQuestionsAccidentsFirstAidAndTreatments
141-
)
142-
app.all(
143-
'/common-health-questions/caring-carers-and-long-term-conditions/',
144-
handlers.commonHealthQuestionsCaringCarersAndLongTermConditions
145-
)
146-
app.all(
147-
'/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/',
148-
handlers.commonHealthQuestionsChildrensHealthCanMyBabyGoSwimmingBeforeOrAfterVaccinations
149-
)
150-
151134
// ******************************************************************
152135
// ** Conditions pages
153136
// ******************************************************************

sandbox/handlers.js

Lines changed: 0 additions & 94 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,6 @@ const log = require('loglevel')
55
const errorResourceNotFoundResponse = require('./responses/error-resource-not-found.json')
66
const errorSandboxResponseNotFound = require('./responses/error-sandbox-response-not-found.json')
77

8-
// Common health questions - Responses
9-
const commonHealthQuestionsRootResponse = require('./responses/common-health-questions-root-no-params.json')
10-
const commonHealthQuestionsAccidentsFirstAidAndTreatmentsResponse = require('./responses/common-health-questions-accidents-first-aid-and-treatments-no-params.json')
11-
const commonHealthQuestionsCaringCarersAndLongTermConditionsResponse = require('./responses/common-health-questions-caring-carers-and-long-term-conditions-no-params.json')
12-
const commonHealthQuestionsChildrensHealthCanMyBabyGoSwimmingBeforeOrAfterVaccinationsResponse = require('./responses/common-health-questions-childrens-health-can-my-baby-go-swimming-before-or-after-vaccinations-no-params.json')
13-
148
// Conditions - Responses
159
const conditionsRootNoParamsResponse = require('./responses/conditions-root-no-params.json')
1610
const conditionsAcanthosisNigricansResponse = require('./responses/conditions-acanthosis-nigricans-no-params.json')
@@ -106,90 +100,6 @@ async function root(req, res, next) {
106100
next()
107101
}
108102

109-
// ******************************************************************
110-
// ** Common Health Questions pages
111-
// ******************************************************************
112-
113-
// Live website URL
114-
// https://www.nhs.uk/common-health-questions/
115-
// This sandbox on localhost
116-
// http://localhost:9000/common-health-questions/
117-
// API on Azure API Management
118-
// https://api.nhs.uk/common-health-questions/
119-
// Wagtail (Python) Application (no auth key required)
120-
// https://www.nhs.uk/content-api/common-health-questions/
121-
// Apigee Sandbox environment (no auth key required)
122-
// https://sandbox.api.service.nhs.uk/nhs-website-content/common-health-questions/
123-
// Apigee Integration environment ('apikey' required in Header)
124-
// https://int.api.service.nhs.uk/nhs-website-content/common-health-questions/
125-
// Apigee Production environment ('apikey' required in Header)
126-
// https://api.service.nhs.uk/nhs-website-content/common-health-questions/
127-
async function commonHealthQuestionsRoot(req, res, next) {
128-
res.status(200).json(commonHealthQuestionsRootResponse)
129-
res.end()
130-
next()
131-
}
132-
133-
// Live website URL
134-
// https://www.nhs.uk/common-health-questions/accidents-first-aid-and-treatments/
135-
// This sandbox on localhost
136-
// http://localhost:9000/common-health-questions/accidents-first-aid-and-treatments/
137-
// API on Azure API Management
138-
// https://api.nhs.uk/common-health-questions/accidents-first-aid-and-treatments/
139-
// Wagtail (Python) Application (no auth key required)
140-
// https://www.nhs.uk/content-api/common-health-questions/accidents-first-aid-and-treatments/
141-
// Apigee Sandbox environment (no auth key required)
142-
// https://sandbox.api.service.nhs.uk/nhs-website-content/common-health-questions/accidents-first-aid-and-treatments/
143-
// Apigee Integration environment ('apikey' required in Header)
144-
// https://int.api.service.nhs.uk/nhs-website-content/common-health-questions/accidents-first-aid-and-treatments/
145-
// Apigee Production environment ('apikey' required in Header)
146-
// https://api.service.nhs.uk/nhs-website-content/common-health-questions/accidents-first-aid-and-treatments/
147-
async function commonHealthQuestionsAccidentsFirstAidAndTreatments(req, res, next) {
148-
res.status(200).json(commonHealthQuestionsAccidentsFirstAidAndTreatmentsResponse)
149-
res.end()
150-
next()
151-
}
152-
153-
// Live website URL
154-
// https://www.nhs.uk/common-health-questions/caring-carers-and-long-term-conditions/
155-
// This sandbox on localhost
156-
// http://localhost:9000/common-health-questions/caring-carers-and-long-term-conditions/
157-
// API on Azure API Management
158-
// https://api.nhs.uk/common-health-questions/caring-carers-and-long-term-conditions/
159-
// Wagtail (Python) Application (no auth key required)
160-
// https://www.nhs.uk/content-api/common-health-questions/caring-carers-and-long-term-conditions/
161-
// Apigee Sandbox environment (no auth key required)
162-
// https://sandbox.api.service.nhs.uk/nhs-website-content/common-health-questions/caring-carers-and-long-term-conditions/
163-
// Apigee Integration environment ('apikey' required in Header)
164-
// https://int.api.service.nhs.uk/nhs-website-content/common-health-questions/caring-carers-and-long-term-conditions/
165-
// Apigee Production environment ('apikey' required in Header)
166-
// https://api.service.nhs.uk/nhs-website-content/common-health-questions/caring-carers-and-long-term-conditions/
167-
async function commonHealthQuestionsCaringCarersAndLongTermConditions(req, res, next) {
168-
res.status(200).json(commonHealthQuestionsCaringCarersAndLongTermConditionsResponse)
169-
res.end()
170-
next()
171-
}
172-
173-
// Live website URL
174-
// https://www.nhs.uk/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
175-
// This sandbox on localhost
176-
// http://localhost:9000/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
177-
// API on Azure API Management
178-
// https://api.nhs.uk/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
179-
// Wagtail (Python) Application (no auth key required)
180-
// https://www.nhs.uk/content-api/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
181-
// Apigee Sandbox environment (no auth key required)
182-
// https://sandbox.api.service.nhs.uk/nhs-website-content/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
183-
// Apigee Integration environment ('apikey' required in Header)
184-
// https://int.api.service.nhs.uk/nhs-website-content/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
185-
// Apigee Production environment ('apikey' required in Header)
186-
// https://api.service.nhs.uk/nhs-website-content/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/
187-
async function commonHealthQuestionsChildrensHealthCanMyBabyGoSwimmingBeforeOrAfterVaccinations(req, res, next) {
188-
res.status(200).json(commonHealthQuestionsChildrensHealthCanMyBabyGoSwimmingBeforeOrAfterVaccinationsResponse)
189-
res.end()
190-
next()
191-
}
192-
193103
// ******************************************************************
194104
// ** Conditions pages
195105
// ******************************************************************
@@ -1102,10 +1012,6 @@ async function status(req, res, next) {
11021012

11031013
module.exports = {
11041014
root,
1105-
commonHealthQuestionsAccidentsFirstAidAndTreatments,
1106-
commonHealthQuestionsCaringCarersAndLongTermConditions,
1107-
commonHealthQuestionsChildrensHealthCanMyBabyGoSwimmingBeforeOrAfterVaccinations,
1108-
commonHealthQuestionsRoot,
11091015
conditionsAcanthosisNigricans,
11101016
conditionsAchalasia,
11111017
conditionsAcne,

sandbox/responses/_curl-commands.txt

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
** Root pages **
33
*****************************************************************************************************************
44

5-
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/common-health-questions/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/common-health-questions-root-no-params.json
6-
75
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/conditions/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/conditions-no-params.json
86

97
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/live-well/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/live-well-root-no-params.json
@@ -21,17 +19,6 @@ curl -X GET 'https://api.service.nhs.uk/nhs-website-content/contraception/' -H '
2119
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/vaccinations/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/vaccinations-root-no-params.json
2220

2321

24-
*****************************************************************************************************************
25-
** Common Health Questions pages **
26-
*****************************************************************************************************************
27-
28-
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/common-health-questions/accidents-first-aid-and-treatments/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/common-health-questions-accidents-first-aid-and-treatments-no-params.json
29-
30-
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/common-health-questions/caring-carers-and-long-term-conditions/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/common-health-questions-caring-carers-and-long-term-conditions-no-params.json
31-
32-
curl -X GET 'https://api.service.nhs.uk/nhs-website-content/common-health-questions/childrens-health/can-my-baby-go-swimming-before-or-after-vaccinations/' -H 'apikey: Oq5LuCPc5X69KFlIw6P7TVYrrJHSceX8' >> ./responses/common-health-questions-childrens-health-can-my-baby-go-swimming-before-or-after-vaccinations-no-params.json
33-
34-
3522
*****************************************************************************************************************
3623
** Conditions pages **
3724
*****************************************************************************************************************

0 commit comments

Comments
 (0)