Entity-Driven CRUD, REST & GraphQL
Built on Symfony
A PHP framework layered on top of Symfony, leveraging its dependency injection, routing, and Doctrine ORM integration — adding conventions specifically optimized for rapid API generation rather than requiring hand-written controllers for every endpoint.
Entity → Full CRUD API
#[ApiResource]
class Product
{
#[ApiProperty(identifier: true)]
public int $id;
#[Assert\NotBlank]
public string $name;
#[Assert\Positive]
public float $price;
}
// generates GET/POST/PUT/DELETE /products, /products/{id} automatically
// plus OpenAPI docs and a Swagger UI-style interface — no controllers writtenAttributes on the entity drive endpoint generation, validation (via Symfony's Validator), and documentation — all from one source, so docs can't drift from actual behavior the way a separately-authored OpenAPI spec can.
REST + GraphQL from One Definition
The same entity definitions can serve both REST and GraphQL simultaneously — accommodating consumers with different preferences (cacheable resource access vs. precise field selection) without maintaining two separate backend implementations of the same logic.
Filtering, Pagination & Sorting
Common collection-query needs (GET /products?price[gte]=10&order[name]=asc) are configured declaratively on the entity rather than hand-implemented per endpoint.
Keep your own version of these notes — editable, searchable, and organised by your stack.
Start free