List Metadata
Every EFP List has associated key-value metadata called List Metadata.
List Metadata is stored onchain alongside List Records in the same contract, but in a different format (key-value pairs).
Data is stored with a string
key and bytes
value, for each EFP List.
Only the Manager of the EFP List can set or update the metadata for a list.
This allows Managers to store list-specific configuration or preference data.
Global keys
Global Keys must be made up of lowercase letters, numbers and the hyphen (-) character.
There are currently two global keys defined for List Metadata:
Key | Description |
---|---|
manager | The Ethereum address of the Manager role associated with the EFP List, which is able to edit List Records. |
user | The Ethereum address of the User role associated with the EFP List, which is the Ethereum account that is following the Ethereum accounts in the list. |
”manager”
The manager
key is used to store the Manager role associated with an EFP List.
The manager is represented as a 20-byte address.
Byte(s) | Description | Value |
---|---|---|
0-19 | Address (20 bytes) | 0x00000000000000000000000000000000DeaDBeef |
Code
By reading the manager
key for a given List, a client can determine the Manager associated with that list.
”user”
The user
key is used to store the User role associated with an EFP List.
The user is represented as a 20-byte address.
Byte(s) | Description | Value |
---|---|---|
0-19 | Address (20 bytes) | 0x00000000000000000000000000000000DeaDBeef |
Code
with example code shown below:
By reading the user
key for a given EFP List, a client can determine the User associated with that list.
Future
This pattern can be extended to support other list-specific metadata such as a name or description.
Custom Keys
The format for custom keys are undefined at this time but will be defined in the future.