Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. URL prefix - specifies the application context path and the way the server is accessible through the Internet. This is typically http://localhost:8080/openmrs during development and http://example.com/openmrs during production stage.
  2. /ws/rest/metadatasharing/package/  to follow OpenMRS REST patterns
  3. UUID of the package group (a mutual UUID along all package versions)
  4. /latest which indicates that the subscriber will lookup for the latest version of the package
  5. (optional) _.form_ suffix required on OpenMRS versions which don't support webservices.  NoteNote: after upgrading OpenMRS from e.g. 1.6.x to 1.8.1 version the publish URLs will lose this suffix, but old URLs will remain accessible. 

Example of an publis a publish URL: http:/localhost:8080/openmrs/ws/rest/metadatasharing/package/7f2d4731-0a98-4118-8fe0-d4b9731986c6/latest

Example of a curl to this URL

Code Block
xml
xml

<subscriptionHeader id="1">
    <packageHeader id="2" uuid="874f1efb-d73e-4093-9dd9-6e532be3a6fe">
        <dateCreated id="3">2011-08-18 00:30:45</dateCreated>
        <name>Roles</name>
        <description>All available roles</description>
        <openmrsVersion>1.8.2 Build 21762</openmrsVersion>
        <version>5</version>
        <group>7f2d4731-0a98-4118-8fe0-d4b9731986c6</group>
    </packageHeader>
    <contentUri id="4">../7f2d4731-0a98-4118-8fe0-d4b9731986c6/5/download</contentUri>
</subscriptionHeader>

The packageHeader node contains all header information about the package. 

The contentUri node is a relative URI to the place where we can download zipped package with all metadata. 

The download URL is similar to publish URL, but it ends with: %VERSION/download. This allows us to download any published version of the package, but this feature isn't used yet.