FHIR Chat · Validation of messages and operations · IG creation

Stream: IG creation

Topic: Validation of messages and operations


view this post on Zulip Kevin Mayfield (Mar 14 2022 at 07:39):

More what is the best approach?

Should we lean on profiles or rely more on OperationDefinition and MessageDefinition resources.

For FHIR Messages I've already gone down the route of extending validation to use MessageDefinition (to check the focused resources are following the profile specified in the message definition).
I'm looking at extending this to operations and if a Parameters resource is present, this should have the OperationDefinition and that needs to be followed.

I think I'd rather not have both profiles and Message/Operation Definition with similar rules which allows them to get out of step.

view this post on Zulip Lloyd McKenzie (Mar 14 2022 at 14:16):

OperationDefinition and MessageDefinition don't really validate instances, they validate interface behavior. I would definitely expect to have a profile (or, for messages, GraphDefinition) that defines the content. (I was unsuccessful in stripping the parameters from OperationDefinition and having them defined exclusively in StructureDefinition.)

view this post on Zulip Kevin Mayfield (Mar 15 2022 at 05:33):

I'll take a look. I think it's possible to create a profile on the fly from the OperationDefinition and use that for testing.
I don't like the idea of documenting twice - one for testing (profile) and another for documentation. They can easily get out of step.

view this post on Zulip Kevin Mayfield (Mar 15 2022 at 05:40):

The main issue around that is

Screenshot-2022-03-15-at-05.38.52.png

if type is a Resource, then would want to specify a profile. This constraint prevents that.

view this post on Zulip Grahame Grieve (Mar 15 2022 at 05:45):

one reason it's not a profile per se is that the parameters can be in HTTP formats, not a parameters resource

view this post on Zulip Grahame Grieve (Mar 15 2022 at 05:46):

I could extend the validator to validate an HTTP request/response against an OperationDefinition

view this post on Zulip Kevin Mayfield (Mar 15 2022 at 06:47):

Fingers crossed - we may be able to help with that.

view this post on Zulip Lloyd McKenzie (Mar 15 2022 at 13:11):

Even if they can be passed in the URL, you might still need the capabilities of profile to fully define what's going on. There are a whole bunch of constraints that ElementDefinition allows that OperationDefinition doesn't.

view this post on Zulip Grahame Grieve (Mar 15 2022 at 19:56):

but there are also things going on that StructureDefinition doesn't deal with


Last updated: Apr 12 2022 at 19:14 UTC