Define REST API Endpoint Group
We will use Create Customer as a sample to define the REST API Endpoint Group.
- Go to the ##RestEndpointGroup worksheet. AlchemyJ Workbook can support multiple REST API Endpoint Groups worksheets.
- In the Basic Settings section, key in the values as shown below for the basic settings. This defines the endpoint group name.
|Endpoint group path||/customers|
Next, we define the function point Create Customer. In the Function Points section (for output & declaration of function), key in the values as shown below. For REST API, the output must be an object defined in the Data Relationship Schema.
Function Point Path Operation Response Data Type Response Data Address Data Source ID Create Customer /customer POST Object =ajAddress(B21:M24) primary
- In the Input Parameters section, key in the values as shown below. The input is an object and the Data Address is the output data relationship schema which is defined in the business logic sheet.
|Function Point||Style||Name||Data Type||Data Address||Required|
|Create Customer||Request body||customer||Object||=ajAddress(B15:M18)||Yes|
- In the Related Worksheets Section, add the function point name and the related worksheet name.
|Function Point||Worksheet Name|
- Done! All the settings are shown below.