authz module to EVM smart contracts. It lets contracts inspect authorization grants between a granter and a grantee, as well as all grants issued or received by a given account.
Address
The Authz precompile is available at the fixed address:Interface
Methods
All methods on this precompile are read-onlyview queries. They do not mutate state.
grants
Returns the grants between a specific granter and grantee, optionally filtered by a message type URL.granter— the granter’s EVM address, which must be associated with a Sei address.grantee— the grantee’s EVM address, which must be associated with a Sei address.msgTypeUrl— the message type URL to filter by. Pass an empty string to return all grants.pageKey— the pagination key; pass empty bytes to request the first page.
Grant contains the authorization encoded as JSON bytes and an expiration expressed as a Unix timestamp in seconds. The nextKey field of the response is the pagination key for the next page (empty when the result set is exhausted).
granterGrants
Returns every grant issued by a given granter.granter— the granter’s EVM address, which must be associated with a Sei address.pageKey— the pagination key; pass empty bytes to request the first page.
GrantAuthorization includes the bech32 granter and grantee addresses, the authorization encoded as JSON bytes, and an expiration as a Unix timestamp in seconds.
granteeGrants
Returns every grant received by a given grantee.grantee— the grantee’s EVM address, which must be associated with a Sei address.pageKey— the pagination key; pass empty bytes to request the first page.
granterGrants, listing each GrantAuthorization with its granter, grantee, JSON-encoded authorization, and expiration.
Notes
- The addresses passed to these methods must be associated with a Sei address; querying an unassociated address reverts.
- The
authorizationfield is returned as JSON-encoded bytes and includes an@typediscriminator (for example, aSendAuthorization).