WorldIDAddressBook

World Chain

0x57b930d551e677cc36e2fa036ae2fe8fdae0330d

Solidity v0.8.23+commit.f704f362

🤖
通过你的 AI 查询此合约
引用: 0x57b930d551e677cc36e2fa036ae2fe8fdae0330d
示例提示词: "Tell me the current state of world/0x57b930d551e677cc36e2fa036ae2fe8fdae0330d"
还没有接入 AI?→ mcp.smarts.md
World Chain 在 Smarts 上是仅文档链:源代码和 ABI 已索引,但当前不提供实时链上数据(状态、最新事件、管理员画像)。AI 代理仍可通过 MCP 调用 get_contract_info 和 get_contract_source。

概览

读取函数
9
写入函数
7
事件
8

读取函数

addressVerifiedUntil(address) view

Returns a timestamp representing when the address' verification will expire

参数

名称 类型 描述
address

返回值

名称 类型 描述
uint256 timestamp The timestamp when the address' verification will expire
groupId() view

Returns the World ID group identifier used by this contract.✨ AI

返回值

名称 类型 描述
uint256 The numeric group identifier (uint256) associated with the World ID this contract uses.✨ AI
maxProofTime() view

Return the maximum allowed time window for proofs, expressed in seconds.✨ AI

返回值

名称 类型 描述
uint256 Maximum allowed proof time in seconds; proofs older than this duration are considered expired.✨ AI
nullifierHashes(uint256) view

Return the address stored for a given nullifier index.✨ AI

参数

名称 类型 描述
uint256

返回值

名称 类型 描述
address Address associated with the provided nullifier index.✨ AI
owner() view

Returns the contract owner's address.✨ AI

开发者: Returns the address of the current owner.

返回值

名称 类型 描述
address The owner address with administrative privileges for the contract.✨ AI
pendingOwner() view

Returns the address that is set to become the new owner but has not accepted ownership yet.✨ AI

开发者: Returns the address of the pending owner.

返回值

名称 类型 描述
address The pending owner address, or the zero address if no ownership transfer is pending.✨ AI
renounceOwnership() view

Indicates that ownership has been renounced.✨ AI

开发者: Leaves the contract without owner. It will not be possible to call `onlyOwner` functions. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby disabling any functionality that is only available to the owner.
verificationLength() view

Read the number of verification entries stored in the contract.✨ AI

返回值

名称 类型 描述
uint256 The current count of verification records as a uint256.✨ AI
worldIdRouter() view

Returns the address of the World ID router contract.✨ AI

返回值

名称 类型 描述
address The World ID router contract address used to route and validate World ID interactions.✨ AI

写入函数

acceptOwnership() nonpayable

Allow the pending owner to finalize and assume ownership of the contract.✨ AI

开发者: The new owner accepts the ownership transfer.
setGroupId(_groupId: uint256) nonpayable

Update the groupId

开发者: Can only be called by the owner

参数

名称 类型 描述
_groupId uint256 The new groupId
setMaxProofTime(_maxProofTime: uint256) nonpayable

Update the amount of time that a verification request can be pending for, in seconds

开发者: Can only be called by the owner

参数

名称 类型 描述
_maxProofTime uint256 The new maxProofTime
setVerificationLength(_verificationLength: uint256) nonpayable

Update the amount of time that a verification is valid for, in seconds

开发者: Can only be called by the owner.

参数

名称 类型 描述
_verificationLength uint256 The new verificationLength
setWorldIdRouter(_worldIdRouter: address) nonpayable

Update the World ID router address used by the contract.✨ AI

开发者: Can only be called by the owner

参数

名称 类型 描述
_worldIdRouter address The new worldIdRouter
transferOwnership(newOwner: address) nonpayable

Transfers contract ownership to the newOwner address.✨ AI

开发者: Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.

参数

名称 类型 描述
newOwner address Address to which ownership will be transferred.✨ AI
verify(account: address, root: uint256, nullifierHash: uint256, proof: uint256[8], proofTime: uint256) payable

Registers a wallet to receive grants

参数

名称 类型 描述
account address The address that will be registered
root uint256 The root of the Merkle tree (signup-sequencer or world-id-contracts provides this)
nullifierHash uint256 The nullifier for this proof, preventing double signaling
proof uint256[8] The zero knowledge proof that demonstrates the claimer has a verified World ID
proofTime uint256 A timestamp representing when the proof was created

事件

AccountVerified(account: address, verifiedUntil: uint256)

Emitted when an account is verified

名称 类型 已索引 描述
account address
verifiedUntil uint256
GroupIdUpdated(groupId: uint256)

Emitted when the `groupId` is changed

名称 类型 已索引 描述
groupId uint256 The new `groupId`
MaxProofTimeUpdated(maxProofTime: uint256)

Emitted when the amount of time that a verification request can be pending for is changed

名称 类型 已索引 描述
maxProofTime uint256 The new `maxProofTime`
OwnershipTransferStarted(previousOwner: address, newOwner: address)
名称 类型 已索引 描述
previousOwner address
newOwner address
OwnershipTransferred(previousOwner: address, newOwner: address)
名称 类型 已索引 描述
previousOwner address
newOwner address
VerificationLengthUpdated(verificationLength: uint256)

Emitted when the amout of time that a verification is valid for is changed

名称 类型 已索引 描述
verificationLength uint256 The new `verificationLength`
WorldIDAddressBookInitialized(worldIdRouter: address, groupId: uint256, externalNullifierHash: uint256, verificationLength: uint256, maxProofTime: uint256)

Emitted when the contract is initialized

名称 类型 已索引 描述
worldIdRouter address The WorldID router that will manage groups and verify proofs
groupId uint256 The group ID of the World ID
externalNullifierHash uint256 The nullifier hash that will be used to verify proofs
verificationLength uint256 The amount of seconds that a verification is valid for
maxProofTime uint256 The maximum amount of time that a verification request can be pending for
WorldIdRouterUpdated(worldIdRouter: address)

Emitted when the `worldIdRouter` is changed

名称 类型 已索引 描述
worldIdRouter address The new `worldIdRouter` instance