You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Added more information regarding modularised content
* Text update
* Moved health aspects in to a details/summary element
* Removed old list of health aspects
* Added information on the Schema page types
Copy file name to clipboardExpand all lines: specification/nhs-website-content-api.yaml
+85-32Lines changed: 85 additions & 32 deletions
Original file line number
Diff line number
Diff line change
@@ -72,45 +72,98 @@ info:
72
72
73
73
We create modules by adding labels (health aspects) to sections of content on our web pages. For example, on our medical condition pages we have labels (health aspects) for sections on "Overview", "Symptoms", "Treatments", "Causes" and more. These labels (health aspects) are based on international standards for structured data from [Schema.org](https://schema.org/HealthAspectEnumeration). Before being made available, each module is checked by our clinical team to make sure it remains accurate and safe to use in isolation.
74
74
75
-
Here are the 31 health aspects that we currently have available for modularisation, in order of frequency of use:
<p class="nhsd-m-expander__heading nhsd-t-body">List of health aspects</p>
87
+
</div>
88
+
</summary>
89
+
<div class="nhsd-m-expander__content-container">
90
+
<p>Here are the 31 health aspects that we currently have available for modularisation, in order of frequency of use:</p>
91
+
<ul>
92
+
<li>OverviewHealthAspect</li>
93
+
<li>SymptomsHealthAspect</li>
94
+
<li>TreatmentsHealthAspect</li>
95
+
<li>CausesHealthAspect</li>
96
+
<li>MedicalHelpNonurgentHealthAspect</li>
97
+
<li>SelfCareHealthAspect</li>
98
+
<li>MedicalHelpUrgentHealthAspect</li>
99
+
<li>MedicalHelpEmergencyHealthAspect</li>
100
+
<li>DiagnosisHealthAspect</li>
101
+
<li>PreventionHealthAspect</li>
102
+
<li>SideEffectsHealthAspect</li>
103
+
<li>LivingWithHealthAspect</li>
104
+
<li>SuitabilityHealthAspect</li>
105
+
<li>InteractionsHealthAspect</li>
106
+
<li>UsageOrScheduleHealthAspect</li>
107
+
<li>PregnancyHealthAspect</li>
108
+
<li>RisksOrComplicationsHealthAspect</li>
109
+
<li>PrognosisHealthAspect</li>
110
+
<li>BenefitsHealthAspect</li>
111
+
<li>ContagiousnessHealthAspect</li>
112
+
<li>WhatHappensHealthAspect</li>
113
+
<li>PreparationHealthAspect</li>
114
+
<li>ResultsHealthAspect</li>
115
+
<li>TypesHealthAspect</li>
116
+
<li>ContraindicationsHealthAspect</li>
117
+
<li>GettingAccessHealthAspect</li>
118
+
<li>WarningHealthAspect</li>
119
+
<li>EffectivenessHealthAspect</li>
120
+
<li>HowItWorksHealthAspect</li>
121
+
<li>IngredientsHealthAspect</li>
122
+
</ul>
123
+
</div>
124
+
</details>
125
+
</div>
107
126
108
127
### Getting modularised content
109
128
110
129
To get modularised content, you can use the boolean `modules` query parameter in the [conditions/*](#get-/conditions/*) and [medicines/*](#get-/medicines/*) endpoints. This will return the modularised version of the page (if there is one). If the requested page has not been modularised, the full page will be returned.
111
130
112
131
You can get a list of which pages have (and have not) been modularised and which health aspects they contain by calling the `/manifest/pages/` endpoint.
113
132
133
+
## Schema page types
134
+
135
+
Throughout the NHS website we have a couple of page models which are defined using the `@type` property. It is a good thing to implement each page type into your product, as multiple page types can be used within in a single genre (conditions, live-well, medicines, etc).
136
+
137
+
1. **WebPage** — This is the default type and is [defined by Schema.org](https://schema.org/WebPage)
138
+
139
+
2. **MedicalWebPage** — A web page that provides medical information and is [defined by Schema.org](https://schema.org/MedicalWebPage)
140
+
141
+
Here is a list of properties for each schema page type we are currently using:
142
+
143
+
| WebPage | MedicalWebPage |
144
+
| ---------------- | ------------------- |
145
+
| @context | @context |
146
+
| @type | @type |
147
+
| name | name |
148
+
| copyrightHolder | copyrightHolder |
149
+
| license | license |
150
+
| author | author |
151
+
| about | about |
152
+
| description | description |
153
+
| url | url |
154
+
| genre | genre |
155
+
| keywords | keywords |
156
+
| dateModified | dateModified |
157
+
| lastReviewed | lastReviewed |
158
+
| breadcrumb | breadcrumb |
159
+
| hasPart | hasPart |
160
+
| relatedLink | relatedLink |
161
+
| contentSubTypes | contentSubTypes |
162
+
| mainEntityOfPage | mainEntityOfPage |
163
+
| | alternativeHeadline |
164
+
165
+
It is worth noting that the `genre` property is what we use to define which section the article sits in, and the `@type` is used to define how that article is structured.
166
+
114
167
## API status
115
168
This API has moved from the [NHS website developer portal](https://developer.api.nhs.uk/).
116
169
It is currently [in production](https://digital.nhs.uk/developer/guides-and-documentation/reference-guide#statuses).
0 commit comments