version | title | status |
---|---|---|
0.1 |
Community Parameters Convention for Standard Profile Assets (ASAs) |
Draft |
Standard paramaters convention for creating and displaying public user profiles on Algorand blockchain applications.
The goal is to create an ASA convention for any applications where profiles can be associated with account addresses. The user profile is an ASA that stores its metadata as JSON objects in transactions note.
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC-2119.
A PROFILE ASA has an associated JSON Metadata file, formatted as specified below, that is stored on-chain in the most recent asset configuration transaction.
The ASA parameters should follow the following conventions:
- Asset Name (
an
): no restriction - Unit Name (
un
): MUST bePROFILE
- Total (
t
): MUST be 1 - Decimals (
dc
): MUST be 0 - Asset URL (
au
): no restriction - Asset Metadata Hash (
am
): no restriction- OPTIONAL
- Freeze Address (
f
):- SHOULD be empty
- Clawback Address (
c
):- SHOULD be empty
There are no requirements regarding the manager account of the ASA, or the reserve account. However, if immutability is required the manager address MUST be removed.
The JSON Metadata schema is as follows:
{
"title": "Profile Metadata",
"type": "object",
"properties": {
"name": {
"description": "Name or username of the user",
"type": "string",
},
"picture": {
"description": "A URI pointing to the profile picture.",
"type": "string"
},
"bio": {
"description": "Text describing the user. Also known as its biography.",
"type": "string"
},
"links": {
"description": "Links to the user's external pages.",
"type": "object",
"patternProperties": {
"[^\n]+": {
"description": "External link URL. The key can be used as label for this URL.",
"type": "string",
}
}
},
}
}
The picture
field:
- MUST be an image media type
- SHOULD link to a file small enough to fetch quickly in a gallery view.
- MUST follow RFC-3986 and MUST NOT contain any whitespace character.
- SHOULD use one of the following URI schemes (for compatibility and security): https and ipfs:
- When the file is stored on IPFS, the
ipfs://...
URI SHOULD be used. IPFS Gateway URI (such ashttps://ipfs.io/ipfs/...
) SHOULD NOT be used.
- When the file is stored on IPFS, the
- SHOULD NOT use the following URI scheme: http (due to security concerns)
An example of a profile JSON Metadata file for a song follows. The properties array proposes some SUGGESTED formatting for token-specific display properties and metadata.
{
"name": "John Doe",
"picture": "ipfs://bafybeic4xuwsedtfjohcrc2kbr6ixt4u4gbq6oyn6vretq2soefulgmkqm",
"bio": "NFT collector on the Algorand blockchain.",
"links": {
"Twitter": "https://twitter.com/johndoe-sample",
"Twitter (project)": "https://twitter.com/johndoe-sample-project",
"Website": "https://johndoe.com"
}
}
Clients SHOULD render a profile's latest metadata. Clients MAY render an ASA's previous metadata for changelogs or other historical features.
Managers MAY update a profile metadata. To do so, they MUST send a new acfg
transaction with the entire metadata represented as JSON in the transaction's note
field.
Managers MAY make a profile immutable. To do so, they MUST remove the ASA's manager address with an acfg
transaction.
Copyright and related rights waived via CC0.