This repository houses example projects to accompany my article Web APIs with mORMot, though you might find The ORM in mORMot a useful supplementary read.
These projects depend on the mORMot framework, which they expect to find on your search path. See Getting started with mORMot and Delphi for help setting things up. I created the project files using Delphi 10.3.1 Starter but the code in the .pas files should be compatible with just about any version of Delphi.
In the root folder, there is a file called postman_collection.json
. If you import this into Postman, you will find several example requests you can use to test the running applications. These are grouped into folders that echo the directory structure of the repo itself.
The project in this directory demonstrates Option #1: The REST ORM from my article.
This project extends the first project to demonstrate Option #2: Publishing a methods-based service.
This project further builds on the second project to demonstrate Option #3: Publishing an interface-based service.
This directory contains units that are common to the three sample projects.