@@ -21,23 +21,6 @@ Deposit funds for this account in Entrypoint.
2121
2222
2323
24- ### changeRole
25-
26- ``` solidity
27- function changeRole(IAccountPermissions.RoleRequest _req, bytes _signature) external nonpayable
28- ```
29-
30-
31-
32-
33-
34- #### Parameters
35-
36- | Name | Type | Description |
37- | ---| ---| ---|
38- | _ req | IAccountPermissions.RoleRequest | undefined |
39- | _ signature | bytes | undefined |
40-
4124### contractURI
4225
4326``` solidity
@@ -125,28 +108,57 @@ EIP 4337 factory for this contract.
125108| ---| ---| ---|
126109| _ 0 | address | undefined |
127110
128- ### getAllRoleMembers
111+ ### getAllActiveSigners
129112
130113``` solidity
131- function getAllRoleMembers(bytes32 _role ) external view returns (address[] )
114+ function getAllActiveSigners( ) external view returns (struct IAccountPermissions.SignerPermissions[] signers )
132115```
133116
134- Returns all accounts that have a role .
117+ Returns all signers with active permissions to use the account .
135118
136119
137120
138- #### Parameters
121+
122+ #### Returns
139123
140124| Name | Type | Description |
141125| ---| ---| ---|
142- | _ role | bytes32 | undefined |
126+ | signers | IAccountPermissions.SignerPermissions[ ] | undefined |
127+
128+ ### getAllAdmins
129+
130+ ``` solidity
131+ function getAllAdmins() external view returns (address[])
132+ ```
133+
134+ Returns all admins of the account.
135+
136+
137+
143138
144139#### Returns
145140
146141| Name | Type | Description |
147142| ---| ---| ---|
148143| _ 0 | address[ ] | undefined |
149144
145+ ### getAllSigners
146+
147+ ``` solidity
148+ function getAllSigners() external view returns (struct IAccountPermissions.SignerPermissions[] signers)
149+ ```
150+
151+ Returns all active and inactive signers of the account.
152+
153+
154+
155+
156+ #### Returns
157+
158+ | Name | Type | Description |
159+ | ---| ---| ---|
160+ | signers | IAccountPermissions.SignerPermissions[ ] | undefined |
161+
150162### getDeposit
151163
152164``` solidity
@@ -181,66 +193,66 @@ Return the account nonce. This method returns the next sequential nonce. For a n
181193| ---| ---| ---|
182194| _ 0 | uint256 | undefined |
183195
184- ### getRoleRestrictions
196+ ### getPermissionsForSigner
185197
186198``` solidity
187- function getRoleRestrictions(bytes32 _role ) external view returns (struct IAccountPermissions.RoleRestrictions )
199+ function getPermissionsForSigner(address signer ) external view returns (struct IAccountPermissions.SignerPermissions )
188200```
189201
190- Returns the role restrictions for a given role .
202+ Returns the restrictions under which a signer can use the smart wallet .
191203
192204
193205
194206#### Parameters
195207
196208| Name | Type | Description |
197209| ---| ---| ---|
198- | _ role | bytes32 | undefined |
210+ | signer | address | undefined |
199211
200212#### Returns
201213
202214| Name | Type | Description |
203215| ---| ---| ---|
204- | _ 0 | IAccountPermissions.RoleRestrictions | undefined |
216+ | _ 0 | IAccountPermissions.SignerPermissions | undefined |
205217
206- ### getRoleRestrictionsForAccount
218+ ### initialize
207219
208220``` solidity
209- function getRoleRestrictionsForAccount (address _account ) external view returns (struct IAccountPermissions.RoleRestrictions)
221+ function initialize (address _defaultAdmin, bytes ) external nonpayable
210222```
211223
212- Returns the role held by a given account along with its restrictions .
224+ Initializes the smart contract wallet .
213225
214226
215227
216228#### Parameters
217229
218230| Name | Type | Description |
219231| ---| ---| ---|
220- | _ account | address | undefined |
221-
222- #### Returns
223-
224- | Name | Type | Description |
225- | ---| ---| ---|
226- | _ 0 | IAccountPermissions.RoleRestrictions | undefined |
232+ | _ defaultAdmin | address | undefined |
233+ | _ 1 | bytes | undefined |
227234
228- ### initialize
235+ ### isActiveSigner
229236
230237``` solidity
231- function initialize (address _defaultAdmin, bytes ) external nonpayable
238+ function isActiveSigner (address signer ) external view returns (bool)
232239```
233240
234- Initializes the smart contract wallet .
241+ Returns whether the given account is an active signer on the account .
235242
236243
237244
238245#### Parameters
239246
240247| Name | Type | Description |
241248| ---| ---| ---|
242- | _ defaultAdmin | address | undefined |
243- | _ 1 | bytes | undefined |
249+ | signer | address | undefined |
250+
251+ #### Returns
252+
253+ | Name | Type | Description |
254+ | ---| ---| ---|
255+ | _ 0 | bool | undefined |
244256
245257### isAdmin
246258
@@ -442,10 +454,10 @@ Lets a contract admin set the URI for contract-level metadata.
442454| ---| ---| ---|
443455| _ uri | string | keccak256 hash of the role. e.g. keccak256(" ; TRANSFER_ROLE" ; ) |
444456
445- ### setRoleRestrictions
457+ ### setPermissionsForSigner
446458
447459``` solidity
448- function setRoleRestrictions (IAccountPermissions.RoleRestrictions _restrictions ) external nonpayable
460+ function setPermissionsForSigner (IAccountPermissions.SignerPermissionRequest _req, bytes _signature ) external nonpayable
449461```
450462
451463
@@ -456,7 +468,8 @@ function setRoleRestrictions(IAccountPermissions.RoleRestrictions _restrictions)
456468
457469| Name | Type | Description |
458470| ---| ---| ---|
459- | _ restrictions | IAccountPermissions.RoleRestrictions | undefined |
471+ | _ req | IAccountPermissions.SignerPermissionRequest | undefined |
472+ | _ signature | bytes | undefined |
460473
461474### supportsInterface
462475
@@ -504,10 +517,10 @@ function validateUserOp(UserOperation userOp, bytes32 userOpHash, uint256 missin
504517| ---| ---| ---|
505518| validationData | uint256 | undefined |
506519
507- ### verifyRoleRequest
520+ ### verifySignerPermissionRequest
508521
509522``` solidity
510- function verifyRoleRequest (IAccountPermissions.RoleRequest req, bytes signature) external view returns (bool success, address signer)
523+ function verifySignerPermissionRequest (IAccountPermissions.SignerPermissionRequest req, bytes signature) external view returns (bool success, address signer)
511524```
512525
513526
@@ -518,7 +531,7 @@ function verifyRoleRequest(IAccountPermissions.RoleRequest req, bytes signature)
518531
519532| Name | Type | Description |
520533| ---| ---| ---|
521- | req | IAccountPermissions.RoleRequest | undefined |
534+ | req | IAccountPermissions.SignerPermissionRequest | undefined |
522535| signature | bytes | undefined |
523536
524537#### Returns
@@ -552,7 +565,7 @@ Withdraw funds for this account from Entrypoint.
552565### AdminUpdated
553566
554567``` solidity
555- event AdminUpdated(address indexed account , bool isAdmin)
568+ event AdminUpdated(address indexed signer , bool isAdmin)
556569```
557570
558571Emitted when an admin is set or removed.
@@ -563,7 +576,7 @@ Emitted when an admin is set or removed.
563576
564577| Name | Type | Description |
565578| ---| ---| ---|
566- | account ` indexed ` | address | undefined |
579+ | signer ` indexed ` | address | undefined |
567580| isAdmin | bool | undefined |
568581
569582### ContractURIUpdated
@@ -599,41 +612,23 @@ event Initialized(uint8 version)
599612| ---| ---| ---|
600613| version | uint8 | undefined |
601614
602- ### RoleAssignment
603-
604- ``` solidity
605- event RoleAssignment(bytes32 indexed role, address indexed account, address indexed signer, IAccountPermissions.RoleRequest request)
606- ```
607-
608- Emitted when a role is granted / revoked by an authorized party.
609-
610-
611-
612- #### Parameters
613-
614- | Name | Type | Description |
615- | ---| ---| ---|
616- | role ` indexed ` | bytes32 | undefined |
617- | account ` indexed ` | address | undefined |
618- | signer ` indexed ` | address | undefined |
619- | request | IAccountPermissions.RoleRequest | undefined |
620-
621- ### RoleUpdated
615+ ### SignerPermissionsUpdated
622616
623617``` solidity
624- event RoleUpdated(bytes32 indexed role, IAccountPermissions.RoleRestrictions restrictions )
618+ event SignerPermissionsUpdated(address indexed authorizingSigner, address indexed targetSigner, IAccountPermissions.SignerPermissionRequest permissions )
625619```
626620
627- Emitted when the restrictions for a given role are updated.
621+ Emitted when permissions for a signer are updated.
628622
629623
630624
631625#### Parameters
632626
633627| Name | Type | Description |
634628| ---| ---| ---|
635- | role ` indexed ` | bytes32 | undefined |
636- | restrictions | IAccountPermissions.RoleRestrictions | undefined |
629+ | authorizingSigner ` indexed ` | address | undefined |
630+ | targetSigner ` indexed ` | address | undefined |
631+ | permissions | IAccountPermissions.SignerPermissionRequest | undefined |
637632
638633
639634
0 commit comments