Ramonskis Blog

A Microblog powered by Octopress

The Need for APIs - or Why I Built a JSON API for the Plone CMS

| Comments

I started with Plone development already 8 years ago and I was really enthusiastic in the beginning of that time as it was real fun to develop for this great system. I have been a real Plone/Python/Backend-Developer guy these days.

But somehow over the years something changed and more and more I lost the interest on Plone …

What happened here or why did I feel this disfavour?

I really don’t think that Plone is a bad system, it is quite the opposite. In my opinion it has grown to an almost feature complete flagship in the open source CMS world, where people get a lot of cool stuff just out of the box. There are also quite a lot of high quality add-ons which can extend the functionality of Plone and leaves almost no customer wishes open.

It was more the thing that Plone felt sort of clumsy and obsolete to me. It is not that kind of a web system you roll out for a small customer solution where you only need a tiny set of the given features. No, it is for enterprise solutions where the customer needs a training how to use the system and also a maintenance plan for the operational support.

It was also the fact that Plone sites always look like Plone sites. It doesn’t matter what you do or how much effort you put into the CSS or design. Over the years you really get an eye for that…

So what do you need when you want to use some of the features of Plone without the need for the users to face the Plone site at all? Yes. You need a Web API!

But somehow this feature never made it into Plone? Why? I don’t know.

I started to built a package called plone.jsonapi.core which should just serve my needs as I wanted to learn iOS programming and wanted to knit my own web API. I never released the apps I built but after all I knew some Cocoa and ObjectiveC programming:)

Some time ago we (nexiles GmbH) started a new customer project and decided to use Plone after years again. But it should serve more as the backend system in this project than the actual place to work on. The users should not face the Plone UI at all. The whole UI should be realized in ExtJS and it also should be easy to use and fast (even in IE 8).

So I digged out the plone.jsonapi.core package and built a complete JSON API for the customer on top of it. That meant to view, create, update and delete the contents through this API.

Believe me, it was more than one time that I thought “Why didn’t we use flask or django?” And of course it was more than one time I was swearing like a trooper:)

But the project has almost finished today and I ported the functionality of the customers API to an open source project called plone.jsonapi.routes.

Hopefully this will help some other web developers to build modern, fast and intuitive applications on top of Plone without the need to understand how Plone development works at all. And maybe it will get back other developers to use Plone who felt like me:)

I think it is an absolute requirement for modern web systems to provide a sophisticated web interface for their users. Without it they will sooner or later die because they loose their developers and obstruct the possibility that JavaScript UI designers will use the systems at all.

It is absolute clear to me that the solution I provided is awkward and just a patchwork, but maybe this functionality will make it into Plone one day and for the time being, the patchwork will be there:)

You can find the packages here:

and of course on the Python Package Index:

Have fun with it:)

Cheers, ramonski

Comments