Skip to main content

# Generic Services

If you need to monitor a SaaS solution that has no dedicated integration, you can do so by creating and configuring a Generic Service in Avantra.

## Creating Generic Services​

1. Navigate to System > Cloud Services.
2. Click New.
3. Select the Service Type - Generic Service.
4. Define a Service.
5. Select a Customer.
6. Select a System Role.
7. Click New.

The service is created and is shown in the Services table. The cloud icon by the service's name is grey since the service is not configured and its status is `UNKNOWN` to the system.

To configure the service:

1. Double-click the service (alternatively, select the service in the table and click Open in the toolbar).
   The service is opened with the Properties tab displayed by default.

### Properties specific to service monitoring​

1. In the Cloud Service Info section, select the Monitoring Server from the drop-down list. You can also configure a proxy for the agent while adding a new Cloud Service.
2. In the URL field, enter the URL of the SaaS solution.
3. If you want to assign certain users to be responsible for this service, you may select the corresponding values for the Administrator and Administrator's Deputy fields in the Responsibilities block.
4. Click Apply.

The system will attempt to connect to the service, and if successful, the service's icon will turn green. The system also automatically creates the SO_Connect check which can be seen in the Checks tab.

Now you can associate Custom Checks working with the service's API to start monitoring the aspects you are interested in.

## Assigning Custom Checks​

Creating custom checks are requied to work with the SaaS solution's API. These custom checks need to be based on the RUN_JS custom check type. To create a RUN_JS Custom Check:

1. Navigate to Configuration > Custom Checks.
2. Click New.
   The Create Custom Check dialog opens.
3. Scroll down to the Cloud Services option and click RUN_JS in the right pane.
4. The creation options are displayed at the bottom of the dialog. Enter the Custom Check Name, select a Customer and leave the System Type as Cloud Service.
5. Click Create.
   The Custom Check is created. Its Properties tab is displayed, where you associate the check with the service and specify what exactly the check should monitor.
6. In the Systems section, select what system the check is to be associated with:
   - Pre-Defined System Selector - if you have already created a System Selector, select it from the drop-down.
   - Ad-Hoc Custom Selection - opens a System Selector creation dialog, where you can create a new selector or import an existing one.
7. In the Specific section, enter the Java Script to fetch the required information from the SaaS solution.
8. Click Apply to activate the check.

Now your check is configured and associated with your Cloud Service. You can find it in the service's Checks tab.