AccountOperation
Offchain configurable account transaction and key authorization operation utilities.
Derives operation hashes, selects owner approvals, serializes transactions, validates operation state, and converts JSON-RPC representations.
Functions
| Name | Description |
|---|---|
AccountOperation.from | Validates and normalizes an account operation. |
AccountOperation.fromRpc | Converts a JSON-RPC account operation to its domain representation. |
AccountOperation.getHash | Derives the deterministic hash for an account operation. |
AccountOperation.selectApprovals | Validates, deduplicates, and selects owner approvals for an operation. |
AccountOperation.serializeKeyAuthorization | Serializes a key authorization with selected owner approvals. |
AccountOperation.serializeTransaction | Serializes an account transaction operation with selected owner approvals. |
AccountOperation.toRpc | Converts an account operation to its JSON-RPC representation. |
Errors
| Name | Description |
|---|---|
AccountOperation.InvalidApprovalError | Thrown when an account operation owner approval is invalid. |
AccountOperation.InvalidOperationError | Thrown when an account operation is malformed or internally inconsistent. |
Types
| Name | Description |
|---|---|
AccountOperation.Base | Fields shared by every account operation. |
AccountOperation.KeyAuthorizationOperation | Account key authorization approval operation. |
AccountOperation.KeyAuthorizationRpc | JSON-RPC account key authorization operation. |
AccountOperation.Operation | Transaction or key authorization account operation. |
AccountOperation.Rpc | JSON-RPC account operation. |
AccountOperation.TransactionOperation | Account transaction approval operation. |
AccountOperation.TransactionRpc | JSON-RPC account transaction operation. |

