Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
64cf5f4
NRL-518 Validate display as per the definition
axelkrastek1-nhs Nov 27, 2024
dcde0a9
NRL-518 Fix pydantic error reporting
axelkrastek1-nhs Dec 2, 2024
a50f1a5
NRL-518 Update models with mandatory fields
axelkrastek1-nhs Dec 2, 2024
d29aa5f
NRL-518 Add step for upserts, refactor create and upsert into one method
axelkrastek1-nhs Dec 2, 2024
d58fdca
NRL-518 Add default format to default test document reference
axelkrastek1-nhs Dec 3, 2024
548435b
NRL-518 Fix parameter should not be fix to content
axelkrastek1-nhs Dec 3, 2024
84a5f10
NRL-518 Add method to change default parameters for an update
axelkrastek1-nhs Dec 3, 2024
d3f26c6
NRL-518 Add validator method for content and add tests
axelkrastek1-nhs Dec 3, 2024
02a9a7e
NRL-518 Fix default contentType
axelkrastek1-nhs Dec 3, 2024
de90659
NRL-518 Fix integration tests expected without format
axelkrastek1-nhs Dec 3, 2024
48ace9e
NRL-518 Add ContentStability value set
axelkrastek1-nhs Dec 3, 2024
7a6e430
NRL-518 Fix smoke tests missing format
axelkrastek1-nhs Dec 3, 2024
3c6c1b8
NRL-518 Fix unused parameter
axelkrastek1-nhs Dec 3, 2024
4820d08
NRL-518 Fix content_type for smoke test
axelkrastek1-nhs Dec 3, 2024
32e1363
NRL-518 Fix format for smoke tests
axelkrastek1-nhs Dec 3, 2024
7b7f2bd
NRL-518 Add documentation for content validation
axelkrastek1-nhs Dec 4, 2024
6b8e9e6
NRL-518 Add NRLFormatCode valueset
axelkrastek1-nhs Dec 4, 2024
202b4f7
NRL-518 Update postman link in documentation
axelkrastek1-nhs Dec 4, 2024
5a46d45
NRL-518 Remove tests no longer valid due to upstream pydantic validation
axelkrastek1-nhs Dec 5, 2024
e6d10c6
NRL-518 Simplify test, fix lint warnings
axelkrastek1-nhs Dec 5, 2024
1d58d65
NRL-518 Revert contentType regex to simple version
axelkrastek1-nhs Dec 5, 2024
90822a6
NRL-518 Fix lint issue
axelkrastek1-nhs Dec 5, 2024
07fd1e3
NRL-518 Remove checks, pydantic validates that, add invalid contentTy…
axelkrastek1-nhs Dec 5, 2024
3d8f0bd
NRL-518 Improve pydantic diagnostic message
axelkrastek1-nhs Dec 5, 2024
75534a3
NRL-518 ContentStability validation mostly on pydantic
axelkrastek1-nhs Dec 6, 2024
3452fa3
NRL-518 Better naming for scenario
axelkrastek1-nhs Dec 6, 2024
9bc5d31
NRL-518 Better format for single value enum in swagger
axelkrastek1-nhs Dec 6, 2024
52f1d24
NRL-518 Pydantic will ensure extension is always there
axelkrastek1-nhs Dec 6, 2024
f8663e7
NRL-518 Pydantic format validation, fix casing format display
axelkrastek1-nhs Dec 6, 2024
5098eca
NRL-518 Fix integration tests
axelkrastek1-nhs Dec 6, 2024
aca3ca4
NRL-518 Add value set for pydantic diagnostic messages
axelkrastek1-nhs Dec 6, 2024
7886799
NRL-518 Fix smoke tests
axelkrastek1-nhs Dec 6, 2024
3137b90
NRL-518 Fix linting issue
axelkrastek1-nhs Dec 6, 2024
c113df8
NRL-518 Add validation for format code display mismatch
axelkrastek1-nhs Dec 11, 2024
e505b70
NRL-518 Add feature tests for format code display mismatch
axelkrastek1-nhs Dec 11, 2024
85efa9e
NRL-518 Better model inheritance
axelkrastek1-nhs Dec 11, 2024
22523d9
NRL-518 Update narrative
axelkrastek1-nhs Dec 11, 2024
d48ab5a
NRL-518 Move content fhir url strings to constants
axelkrastek1-nhs Dec 12, 2024
64e6312
NRL-518 Remove extension from CodeableConcept
axelkrastek1-nhs Dec 12, 2024
b1cba0a
Merge branch 'develop' into feature/axkr1-NRL-518-validate-context
axelkrastek1-nhs Dec 12, 2024
c6546b2
Merge branch 'develop' into feature/axkr1-NRL-518-validate-context
eesa456 Dec 13, 2024
8b398a7
NRL-518 add import for smoke tests
eesa456 Dec 13, 2024
e58aee9
Merge branch 'develop' into feature/axkr1-NRL-518-validate-context
axelkrastek1-nhs Dec 13, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
90 changes: 82 additions & 8 deletions api/consumer/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1065,15 +1065,19 @@ components:
$ref: "#/components/schemas/Attachment"
description: The document or URL of the document along with critical metadata to prove content has integrity.
format:
$ref: "#/components/schemas/Coding"
$ref: "#/components/schemas/NRLFormatCode"
description: An identifier of the document encoding, structure, and template that the document conforms to beyond the base format indicated in the mimeType.
extension:
type: array
items:
$ref: "#/components/schemas/Extension"
description: Additional content defined by implementations.
$ref: "#/components/schemas/ContentStabilityExtension"
description: Additional extension for content stability.
minItems: 1
maxItems: 1
required:
- attachment
- format
- extension
DocumentReferenceRelatesTo:
type: object
properties:
Expand Down Expand Up @@ -1130,6 +1134,9 @@ components:
type: string
pattern: ([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\.[0-9]+)?(Z|(\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?
description: The date that the attachment was first created.
required:
- contentType
- url
CodeableConcept:
type: object
properties:
Expand All @@ -1146,11 +1153,6 @@ components:
type: string
pattern: "[ \\r\\n\\t\\S]+"
description: A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user.
extension:
type: array
items:
$ref: "#/components/schemas/Extension"
description: Additional content defined by implementations.
Coding:
type: object
properties:
Expand Down Expand Up @@ -1187,6 +1189,78 @@ components:
type: string
pattern: \S*
description: The reference details for the link.
ContentStabilityExtension:
allOf:
- $ref: "#/components/schemas/Extension"
- type: object
properties:
url:
type: string
enum:
- "https://fhir.nhs.uk/England/StructureDefinition/Extension-England-ContentStability"
valueCodeableConcept:
$ref: "#/components/schemas/ContentStabilityExtensionValueCodeableConcept"
required:
- url
- valueCodeableConcept
ContentStabilityExtensionValueCodeableConcept:
allOf:
- $ref: "#/components/schemas/CodeableConcept"
- type: object
properties:
coding:
type: array
items:
$ref: "#/components/schemas/ContentStabilityExtensionCoding"
minItems: 1
maxItems: 1
required:
- coding
ContentStabilityExtensionCoding:
allOf:
- $ref: "#/components/schemas/Coding"
- type: object
properties:
system:
type: string
enum:
- "https://fhir.nhs.uk/England/CodeSystem/England-NRLContentStability"
code:
type: string
enum: ["static", "dynamic"]
display:
type: string
enum: ["Static", "Dynamic"]
required:
- system
- code
- display
NRLFormatCode:
allOf:
- $ref: "#/components/schemas/Coding"
- type: object
properties:
system:
type: string
enum:
- "https://fhir.nhs.uk/England/CodeSystem/England-NRLFormatCode"
description: The system URL for the NRLF Format Code.
code:
type: string
enum:
- "urn:nhs-ic:record-contact"
- "urn:nhs-ic:unstructured"
description: The code representing the format of the document.
display:
type: string
enum:
- "Contact details (HTTP Unsecured)"
- "Unstructured Document"
description: The display text for the code.
required:
- system
- code
- display
Identifier:
type: object
properties:
Expand Down
95 changes: 84 additions & 11 deletions api/producer/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ paths:
{
"system": "https://fhir.nhs.uk/England/CodeSystem/England-NRLFormatCode",
"code": "urn:nhs-ic:unstructured"
"display": "Unstructured document"
"display": "Unstructured Document"
}
]
```
Expand Down Expand Up @@ -1215,7 +1215,7 @@ components:
format:
system: https://fhir.nhs.uk/England/CodeSystem/England-NRLFormatCode
code: "urn:nhs-ic:unstructured"
display: Unstructured document
display: Unstructured Document
context:
event:
- coding:
Expand Down Expand Up @@ -1630,15 +1630,19 @@ components:
$ref: "#/components/schemas/Attachment"
description: The document or URL of the document along with critical metadata to prove content has integrity.
format:
$ref: "#/components/schemas/Coding"
$ref: "#/components/schemas/NRLFormatCode"
description: An identifier of the document encoding, structure, and template that the document conforms to beyond the base format indicated in the mimeType.
extension:
type: array
items:
$ref: "#/components/schemas/Extension"
description: Additional content defined by implementations.
$ref: "#/components/schemas/ContentStabilityExtension"
description: Additional extension for content stability.
minItems: 1
maxItems: 1
required:
- attachment
- format
- extension
DocumentReferenceRelatesTo:
type: object
properties:
Expand Down Expand Up @@ -1695,6 +1699,9 @@ components:
type: string
pattern: ([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\.[0-9]+)?(Z|(\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?
description: The date that the attachment was first created.
required:
- contentType
- url
CodeableConcept:
type: object
properties:
Expand All @@ -1711,12 +1718,6 @@ components:
type: string
pattern: "[ \\r\\n\\t\\S]+"
description: A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user.
extension:
type: array
items:
$ref: "#/components/schemas/Extension"
description: Additional content defined by implementations.

Coding:
type: object
properties:
Expand Down Expand Up @@ -1753,6 +1754,78 @@ components:
type: string
pattern: \S*
description: The reference details for the link.
ContentStabilityExtension:
allOf:
- $ref: "#/components/schemas/Extension"
- type: object
properties:
url:
type: string
enum:
- "https://fhir.nhs.uk/England/StructureDefinition/Extension-England-ContentStability"
valueCodeableConcept:
$ref: "#/components/schemas/ContentStabilityExtensionValueCodeableConcept"
required:
- url
- valueCodeableConcept
ContentStabilityExtensionValueCodeableConcept:
allOf:
- $ref: "#/components/schemas/CodeableConcept"
- type: object
properties:
coding:
type: array
items:
$ref: "#/components/schemas/ContentStabilityExtensionCoding"
minItems: 1
maxItems: 1
required:
- coding
ContentStabilityExtensionCoding:
allOf:
- $ref: "#/components/schemas/Coding"
- type: object
properties:
system:
type: string
enum:
- "https://fhir.nhs.uk/England/CodeSystem/England-NRLContentStability"
code:
type: string
enum: ["static", "dynamic"]
display:
type: string
enum: ["Static", "Dynamic"]
required:
- system
- code
- display
NRLFormatCode:
allOf:
- $ref: "#/components/schemas/Coding"
- type: object
properties:
system:
type: string
enum:
- "https://fhir.nhs.uk/England/CodeSystem/England-NRLFormatCode"
description: The system URL for the NRLF Format Code.
code:
type: string
enum:
- "urn:nhs-ic:record-contact"
- "urn:nhs-ic:unstructured"
description: The code representing the format of the document.
display:
type: string
enum:
- "Contact details (HTTP Unsecured)"
- "Unstructured Document"
description: The display text for the code.
required:
- system
- code
- display
Identifier:
type: object
properties:
Expand Down
Loading
Loading