#[allow(clippy::too_many_arguments, unused_attributes)]
mod names_inner {
use alloy::sol;
sol! {
#[sol(rpc)]
interface IdentityNames {
#[derive(Debug, serde::Serialize, serde::Deserialize)]
struct Rules {
uint16 maxLength;
bool stripLeadingAt;
bool isEmail;
bool allowUnderscore;
bool allowHyphen;
}
function initialize(address owner_) external;
function setPlatform(bytes32 platformId, Rules calldata rules) external;
function setProofVerifier(address verifier) external;
function proofVerifier() external view returns (address);
function claim(bytes32 platformId, uint16 verifierVersion, bytes calldata payload, bool publishName) external payable;
function quoteClaim(bytes32 platformId, uint16 verifierVersion) external view returns (uint256);
function digestSpent(bytes32 digest) external view returns (bool);
function unpublish(bytes32 platformId) external;
function resolveId(bytes32 platformId, string calldata userId) external view returns (address);
function resolveHandle(bytes32 platformId, string calldata handle) external view returns (address);
function resolvePair(bytes32 platformId, string calldata handle, string calldata userId) external view returns (address);
function reverseOf(address wallet, bytes32 platformId) external view returns (string memory);
function primaryOf(address wallet, bytes32 platformId) external view returns (string memory);
event IdentityBound(
address indexed owner,
bytes32 indexed idNode,
bytes32 indexed handleNode,
bytes32 platformId,
string userId,
string handle,
uint64 observedAt,
bool published,
uint16 ceremonyVersion
);
event HandleRetired(bytes32 indexed platformId, bytes32 indexed handleNode, address indexed owner);
event PlatformConfigured(bytes32 indexed platformId);
event ProofVerifierConfigured(address verifier);
event NameUnpublished(address indexed owner, bytes32 indexed platformId);
event CeremonyBound(
bytes32 indexed authorizationDigest,
address indexed owner,
bytes32 indexed platformId,
bytes clientIdentifier
);
}
}
}
pub use names_inner::IdentityNames;