Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Just as with the composer, the GCS does not have any conventional APIs. 

We will take the same approach as we did with the composer, explaining how it works, and the features that it offers.

But before that, let's look at the workflow we would have to go through to generate a service without the GCS:

  • create config.js containing service information and API configuration
  • create model.js containing function that handle calls to the databases to be supported. A separate model.js file is required for every supported database.
  • create BLModule.js containing the business logic that will implement the service features.
  • create index.js bridging the above files together.


Now let's see how things look like when we invoke the use of the GCS.

To access the UI of the GCS start by making sure the GCS service is running and logging into the SOAJS dashboard and selecting the "Develop" pillar, then "Content Builder" in the left-hand side menu.

Note
titleQuick Reminder

Remember that you need to have started the controller, urac, and dashbaord services all in the dashbaord environment (SOAJS_ENV=dashboard) to be able to access the dashboard!

Image Added


This screen allows the user to name their service and select which database to use.


Image Added


The cluster to be used must be previously created.

After this information is specified, this next screen appears:


Image Added


Clicking on "Add New Input":


Image Added


Here, wre can choose how many inputs our APIs should have along with their properties.

On the next screen, we will we fill out the schema of our service by specifying different parameters we want our service to use.


Image Added

Image Added


Finally, we can add our service's APIs:


Image Added

Image Added


Here we specify which API method and type, along with the default error code (that was previously configured) among other API information.

Once completed, this screen will be visible:


Image Added


Now just click "Generate Service Schema" and that's it!

You have a running service generated by the GCS!