Retrieves a version of a ruleset with a specified event type. A new version is created each time you change a rule.
eventType required | string Type of event. |
version required | integer >= 1 Version of the ruleset. To retrieve the full related object instead of the ID, expand the response. For more information, see Expand to include embedded objects. |
Ruleset version retrieved.
version | integer Version of the ruleset. | ||||||||||||||
Array of objects (Bind) Binds always execute, regardless of rule based events. A bind is a configuration of an event and one or more actions. | |||||||||||||||
Array
| |||||||||||||||
Array of objects (Rule) Rules can be configured to stop subsequent rules in the event list from being executed. A rule is a configuration of an event and one or more actions. | |||||||||||||||
Array
| |||||||||||||||
createdTime | string <date-time> (CreatedTime) Date and time which is set automatically when the resource is created. | ||||||||||||||
updatedTime | string <date-time> (UpdatedTime) Date and time which updates automatically when the resource is updated. | ||||||||||||||
Array of objects (SelfLink) Related links. | |||||||||||||||
Unauthorized access. Invalid credentials used.
Access forbidden.
Resource not found.
// get version #2 for this event ID const version = await api.events.getRulesVersionDetail({eventType: 'risk-score-changed', version: 2}); // the version exposes the ruleset console.log(version.fields.rules);
{- "version": 0,
- "binds": [
- {
- "id": "4f6cf35x-2c4y-483z-a0a9-158621f77a21",
- "name": "string",
- "labels": [
- "test-rule",
- "category:foo"
], - "status": "active",
- "filter": "string",
- "actions": [
- {
- "name": "add-risk-score",
- "status": "active"
}
]
}
], - "rules": [
- {
- "id": "4f6cf35x-2c4y-483z-a0a9-158621f77a21",
- "name": "string",
- "labels": [
- "test-rule",
- "category:foo"
], - "status": "active",
- "filter": "string",
- "actions": [
- {
- "name": "add-risk-score",
- "status": "active"
}
], - "final": true
}
], - "createdTime": "2019-08-24T14:15:22Z",
- "updatedTime": "2019-08-24T14:15:22Z",
- "_links": [
- {
- "href": "string",
- "rel": "self"
}
]
}