Description
This library allows you to quickly annotate your doctrine entities into restful resources. It comes shipped with it's own internal router, and can be used standalone or alongside your existing framework stack. Routes are mapped to either a default or customised service action that takes care of handling requests.
Setting up endpoints is as easy as adding in a simple annotation to an entity
Drest alternatives and similar libraries
Based on the "API" category.
Alternatively, view Drest alternatives based on common mentions on social networks and blogs.
-
API Platform
Create REST and GraphQL APIs, scaffold Jamstack webapps, stream changes in real-time. -
PHP-CRUD-API
Single file PHP script that adds a REST API to a SQL database -
Firebase Admin SDK for PHP
Unofficial Firebase Admin SDK for PHP -
Restler
Simple and effective multi-format Web API Server to host your PHP API as Pragmatic REST and/or RESTful API -
wsdl2phpgenerator
Simple utility and class library for generating php classes from a wsdl file. -
Hateoas
A PHP library to support implementing representations for HATEOAS REST web services. -
OverblogGraphQLBundle
This bundle provides tools to build a complete GraphQL API server in your Symfony App. -
Pinterest Bot for PHP
This PHP library will help you to work with your Pinterest account without using any API account credentials. -
Symfony GraphQl Bundle
Pure PHP implementation of GraphQL Server โ Symfony Bundle -
PSX Framework
PSX is an innovative PHP framework dedicated to build fully typed REST APIs. -
Slack for PHP
A simple PHP package for sending messages to Slack, with a focus on ease of use and elegant syntax. -
chubbyphp-framework
A minimal, highly performant middleware PSR-15 microframework built with as little complexity as possible, aimed primarily at those developers who want to understand all the vendors they use. -
Behapi
Behat extension for those who want to write acceptances tests for apis -
cidaas SDK for php
With this SDK, you can integrate cidaas smoothly and with minimal effort into your PHP application. It enables you to map the most important user flows for OAuth2 and OIDC compliant authentication. Secure โ Fast โ And unrivaled Swabian. -
Personio SDK for PHP
Interact with Personio from your PHP application. -
yii2-fractal
A set of utils and actions for build API following JSON:Api specification, based on league/fractal -
icanhazstring/expressive-hashids-middleware
PSR-15/PSR-7 compliant middleware using ivanakimov/hashids.php
Clean code begins in your IDE with SonarLint
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Drest or a related project?
README
Drest
Dress up doctrine entities and expose them as REST resources
This library allows you to quickly annotate your doctrine entities into restful resources. It comes shipped with it's own internal router, and can be used standalone or alongside your existing framework stack. Routes are mapped to either a default or customised service action that takes care of handling requests.
Setting up endpoints is as easy as adding in a simple annotation to an entity
/* @Drest\Resource(
* routes={
* @Drest\Route(
* name="get_user",
* route_pattern="/user/:id",
* verbs={"GET"}
* )})
* @ORM\Table(name="user")
* @ORM\Entity
*/
class User
{
.......
}
// hitting [GET] http://myapplication.com/user/123 may return:
{
"user": {
"name": "lee",
"email": "[email protected]"
... + other attributes set up to be exposed ...
}
}
Documentation
Check out how to use drest by reading the documentation
Features
Quickly annotate existing Doctrine entities to become a fully functional REST resource.
Utilises the internal router for matching resource route patterns.
Specify what data you want to expose from your entities (including relations), or let the client choose!
Generate data objects using exposable data for your API users to consume.
Comes shipped with both JSON and XML representations, or you can create your own.
Allows media type detection from your client requests, getting you one step close to RMM level 3.
Use it independently from your existing framework stack, or alongside it.
Allows extension points so you can configure requests to your specific needs.
*Note that all licence references and agreements mentioned in the Drest README section above
are relevant to that project's source code only.