Welcome to Dunglas's API platform - a fully-functional Symfony2 application that you can use as the skeleton to build a hypermedia and auto-discoverable REST API relying on internet standards.
It provides JSON-LD and Hydra support out of the box.
Use Composer to create your new project:
composer create-project dunglas/api-platform my-api
A default application representing a bookstore is installed by default.
Run bin/console server:start
and open http://localhost:8000
in any
HTTP client to play it.
Give a try to HydraConsole to leverage JSON-LD and Hydra features.
Dunglas's API platform provides rock solid fundations to build your API:
-
The full power of the Symfony framework and its ecosystem;
-
Doctrine ORM/DBAL;
-
PHP Schema to generate Doctrine entities (with Symfony validation and extended PHPDoc) from [Schema.org][8] types.
-
DunglasJsonLdApiBundle to expose in minutes your entities as a JSON-LD and Hydra enabled hypermedia REST API.
-
An AppBundle you can use to start coding;
-
Annotations enabled for everything;
-
Swiftmailer and Twig to create beautiful emails;
It comes pre-configured with the following bundles:
-
Symfony - Dunglas's API platform is built on top of the full-stack Symfony framework
-
DunglasJsonLdApiBundle - Creates powerful Hypermedia APIs supporting JSON-LD and Hydra
-
NelmioCorsBundle - Support for CORS headers
-
FosHttpCacheBundle - Add powerful caching capacities, supports Varnish, Nginx a built-in PHP reverse proxy
-
SensioFrameworkExtraBundle - Adds several enhancements, including template and routing annotation capability
-
DoctrineBundle - Adds support for the Doctrine ORM
-
TwigBundle - Adds support for the Twig templating engine
-
SecurityBundle - Adds security by integrating Symfony's security component
-
SwiftmailerBundle - Adds support for Swiftmailer, a library for sending emails
-
MonologBundle - Adds support for Monolog, a logging library
-
WebProfilerBundle (in dev/test env) - Adds profiling functionality and the web debug toolbar
-
SensioDistributionBundle (in dev/test env) - Adds functionality for configuring and working with Symfony distributions
-
SensioGeneratorBundle (in dev/test env) - Adds code generation capabilities
All libraries and bundles included in Dunglas's API platform are released under the MIT or BSD license.
Json Web Token is a lightweight and popular way to handle authentication in a stateless way. Install LexikJWTAuthenticationBundle to adds JWT support to Dunglas's API platform.
Oauth support can also be easily added using FOSOAuthServerBundle.
Enjoy!
Built by Kévin Dunglas.