Skip to content

The OpenCms headless JSON API

With the headless JSON API, OpenCms can be used to manage content in mobile apps.

Mobile apps typically provide a combination of features and information. One challenge is to keep the information in the app current and up to date. The easier it is to manage the content information in the app, the better.

With OpenCms, content managers can use intuitive "drag & drop" based editors to create and update information in mobile apps. App developers can access this information through the OpenCms headless JSON API. Optionally content can be enriched with meta information used to control the layout in the app.

About the demo apps

The demo apps are simple React applications intended to showcase how the OpenCms headless JSON API works. There are no React dependencies, so the same principles can easily be used with other frameworks such as Angular, Vue or whatever else you prefer.

The demos are not intended to be real-world use cases. These apps have been created specifically as short and simple examples that concentrate on various aspects of the OpenCms headless JSON API.

The source code of the demo apps is available on GitHub. It contains useful comments about technical details. The OpenCms headless JSON API documentation explains the features of the API in detail.

About the demo backend / template

Even though this demo uses the OpenCms Mercury template and demo contents, the headless JSON API does NOT depend on Mercury in any way. The headless JSON API works with any OpenCms template.

Enabling the JSON API

The headless JSON API in OpenCms is disabled by default. If it is enabled, published OpenCms contents can be requested via the JSON API. There is a filter mechanism available to restrict the JSON API access to selected contents if required.