Data - Retrieve Rules
Retrieves the list of rules and their properties based on the specified criteria.
POST http://<Servername>/OperationsManager/data/rules
Request Body
Media Types: "application/json", "text/json", "application/xml", "text/xml", "application/x-www-form-urlencoded"
Name | Type | Description |
---|---|---|
criteria |
string |
specify the criteria to search. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
OK.Successfully retrieved the list of rules and their properties based on the specified criteria Media Types: "application/json", "text/json", "application/xml", "text/xml" |
Examples
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"
}
]
}
Definitions
Name | Description |
---|---|
Table |
|
Table |
TableColumn
Name | Type | Description |
---|---|---|
field |
string |
Name of the Column |
header |
string |
Header of the column |
hidden |
boolean |
Is column hidden |
type |
string |
Type of the Column |
TableDataResponse
Name | Type | Description |
---|---|---|
rows |
object[] |
Table Rows of data |
tableColumns |
Table columns of data |