Suspected Consent Resource Nested Exception Rule B...
# support
k
Hello Medplum team! I suspect there is a bug with the default Consent resource structure definition. Under the
provision
field, there is another field within that named
provision
, where nested exception rules to the existing provision can be defined. According to the Medplum docs (https://www.medplum.com/docs/api/fhir/resources/consent) and to the resource type, this nested provision field should be an array of provisions, however I get an error anytime I try to update the resource with an array. The error says
Expected single value for property (Consent.provision.provision)
. I just wanted to point out this discrepency in case it wasn't already on your radar! Thank you!
r
Thanks @kwillard95 ! Just filed a ticket to track. https://github.com/medplum/medplum/issues/4299
Out of curiosity, how are you using recursive consent.provisions? Seems like a very advanced use case 🙂
k
Well currently, the outer
provision
is an object that takes a single rule. From my understanding, the inner
provision
should be an array of exceptions to the outer rule, given that certain conditions are met. My use case is for when a
Consent
should be denied for a period of time. I am adding that rule in the nested provision field!
c
Thanks @kwillard95 - good bug. Fix is under review, should be out shortly. https://github.com/medplum/medplum/pull/4304
135 Views