PDFs

Versions Compared

Key

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

...

The JSON you send must contain the relevant Collector information.  The required fields describing the Collector vary based on the type of database. Below is a sample JSON request body:

Code Block
{   "type": "MYSQL",   "name": "cart",   "hostname": "localhost",   "port": "3306",   "username": "root",   "password": "singcontroller",   "agentName": "Default Database Agent",   "enabled": "true" }

For more information, see the table in the "UI Collector versus JSON Collector Configuration Field Names" section that follows.

...

  1. Make a GET request for the collector that you want to update.
  2. Copy the JSON response body that is returned by the GET request to a text editor, and modify the fields that you want to update.
  3. Make a POST request for the collector that you want to update, and include the updated JSON. 
     

    Code Block
    POST /controller/rest/databases/collectors/update

    Below is a sample JSON request body:

    Code Block
    {   "type": "MYSQL",   "name": "cart",   "hostname": "localhost",   "port": "3306",   "username": "root",   "password": "singcontroller",   "agentName": "Default Database Agent",   "enabled": "true" }

    The JSON you send must contain all the details of the existing collector with only the fields that you want to modify changed. To ensure you have all the fields, use the Get a Specific Collector call.

...