Delen via


Data - Retrieve Rules

Haalt de lijst met regels en de bijbehorende eigenschappen op op basis van de opgegeven criteria.

POST http://<Servername>/OperationsManager/data/rules

Aanvraagbody

Media Types: "application/json", "text/json", "application/xml", "text/xml", "application/x-www-form-urlencoded"

Name Type Description
criteria

string

geef de criteria op om te zoeken.

Antwoorden

Name Type Description
200 OK

TableDataResponse

OK. De lijst met regels en de bijbehorende eigenschappen op basis van de opgegeven criteria is opgehaald

Media Types: "application/json", "text/json", "application/xml", "text/xml"

Voorbeelden

RetrieveRules

Sample Request

POST http://<Servername>/OperationsManager/data/rules

[
  "DisplayName like '%MomSdkTest_v3 : Discovery rule to find all instances of  NT Services on a computer%'"
]

Sample Response

{
  "tableColumns": [
    {
      "field": "id",
      "header": "Id",
      "type": null,
      "hidden": true
    },
    {
      "field": "targetid",
      "header": "Target Id",
      "type": null,
      "hidden": true
    },
    {
      "field": "displayname",
      "header": "Display Name",
      "type": null,
      "hidden": false
    },
    {
      "field": "description",
      "header": "Description",
      "type": null,
      "hidden": false
    },
    {
      "field": "enabled",
      "header": "Enabled",
      "type": null,
      "hidden": false
    },
    {
      "field": "targetname",
      "header": "Target",
      "type": null,
      "hidden": false
    }
  ],
  "rows": [
    {
      "id": "54592d73-7c17-1ab2-7b31-0ab9b237ea6e",
      "targetid": "a4201cd2-feff-b19b-997c-38a8a0c0aa59",
      "displayname": "MomSdkTest_v3 : Discovery rule to find all instances of  NT Services on a computer",
      "description": "This rule discovers all instances of Windows NT Services installed on this computer by querying WMI",
      "enabled": "true",
      "targetname": "MomSdkTest_v3 : Windows Computer"
    }
  ]
}

Definities

Name Description
TableColumn
TableDataResponse

TableColumn

Name Type Description
field

string

Naam van de kolom

header

string

Koptekst van de kolom

hidden

boolean

Is de kolom verborgen

type

string

Type kolom

TableDataResponse

Name Type Description
rows

object[]

Tabelrijen met gegevens

tableColumns

TableColumn[]

Tabelkolommen met gegevens