REST: POST EHR directory twice, what happens?

What should happen in the EHR directory is created (POST) twice? PUT is used for updates and requires If-Match to prevent conflicting concurrent updates. POST should probably return 409 Conflict if EHR already has a directory?

https://specifications.openehr.org/releases/ITS-REST/latest/ehr.html#directory-directory-post

Yes, I think you are right

I filed an issue for that: https://openehr.atlassian.net/projects/SPECITS/issues/SPECITS-44

I set fixVersion to 1.1.0, although this is actually more of a “bug fix”, so if there ever is a 1.0.2 version released, it should go there.

A bit late to the party here, but we independently did this exactly as described (409 Conflict) in EHRbase.