# REST: POST EHR directory twice, what happens? **Category:** [ITS](https://discourse.openehr.org/c/its/41) **Created:** 2020-03-09 06:12 UTC **Views:** 443 **Replies:** 3 **URL:** https://discourse.openehr.org/t/rest-post-ehr-directory-twice-what-happens/432 --- ## Post #1 by @matijap 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 --- ## Post #2 by @sebastian.iancu Yes, I think you are right --- ## Post #3 by @matijap 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. --- ## Post #4 by @birger.haarbrandt A bit late to the party here, but we independently did this exactly as described (409 Conflict) in EHRbase. --- **Canonical:** https://discourse.openehr.org/t/rest-post-ehr-directory-twice-what-happens/432 **Original content:** https://discourse.openehr.org/t/rest-post-ehr-directory-twice-what-happens/432