Creating a RAD Server Package

From RAD Studio
Jump to: navigation, search

Go Up to Developing a RAD Server Package


You can create a new RAD Server package by running the RAD Server Package Wizard, as follows:

  1. Open the RAD Server Package Wizard:
    • For Delphi: File > New > Other > Delphi projects > RAD Server > RAD Server Package
    • For C++: File > New > Other > C++Builder projects > RAD Server > RAD Server Package
  2. Select the type of package extension you are creating:
    • Empty package. An empty package does not register a resource in the RAD Server Engine. You can choose it if you plan to add the resource later.
    • Create package with resource. Creates a package with a resource that will extend the REST API of the RAD Server Engine.
    Note: If you are creating a new empty package, select Finish to close the wizard.
    RSPackageWizard.png
  3. Enter additional resource information:
    • Name. The name of the created resource.
    • File type. Select if you want to implement the resource:
      • Data Module: uses the designer and visual components. Select this type if you are creating a FireDAC RAD Server Resource.
      • Unit: uses code.
    RSPackageDataModuleWizard.png
  4. On the Endpoints wizard you can select:
    RAD Server Package Wizard.png
    • Database EndPoints, click Next and a new wizard displays, you can select a FireDAC connection to display the available tables, by selecting a table you expose the access to it.
    Attention: If you use InterBase, install the extensions for the table filter available in the InterBase UDF library.
    Note: For each selected table, the wizard will add an FDQuery and an EMSDataSetResource component to the data module, visible at the design time with the components generated with the selection made above.
    DatabaseEndpoints.png
    • API Documentation to generate the necesary code to support Swagger API Documentation.
    Note: You get the Swagger documentation with no problem even if you have methods without attributes.
  5. Click the Finish button.


After finishing the wizard, you need to implement the resource endpoint methods as you want. See Tutorial: Implementing Your First RAD Server Resource or Tutorial: Implementing a FireDAC RAD Server Resource for more details.
You can also add new RAD Server resources to your existing RAD Server Package. See Adding a RAD Server Module to a RAD Server Package for more information.

See Also