API Data: exporting all data in the website to be consumed by others

It is now possible to export all data in the website, through the addition of the share button “API Data”. This way, your PoP website truly becomes a platform, from where 3rd party developers can, through the public API, consume your information and show it on their own websites, interact with mobile apps, etc.

It works for any object type or list of results, such as:

List of posts:

apidata-btn-list

Single post/page:

apidata-btn-post

User:

apidata-btn-user

etc…

Upon clicking on the button, a modal window appears showing the corresponding URL to access the data, and a preview of the JSON code:

apidata-modal

The URL looks like this:

https://getpop.org/en/blog/becoming-a-progressive-web-app/?output=json&module=data&mangled=none

The basic composition of the URL is as follows:

  • The same URL as the post, user profile, etc
  • Addition of parameters:
    • output=json: To retrieve the data as a JSON code
    • module=data: include only the object data, ignore the configuration data
    • mangled=none: do not mangle the output (it makes the code more legible and understandable)

Enjoy!

Welcome to the PoP framework!
Break the information monopoly

the PoP framework is open source software which aims to decentralize the content flow and break the information monopoly from large internet corporations. Read more.


Sign up to our newsletter: