French developer Kévin Dunglas has released the 1.0.0 beta version of API Platform, an open-source “API-first” PHP framework for creating interoperable single-page applications, native mobile apps, and websites. It is built on Symfony reusable PHP components.
(Related: API management comes of age)
The platform’s interoperability stems from its alignment with the W3C’s Hydra Web standard, the Doctrine Project’s object-relational mapping protocol, and the JSON-LD Web standard. It allows programmers to build, test, document and authenticate a complete production API. The framework also includes a data model generator to help developers reuse common schema types from Schema.org.
Dunglas explained the idea behind his “API-first” framework for Web and mobile applications in a blog post.
“The semantic Web and especially Linked Data is a reality: With the Schema.org initiative and new open Web standards such as JSON-LD, search engines consume structured and machine-readable data at Web scale,” he said. “Not exposing such data decreases interoperability and search engine ranking/efficiency.
“PHP.net, Symfony, Facebook and many others have worked hard to improve and professionalize the PHP ecosystem. The PHP world has closed the gap with most back-end solutions and is often more innovative than them. But in critical area I’ve described previously, many things can be improved. Almost all existing solutions are still designed and documented to create websites the old way: A server generates then sends plain-old HTML documents to browsers.”
API Platform uses an API context system to automate documentation creation and testing, and it uses Symfony bundles within the framework for integrating the APIs of the single-page app, native mobile app or Web application with existing Symfony applications.
The framework requires PHP 5.5 and ships with a built-in Web server for the development environment. Dunglas hopes to release the first stable version of API Platform this month, and in the meantime encourages open-source participation to debug the code, enhance the documentation, and integrate the platform with more front-end development frameworks and libraries.