ActionInvocation
Record in Oadm.Sdk.Actions · Oadm.Sdk.dll
One run of an action on one target (a device, or none for actions without IActionPlugin.NeedsDevice). Settings are the action’s settings with password fields decrypted and the fields of a chosen recipient merged in under their own keys.
public sealed record ActionInvocation(Guid RuleId, string RuleName, ActionEdge Edge, JsonElement Settings, IDeviceInfo? Device, ActionTrigger Trigger)Guide: Event rules
Parameters
RuleId: The rule.RuleName: Its name.Edge: Why the action runs.Settings: The settings of the action, passwords decrypted, a chosen recipient’s fields merged in.Device: The target device; null for actions without devices.Trigger: What happened.
Properties
Section titled “Properties”Device
Section titled “Device”IDeviceInfo? Device { get; init; }The target device; null for actions without devices.
ActionEdge Edge { get; init; }Why the action runs.
RecipientIds
Section titled “RecipientIds”IReadOnlyDictionary<string, Guid> RecipientIds { get; init; }The chosen recipients of this run, field key to recipient id (SDK 0.11.0); empty for an action without recipient fields and for the Test of a recipient, which runs on the values of its form.
RuleId
Section titled “RuleId”Guid RuleId { get; init; }The rule.
RuleName
Section titled “RuleName”string RuleName { get; init; }Its name.
Settings
Section titled “Settings”JsonElement Settings { get; init; }The settings of the action, passwords decrypted, a chosen recipient’s fields merged in.
Trigger
Section titled “Trigger”ActionTrigger Trigger { get; init; }What happened.
Methods
Section titled “Methods”string? Get(string key)A setting as text (null when missing or null).
GetBool
Section titled “GetBool”bool GetBool(string key)A check box setting.
GetInt
Section titled “GetInt”int GetInt(string key, int fallback)A number setting; fallback when missing or not a number.
GetPairs
Section titled “GetPairs”IReadOnlyList<KeyValuePair<string, string>> GetPairs(string key)The rows of a ActionFieldType.KeyValues setting, in order; rows without a name are left out.