Blocks account out of band with the operator-supplied reason.
account accepts an AccountId or a numeric/string identifier.
Throws AccountIdError on an invalid identifier.
Blocks every account in group with the operator-supplied reason.
group accepts an AccountGroupId or a numeric/string identifier.
Throws AccountBlockError (err.kind === "ReservedGroup") when group
is the reserved default group, or ParamError on an invalid identifier.
Clears the currency configured for account.
This changes configuration only; it does not recompute holdings, average entry prices, or realized P&L.
account accepts an AccountId or a numeric/string identifier.
Throws AccountIdError on an invalid account identifier.
Clears the fallback currency configured for group.
AccountGroupId.DEFAULT() selects the global fallback tier. This changes
configuration only; it does not recompute holdings, average entry prices,
or realized P&L.
group accepts an AccountGroupId or a numeric/string identifier.
Throws ParamError on an invalid group identifier.
Returns the group of account, or undefined when it is unregistered.
account accepts an AccountId or a numeric/string identifier.
Throws AccountIdError on an invalid identifier.
Atomically registers every account in accounts into group.
accounts is an iterable of AccountId or numeric/string identifiers;
group accepts an AccountGroupId or a numeric/string identifier.
Throws AccountGroupRegistrationError on a conflict, or
ParamError/AccountIdError on a bad input.
Replaces the stored reason for an already-blocked account.
account accepts an AccountId or a numeric/string identifier.
Throws AccountBlockError (err.kind === "AccountNotBlocked") when
account is not currently blocked, or AccountIdError on an invalid
identifier.
Replaces the stored reason for an already-blocked group.
group accepts an AccountGroupId or a numeric/string identifier.
Throws AccountBlockError when group is the reserved default group
(err.kind === "ReservedGroup") or is not currently blocked
(err.kind === "GroupNotBlocked"), or ParamError on an invalid
identifier.
Sets the currency used by account-aware policies for account.
This changes configuration only; it does not recompute holdings, average entry prices, or realized P&L.
account accepts an AccountId or a numeric/string identifier. asset
must be a valid asset identifier.
Throws AccountIdError on an invalid account identifier or AssetError
on an invalid asset identifier.
Sets the fallback currency used by account-aware policies for group.
AccountGroupId.DEFAULT() selects the global fallback tier. This changes
configuration only; it does not recompute holdings, average entry prices,
or realized P&L.
group accepts an AccountGroupId or a numeric/string identifier.
asset must be a valid asset identifier.
Throws ParamError on an invalid group identifier or AssetError on an
invalid asset identifier.
Unblocks account, clearing any block on it.
account accepts an AccountId or a numeric/string identifier.
Throws AccountIdError on an invalid identifier.
Unblocks every account in group.
group accepts an AccountGroupId or a numeric/string identifier.
Throws AccountBlockError (err.kind === "ReservedGroup") when group
is the reserved default group, or ParamError on an invalid identifier.
Atomically removes every account in accounts from group.
accounts is an iterable of AccountId or numeric/string identifiers;
group accepts an AccountGroupId or a numeric/string identifier.
Throws AccountGroupRegistrationError on a conflict, or
ParamError/AccountIdError on a bad input.
Handle to the engine's account-group registry, currency configuration, and block controls.
Obtained from
Engine.accounts(). It shares the engine's single account control state, so changes made through it are visible to every other handle and to running policies.