Stream: implementers
Topic: CodeSystem id vs url
John Moehrke (Jul 27 2017 at 20:40):
What is the difference/similarity between CodeSystem.id and CodeSystem.url? I feel like I want to put the same URL there, the URL that the CodeSystem will live at... but I am not sure.
Grahame Grieve (Jul 27 2017 at 20:43):
the canonical URL is fixed by the author, and never changes as it is copied from server to server. Customarily, the author fixes the canonical URL so that it implies the id that the resource has when it lives at it's canonical location. So for example, I am publishing an IG at http://example.org/fhir/my-ig
Grahame Grieve (Jul 27 2017 at 20:44):
the canonical URL will be http://example.org/fhir/my-ig/CodeSystem/mycs and the id will be mycs, and the canonical URL should resolve to the code system
Grahame Grieve (Jul 27 2017 at 20:44):
none of this is required though. The IG publisher encourages this but does not enforce it
Grahame Grieve (Jul 27 2017 at 20:46):
the id will change, so e.g. if you post the same resource to registry.fhir.org (once it's set up in a few weeks), the canonical URL will still be http://example.org/fhir/my-ig/CodeSystem/mycs, but it may need/decide to change the id since they cannot be duplicated locally.
John Moehrke (Jul 27 2017 at 20:48):
Likely easier if I as using the IG Publisher... but I am not. Mostly because I have no idea where to start with that. So I am using Simplifier, Forge, and ClinFHIR...
John Moehrke (Jul 27 2017 at 20:50):
I am writing a IG for AuditEvent. Starting with StructureDefinition for RESTful Query. And adding a CodeSystem for IHE transaction numbers, which are commonly used in IHE specifications of audit events per 'other' transaction events.
Grahame Grieve (Jul 27 2017 at 20:50):
we're working on integration between simplifier and the IG publisher, and also we're starting to work on an IG publisher tutorial
John Moehrke (Jul 27 2017 at 20:51):
Im fresh meat to help review and improve that...
Peter Jordan (Jul 27 2017 at 20:55):
Interesting. Thus far my implementation for SNOMED CT has been to use "SNOMED CT" as the CodeSystem.id so that the Code System can be reached at [myserver url]/CodeSystem/SNOMED CT. I've assigned "http://snomed.info/sct" to the CodeSystem.url property and left the CodeSystem.identifier property empty. Is this correct?
Grahame Grieve (Jul 27 2017 at 20:56):
you can't have a space in your id
Grahame Grieve (Jul 27 2017 at 20:56):
other than that it's not wrong
Peter Jordan (Jul 27 2017 at 21:02):
Thanks, will fix that. It looked wrong the minute I typed it and none of my other Code System IDs have a space. In terms of operations, all requests seem to use the system parameter and I attempt to match that with the Code System url or id.
Grahame Grieve (Jul 27 2017 at 21:05):
system parameter should always match the canonical
John Moehrke (Jul 27 2017 at 21:06):
Here is my challenge. IHE has a set of codes for each of the IHE defined transactins (e.g. ITI-18). These codes are used in AuditEvents.subtype. Within IHE the code system identifier is "urn:ihe:event-type-code". I have created (draft) these codes, but don't know where they will eventually live. So far I have an ftp://ftp.ihe.net, or experimentally a github space...
Grahame Grieve (Jul 27 2017 at 21:07):
well, then you don't have a challenge. the code system URL is urn:ihe:event-type-code
Grahame Grieve (Jul 27 2017 at 21:07):
irrespective of the canonical location
John Moehrke (Jul 27 2017 at 21:09):
but CodeSystem.url definition says it SHALL be a URL. So according to that I can't use a URI... which is it?
Grahame Grieve (Jul 27 2017 at 21:10):
where does it say that?
John Moehrke (Jul 27 2017 at 21:10):
http://build.fhir.org/codesystem-definitions.html#CodeSystem.url
John Moehrke (Jul 27 2017 at 21:10):
the definition
John Moehrke (Jul 27 2017 at 21:10):
does seem to conflict with everything else said... but it is right there
Grahame Grieve (Jul 27 2017 at 21:11):
ah yes. the second sentence should start 'this SHALL be URI" not a "URL". can you create a task to correct that?
Grahame Grieve (Jul 27 2017 at 21:11):
and in this case, you can follow the comments
John Moehrke (Jul 27 2017 at 21:12):
Yeah.. I will create a tas..... So then this simplifier instance is okay? https://simplifier.net/AuditEventforRESTque/urniheevent-type-code-1
Grahame Grieve (Jul 27 2017 at 21:14):
yes.
John Moehrke (Jul 27 2017 at 21:15):
bug logged at GF#13699
Last updated: Apr 12 2022 at 19:14 UTC