Domain fields
Fields (also called records) are key-value metadata attached to your .night domain. They let you store information like a display name, bio, social links, avatar URL, and more — all on-chain and queryable by anyone through the SDK.
Common fields
Section titled “Common fields”| Field | Description |
|---|---|
name | Display name shown on your profile |
bio | Short description or bio text |
website | Your website URL |
twitter | Twitter/X handle (without @) |
github | GitHub username |
avatar | URL to your profile picture |
epk | Your EncryptionPublicKey — set automatically on registration |
location | Your location |
You can also add any custom field you like. Field names are case-insensitive.
How fields are used
Section titled “How fields are used”Fields appear on your domain profile at preprod.midnames.com and in any app that uses the DomainProfileWidget or calls getDomainFields from the SDK.
The widget automatically reads these fields to populate the profile card — for example, avatar sets the profile picture, bio fills the bio section, and twitter/github/website render as social link chips.
Managing fields
Section titled “Managing fields”To add, edit, or remove fields, go to preprod.midnames.com, search for your domain, and click Customize & Advanced. From there you can:
- Add fields — enter a field name and value, then click the add button. You can add multiple fields at once.
- Edit fields — change the value of an existing field in the input.
- Remove fields — clear the value (leave it empty) to remove a field.
Click the update button when you’re done. Your Lace wallet will prompt you to sign the transaction.
Reading fields with the SDK
Section titled “Reading fields with the SDK”import { getDomainFields } from "@midnames/sdk";
const result = await getDomainFields("facu.night");if (result.success) { for (const [key, value] of result.data) { console.log(`${key}: ${value}`); }}See the SDK reference for full details.