Saltearse al contenido

Royal ID

Esta página aún no está disponible en tu idioma.

The User struct

Royal IDs are stored in User structs 🔗:

FieldTypeMeaning
iduint256Unique identifier (autoincrement)
usernamestringReadable username
custodyaddressThe address currently controlling this Royal ID
recoveryaddressAddress authorized to reset the custody address (optional)

Requirements

For user information to be valid, it needs to follow these requirements:

  • Both username and custody address have to be unique.
  • The username has to be URL safe (matching the regular expression /^[a-zA-Z0-9_][a-zA-Z0-9\._-]+$/)

Changes

Royal IDs can change their username (once every 28 days), custody address, and recovery address. The custody address can also be changed by the recovery address. See here for more information.

To avoid people registering under names that should belong to somebody else, Royal also has the ability to modify an ID’s username.

Contracts

Control and data flows

Queries

You can get Royal IDs by identifier, custody address, or username.

Query byFunctionBaseBase Sepolia
idgetUserById(uint256 id) 🔗 🔗 🔗
usernamegetUserByUsername(string username) 🔗 🔗 🔗
custody addressgetUserByAddress(address wallet) 🔗 🔗 🔗