Skip to content

Commit 91bb734

Browse files
committed
#29 update README
1 parent 89b8fbc commit 91bb734

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,20 @@ Encrypts a transaction object using the BLS threshold encryption public key(s) f
9393

9494
---
9595

96+
### `BITE.encryptTransactionWithCommitteeInfo(tx, committees)`
97+
98+
Static method that encrypts a transaction object using the provided committee information, avoiding an internal RPC call to fetch committees.
99+
100+
- **Parameters**:
101+
- `tx`: An object containing `data` and `to` fields as hex strings.
102+
- `committees`: `Array` – An array of committee info objects (as returned by `getCommitteesInfo`).
103+
- **Returns**: `Promise<Transaction>` – The encrypted transaction with modified `data` and `to` fields.
104+
105+
**Use Cases**:
106+
- **Offline / Cached Encryption**: When committee information is already known or cached, preventing redundant RPC calls.
107+
108+
---
109+
96110
### `bite.encryptMessage(message)`
97111

98112
Encrypts a raw hex-encoded message using the BLS threshold encryption from the configured BITE provider.

0 commit comments

Comments
 (0)