Skip to main content

API Page Generator

Every normal user page can be exposed as a Web Service. However, it is advised for performance reasons to provide an API page, which doesn't come with the overhead of fact boxes and OnAfterGetRecord code, etc..

The API Page Generator is a tool to produce AL code for a Page of type API. It will include all fields of a table. This produced code can then be further tailored to the specific need.


Adding all columns, especially FlowFields will cause performance problems. Please reduce the number of fields to your needs.

The API Generator can be found here: Alt text

Search for the required table and select the table record. Click on the Generate AL code action.

Alt text

The generated API is ready to be copied and paste into VS Code.

Alt text


Every API page requires a key of type GUID. The SystemId is used as the primary key. The field will always be named pkID. The API page is produced in a way that the pkID can be set on insert of the record.