Attestations
Celo0xdc553892cdeeed9f575aa0fba099e5847fd88d20
Proxy implementation: 0xf65903343712820ef19090c15051687b9363758c
Solidity v0.5.13+commit.5b0b510c
Overview
Read Functions
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 |
Parameters
| Name | Type | Description |
|---|---|---|
| — | address |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 |
Batch lookup function to determine attestation stats for a list of identifiers.
Parameters
| Name | Type | Description |
|---|---|---|
| identifiersToLookup | bytes32[] | Array of n identifiers. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256[] | [0] Array of number of matching accounts per identifier. |
| — | address[] | [1] Array of sum([0]) matching walletAddresses. |
| — | uint64[] | [2] Array of sum([0]) numbers indicating the completions for each account. |
| — | uint64[] | [3] Array of sum([0]) numbers indicating the total number of requested attestations for each account. |
Returns selected attestation issuers for a identifier/account pair.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | Hash of the identifier. |
| account | address | Address of the account. |
Returns
| Name | Type | Description |
|---|---|---|
| — | address[] | Addresses of the selected attestation issuers. |
Returns the fee set for a particular token.
Parameters
| Name | Type | Description |
|---|---|---|
| token | address | Address of the attestationRequestFeeToken. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 | The fee. |
Returns the state of a specific attestation.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | Hash of the identifier. |
| account | address | Address of the account. |
| issuer | address | Address of the issuer. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint8 | status Status of the attestation. |
| — | uint32 | block Block number of request/completion the attestation. |
| — | address | address Address of the token with which this attestation request was paid for. |
Returns attestation stats for a identifier/account pair.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | Hash of the identifier. |
| account | address | Address of the account. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint32 | completed Number of completed attestations. |
| — | uint32 | requested Number of total requested attestations. |
Returns the state of all attestations that are completable
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | Hash of the identifier. |
| account | address | Address of the account. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint32[] | Block number of request/completion the attestation. |
| — | address[] | Address of the issuer. |
| — | uint256[] | The length of each metadataURL string for each issuer. |
| — | bytes | All strings concatenated. |
Query 'maxAttestations'
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 | Maximum number of attestations that can be requested. |
Returns the unselected attestation request for an identifier/account pair, if any.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | Hash of the identifier. |
| account | address | Address of the account. |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint32 | block Block number at which was requested. |
| — | uint32 | number Number of unselected requests. |
| — | address | address Address of the token with which this attestation request was paid for. |
Returns the storage, major, minor, and patch version of the contract.
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 | Storage version of the contract. |
| — | uint256 | Major version of the contract. |
| — | uint256 | Minor version of the contract. |
| — | uint256 | Patch version of the contract. |
Returns
| Name | Type | Description |
|---|---|---|
| — | bool |
Returns
| Name | Type | Description |
|---|---|---|
| — | bool |
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 |
Returns
| Name | Type | Description |
|---|---|---|
| — | address[] |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 |
Returns
| Name | Type | Description |
|---|---|---|
| — | address |
Parameters
| Name | Type | Description |
|---|---|---|
| — | address | |
| — | address |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 |
Returns
| Name | Type | Description |
|---|---|---|
| — | address |
Require that a given identifier/address pair has requested a specific number of attestations.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | Hash of the identifier. |
| account | address | Address of the account. |
| expected | uint32 | Number of expected attestations |
Returns
| Name | Type | Description |
|---|---|---|
| — | uint256 |
Parameters
| Name | Type | Description |
|---|---|---|
| — | address | |
| — | bytes32 |
Returns
| Name | Type | Description |
|---|---|---|
| — | bool |
Validates the given attestation code.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | The hash of the identifier to be attested. |
| account | address | Address of the account. |
| v | uint8 | The recovery id of the incoming ECDSA signature. |
| r | bytes32 | Output value r of the ECDSA signature. |
| s | bytes32 | Output value s of the ECDSA signature. |
Returns
| Name | Type | Description |
|---|---|---|
| — | address | The issuer of the corresponding attestation. |
Write Functions
Used in place of the constructor to allow the contract to be upgradable via proxy.
Parameters
| Name | Type | Description |
|---|---|---|
| registryAddress | address | The address of the registry core smart contract. |
| _attestationExpiryBlocks | uint256 | The new limit on blocks allowed to come between requesting an attestation and completing it. |
| _selectIssuersWaitBlocks | uint256 | The wait period in blocks to call selectIssuers on attestation requests. |
| _maxAttestations | uint256 | |
| attestationRequestFeeTokens | address[] | The address of tokens that fees should be payable in. |
| attestationRequestFeeValues | uint256[] | The corresponding fee values. |
Revokes an account for an identifier.
Parameters
| Name | Type | Description |
|---|---|---|
| identifier | bytes32 | The identifier for which to revoke. |
| index | uint256 | The index of the account in the accounts array. |
Updates 'attestationExpiryBlocks'.
Parameters
| Name | Type | Description |
|---|---|---|
| _attestationExpiryBlocks | uint256 | The new limit on blocks allowed to come between requesting an attestation and completing it. |
Updates the fee for a particular token.
Parameters
| Name | Type | Description |
|---|---|---|
| token | address | The address of the attestationRequestFeeToken. |
| fee | uint256 | The fee in 'token' that is required for each attestation. |
Updates 'maxAttestations'.
Parameters
| Name | Type | Description |
|---|---|---|
| _maxAttestations | uint256 | Maximum number of attestations that can be requested. |
Updates the address pointing to a Registry contract.
Parameters
| Name | Type | Description |
|---|---|---|
| registryAddress | address | The address of a registry contract for routing to other contracts. |
Updates 'selectIssuersWaitBlocks'.
Parameters
| Name | Type | Description |
|---|---|---|
| _selectIssuersWaitBlocks | uint256 | The wait period in blocks to call selectIssuers on attestation requests. |
Parameters
| Name | Type | Description |
|---|---|---|
| newOwner | address |
Allows issuers to withdraw accumulated attestation rewards.
Parameters
| Name | Type | Description |
|---|---|---|
| token | address | The address of the token that will be withdrawn. |
Events
| Name | Type | Indexed | Description |
|---|---|---|---|
| identifier | bytes32 | ✓ | |
| account | address | ✓ | |
| issuer | address | ✓ |
| Name | Type | Indexed | Description |
|---|---|---|---|
| value | uint256 |
| Name | Type | Indexed | Description |
|---|---|---|---|
| identifier | bytes32 | ✓ | |
| account | address | ✓ | |
| issuer | address | ✓ | |
| attestationRequestFeeToken | address |
| Name | Type | Indexed | Description |
|---|---|---|---|
| token | address | ✓ | |
| value | uint256 |
| Name | Type | Indexed | Description |
|---|---|---|---|
| identifier | bytes32 | ✓ | |
| account | address | ✓ | |
| attestationsRequested | uint256 | ||
| attestationRequestFeeToken | address |
| Name | Type | Indexed | Description |
|---|---|---|---|
| identifier | bytes32 | ✓ | |
| fromAccount | address | ✓ | |
| toAccount | address | ✓ |
| Name | Type | Indexed | Description |
|---|---|---|---|
| value | uint256 |
| Name | Type | Indexed | Description |
|---|---|---|---|
| previousOwner | address | ✓ | |
| newOwner | address | ✓ |
| Name | Type | Indexed | Description |
|---|---|---|---|
| registryAddress | address | ✓ |
| Name | Type | Indexed | Description |
|---|---|---|---|
| value | uint256 |
| Name | Type | Indexed | Description |
|---|---|---|---|
| approver | address | ✓ | |
| indentifier | bytes32 | ✓ | |
| from | address | ||
| to | address | ||
| approved | bool |
| Name | Type | Indexed | Description |
|---|---|---|---|
| account | address | ✓ | |
| token | address | ✓ | |
| amount | uint256 |