Everything before “/Patient” or “/Encounter” is called the server’s base URL - and it can look like anything you wish. In our examples, we often use “/fhir/” as part of the URL, but that’s not a requirement. Some servers may provide different endpoints for each FHIR release they support, and if so, including the name of the FHIR version in the URL is convenient for readers, but again is not required.
What your base URL is going to be depends entirely on how you host your site, how many endpoints you have, etc. Ideally they should be human-readable because that’s nicer for implementers, but there are no rules beyond the base rules for URLs generally.
@lloyd I think the main point we would like to clarify is if the fullURL must be a valid url or it serves just as a pointer. In the example cited by @Rodrigo_Lopes, the url contains the string “microservice-fhir-base” because we separate our endpoints in some microservices. But if in the future we decided to change how the microservices are hosted, or simply change the name of them, how should it be treated? We should do some treatment to keep the url the same, as some resources could be already in use for other partners or it could be done and the old resources will have a fullURL that now it’s not valid anymore?
We would like to omit this part in the fullURL in the sake of not compromising with the current structure of our microservices, using “https://acme.com.br/fhir/Encounter/XXX” as fullURL. Is it against the specification?
The fullUrl is expected to be the location you could perform a Read to retrieve the current version of the resource. The only exception is if you’re dealing with a resource that doesn’t have a RESTful endpoint at all, in which case you must use the “urn:uuid:…” approach.
It’s possible that resources get moved, in which case old locations will no longer resolve (though ideally there’d be redirects). What matters is that the location exposed represents the ‘current’ location of the resource.