The Open mHealth Schema Library Wordpress plugin generates online documentation for the JSON schemas and sample data contained in a Git repository.
When updated through the Wordpress admin panel, it pulls in each schema, including all versions and sample data, creates a custom post for it in wordpress, and allows the maintainer to enter additional descriptions and metadata.
With each subsequent update, any new schemas found in the repository are added to the library in Wordpress, while existing schemas descriptions and metadata are preserved.
By hand, in this order:
- Go to wordpress.org, get WP, install it
- Install the WP REST API v2 plugin
- Install the Advanced Custom Fields Pro plugin
- Go to plugin on GitHub, go to latest release, download zipfile
- Install plugin in WP
- Go to theme on GitHub, go to latest release, download zipfile
- Install theme on WP
- Follow configuration instructions
Or, using Docker:
(coming soon)
- Click the “Schema Library” tab near the bottom of the admin panel’s left navigation
- Enter the appropriate settings for your organization
- Click “Save Changes”
- Click “Update Schemas” at the bottom of the configuration panel
- Click the “Schemas” tab near the top of the admin panel’s left navigation
- Edit each schema
- Enter relevant meta-data
- Make schema versions visible, as appropriate
- Click “Publish” in the upper right corner of the editing page
If you want to have a dedicated website:
- Install the website
If you want a dedicated page on your existing non-WordPress site:
- Install the website
- Style the wordpress theme to match your site
- Link to the ‘/schemas’ page
If you have a wordpress website, and you would like to include the library in a page that doesn’t already use angular, copy the following files from the theme repository to your theme directory:
- single-schema.php
- archive-schema.php
- template-parts/content-single-schema.php
- omh-schema-library-functions.php
- js/omh-schema-library-functions.js
- js/omh-documentation-utilities.js
- css/omh-schema-library-style.css
- css/images
Then, add include(omh-schema-library-functions.php);
to the end of your theme’s functions.php file.