REST main annotations
- Last Updated: March 12, 2026
- 1 minute read
- OpenEdge
- Version 13.0
- Documentation
REST main annotation makes an ABL procedure or class, or an external procedure file available as a REST resource. This annotation must precede any ABL statement in the procedure or class file.
The illustration below provides an example of REST main
annotation:@openapi.openedge.export FILE(type="REST",
executionMode="{external | single-run | singleton}", useReturnValue="{true |
false}", writeDataSetBeforeImage="{true | false}").
- File
- This keyword specifies that the annotation applies to an ABL class or procedure level. This is a mandatory attribute for main annotation.
- type
- This attribute specifies the type of defined service such as
RESTfor a REST service orDataObjectfor a DataObject service. This is a mandatory attribute. - executionMode
- This attribute specifies how the ABL class or procedure, or an external procedure runs. If
you specify the value as
EXTERNAL, the procedure runs externally, the valueSINGLE-RUNallows you to call internal procedures and user defined functions in a procedure file, and the valueSINGLETONallows you to call methods in a class file or internal procedures in a procedure file. This is a mandatory attribute. - useReturnValue
- This attribute specifies whether a return string is used for procedures. The default value is false. This is an optional attribute.
- writeDataSetBeforeImage
- This attribute specifies whether before-image data is written out when ProDataSet parameters are serialized as XML. Before-image is not supported for JSON. The only valid value for REST is false. This is an optional attribute.