EDB Postgres Enterprise Manager REST APIs v6.0: Export Custom Probes v10.2

post__probe_custom_export_

Code samples

POST /probe/custom/export/

Export custom probes

Body parameter

{
  "probes": [
    0
  ]
}

Parameters

NameInTypeRequiredDescription
X-Auth-TokenheaderstringtrueToken of authorization
bodybodyCustomProbeExportDatatruenone

Example responses

200 Response
[
  {
    "probe_name": "string",
    "collection_method": "w",
    "enabled": true,
    "target_type": 0,
    "any_server_version": true,
    "interval": 0,
    "lifetime": 0,
    "discard_history": true,
    "platform": "string",
    "probe_code": "string",
    "probe_columns": [
      {
        "pc_name": "string",
        "pc_data_type": "bigint",
        "pc_unit": "string",
        "pc_col_type": "m",
        "pc_graphable": true,
        "pc_calc_pit": true,
        "pc_pit_default": true
      }
    ],
    "alternate_code": [
      {
        "server_version_id": 0,
        "server_probe_code": "string"
      }
    ],
    "internal_name": "string"
  }
]

Responses

StatusMeaningDescriptionSchema
200OKSuccessful responseInline

Response Schema

Status Code 200

NameTypeRequiredRestrictionsDescription
anonymous[allOf]falsenonenone

allOf

NameTypeRequiredRestrictionsDescription
» anonymousCustomProbePostDatafalsenonenone
»» probe_namestringfalsenoneName of the probe.
»» collection_methodstringfalsenoneDefines the method of statistics collection. PEM supports three methods for custom made probes. i.e. SQL, WMI, Batch/Shell script.
  • 'w' stands for WMI script.
    It is applicable for the windows platform only, and target_type will be 100 (i.e. agent).
  • 'b' stands for Batch/Shell script. 'target_type' for this will be always be 100 (i.e. agent). It will behave as batch script on windows otherwise as a shell script.
  • 's' stands for SQL script. It will applicable only for 200 (i.e. server), 300 (i.e. database), 400 (i.e. schema), 500 (i.e. table), 600 (i.e. index), 700 (i.e. sequence), 800 (i.e. function), 900 (i.e. view).
»» enabledbooleanfalsenoneDefines whether the probe is enabled/disabled by default.
»» target_typeintegerfalsenoneDefines the type of the object on which the probe is applicable to.
  • A probe with target_type 100 is responsible for collecting statistics for an agent.
  • A probe with target_type 200 is responsible for collecting statistics for a monitored server.
  • A probe with target_type 300 is responsible for collecting statistics for a database.
  • A probe with target_type 400 is responsible for collecting statistics for a schema.
  • A probe with target_type 500 is responsible for collecting statistics for a table.
  • A probe with target_type 600 is responsible for collecting statistics for a index.
  • A probe with target_type 700 is responsible for collecting statistics for a sequence.
  • A probe with target_type 800 is responsible for collecting statistics for a function.
  • A probe with target_type 900 is responsible for collecting statistics for a view.
»» any_server_versionbooleanfalsenoneDefines whether this probe is applicable to any version of Postgres variant. For more details, please follow the documenation.
»» intervalintegerfalsenoneDefines how frequently the probe will collect the statistics (in seconds).
»» lifetimeintegerfalsenoneDefines the history data retention time (in days). It does not have any effect, if 'discard_history' is set to true.
»» discard_historybooleanfalsenoneDefines whether to discard the history data. It will not store the history of the data for this probe, when 'discard_history' is set to false.
»» platformstringfalsenoneDefines on which platform this probe can run on. It is only applicable to an agent level probe.
»» probe_codestringfalsenoneA SQL/Batch script/Shell script/WMI script to collect the statistics as per definition of the code.
»» probe_columns[object]falsenonenone
»»» pc_namestringfalsenoneName of the column
»»» pc_data_typestringfalsenoneData type of the column.
Supported datatypes are:
      bigint
      char
      decimal
      double precision
      integer
      numeric
      real
      text
      text[]
      timestamp
      timestamptz
»»» pc_unitstringfalsenoneReturns the unit of the column.
»»» pc_col_typestringfalsenoneReturns the columns is part of the primary key of the internal table, or not. 'k' stands for a key column, and 'm' stands for a member/normal column.
»»» pc_graphablebooleanfalsenoneReturns whether the data of the column is graphable on a chart, or not.
»»» pc_calc_pitbooleanfalsenoneReturns whether server calculates the point-in-time for the metric data for this column.
»»» pc_pit_defaultbooleanfalsenoneReturns the metric is stored by point-in-time by default. Please refer the 'Custom Probes' section in the documentation for detailed information.
»» alternate_code[AlternateServerProbeCode]falsenonenone
»»» server_version_idintegerfalsenoneServer version id for the support monitored server
server_version_idDatabase Server
10905PostgreSQL 9.5
10906PostgreSQL 9.6
11000PostgreSQL 10
11100PostgreSQL 11
11200PostgreSQL 12
11300PostgreSQL 13
20905Postgres Plus Advanced Server 9.5
20906Postgres Plus Advanced Server 9.6
21000EDB Postgres Advanced Server 10
21100EDB Postgres Advanced Server 11
21200EDB Postgres Advanced Server 12
21300EDB Postgres Advanced Server 13
»»» server_probe_codestringfalsenoneSQL query to run on the specified server version

and

NameTypeRequiredRestrictionsDescription
» anonymousobjectfalsenonenone
»» internal_namestringfalsenoneInternal name of the probe from the system where probe was exported.
Enumerated Values
PropertyValue
collection_methodw
collection_methodb
collection_methods
pc_data_typebigint
pc_data_typechar
pc_data_typedecimal
pc_data_typedouble precision
pc_data_typeinteger
pc_data_typenumeric
pc_data_typereal
pc_data_typetext
pc_data_typetext[]
pc_data_typetimestamp
pc_data_typetimestamptz
pc_col_typem
pc_col_typek
Info

This operation does not require authentication