Get Subname Profile
Retrieve a comprehensive profile for a subname including records, links, QR codes, and social preview data.
Endpoint​
GET /api/subnames/{parent}/{name}/profile
Authentication​
None required — This is a public read endpoint.
Parameters​
| Parameter | Type | Location | Required | Description |
|---|---|---|---|---|
parent | string | path | âś… | Parent ENS name (e.g., aboutme.eth) |
name | string | path | âś… | Subname label (e.g., alice) |
Response​
{
"name": "alice",
"fullName": "alice.aboutme.eth",
"owner": "0x701B4937e6c943789ffA74CC8601813b2D87B454",
"created_at": "2024-02-09T18:30:00.000Z",
"expires_at": "2025-02-09T18:30:00.000Z",
"links": {
"profile": "https://alice.aboutme.eth.limo",
"ens_app": "https://app.ens.domains/alice.aboutme.eth",
"etherscan": "https://etherscan.io/address/0x701B4937e6c943789ffA74CC8601813b2D87B454",
"api": "https://api.web3identity.com/api/subnames/aboutme.eth/alice"
},
"qr": {
"profile": "https://api.qrserver.com/v1/create-qr-code/?size=300x300&data=https%3A%2F%2Falice.aboutme.eth.limo",
"address": "https://api.qrserver.com/v1/create-qr-code/?size=300x300&data=ethereum:0x701B4937e6c943789ffA74CC8601813b2D87B454"
},
"og": {
"title": "alice.aboutme.eth | Web3 Identity",
"description": "alice.aboutme.eth - A Web3 identity on ENS. Owner: 0x701B...B454",
"image": "https://api.web3identity.com/api/subnames/aboutme.eth/alice/og-image",
"url": "https://alice.aboutme.eth.limo",
"type": "profile"
},
"mint_cta": {
"text": "Get your own .aboutme.eth name",
"url": "https://aboutme.eth.limo",
"button_text": "Claim Yours Free"
},
"records": {
"description": "Web3 developer & ENS enthusiast",
"url": "https://alice.dev",
"com.twitter": "@alice",
"com.github": "alice",
"avatar": "ipfs://QmXyz123..."
},
"timestamp": "2024-02-10T14:30:00.000Z"
}
Examples​
cURL​
curl "https://api.web3identity.com/api/subnames/aboutme.eth/alice/profile"
JavaScript​
async function getProfile(parent, name) {
const response = await fetch(
`https://api.web3identity.com/api/subnames/${parent}/${name}/profile`
);
return response.json();
}
// Get full profile
const profile = await getProfile('aboutme.eth', 'alice');
// Display profile card
console.log(`Name: ${profile.fullName}`);
console.log(`Owner: ${profile.owner}`);
console.log(`Description: ${profile.records?.description || 'No description'}`);
console.log(`Profile URL: ${profile.links.profile}`);
// Use QR code
const qrImageUrl = profile.qr.profile;
Social Preview Integration​
Use the og data for social sharing:
<!-- HTML meta tags -->
<meta property="og:title" content="${profile.og.title}" />
<meta property="og:description" content="${profile.og.description}" />
<meta property="og:image" content="${profile.og.image}" />
<meta property="og:url" content="${profile.og.url}" />
<meta property="og:type" content="${profile.og.type}" />
<!-- Twitter Card -->
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="${profile.og.title}" />
<meta name="twitter:description" content="${profile.og.description}" />
<meta name="twitter:image" content="${profile.og.image}" />
Response Fields​
| Field | Type | Description |
|---|---|---|
name | string | Subname label |
fullName | string | Complete ENS name |
owner | string | Owner's Ethereum address |
created_at | string | Registration timestamp |
expires_at | string | Expiration timestamp |
links | object | Useful URLs (profile, ENS app, Etherscan) |
qr | object | QR code URLs for profile and wallet address |
og | object | Open Graph data for social previews |
mint_cta | object | Call-to-action for registration |
records | object | ENS text records (if any) |
Use Cases​
- Profile Cards: Display rich profile information in apps
- Social Sharing: Generate shareable links with proper previews
- QR Codes: Generate printable QR codes for wallets/profiles
- Portfolio Sites: Build profile pages with complete data
Error Responses​
| Status | Code | Description |
|---|---|---|
| 404 | NOT_FOUND | Subname does not exist |
| 429 | RATE_LIMITED | Rate limit exceeded |
| 500 | PROFILE_ERROR | Internal server error |
Related Endpoints​
- Get Details — Basic subname info
- Update Records — Modify text records
- By Owner — List all names by owner