Skip to content

Commit 6172c33

Browse files
authored
Document ENS resolution support for profiles API (#76)
1 parent ee4d444 commit 6172c33

3 files changed

Lines changed: 13 additions & 8 deletions

File tree

api/openapi.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4166,7 +4166,7 @@
41664166
"schema": {
41674167
"type": "string"
41684168
},
4169-
"description": "Filter by wallet address"
4169+
"description": "Filter by wallet address. Accepts an EVM (0x...) or Solana address, or an ENS name (e.g. vitalik.eth) which is resolved to an address."
41704170
},
41714171
{
41724172
"name": "expand",
@@ -4314,7 +4314,7 @@
43144314
"schema": {
43154315
"type": "string"
43164316
},
4317-
"description": "Wallet address"
4317+
"description": "Wallet address. Accepts an EVM (0x...) or Solana address, or an ENS name (e.g. vitalik.eth) which is resolved to an address."
43184318
},
43194319
{
43204320
"name": "expand",
@@ -4524,7 +4524,7 @@
45244524
"schema": {
45254525
"type": "string"
45264526
},
4527-
"description": "Wallet address (EVM 0x... or Solana base58)"
4527+
"description": "Wallet address. Accepts an EVM (0x...) or Solana address, or an ENS name (e.g. vitalik.eth) which is resolved to an address."
45284528
},
45294529
{ "$ref": "#/components/parameters/IdempotencyKey" }
45304530
],
@@ -4656,7 +4656,7 @@
46564656
"schema": {
46574657
"type": "string"
46584658
},
4659-
"description": "Wallet address (EVM 0x... or Solana base58)"
4659+
"description": "Wallet address. Accepts an EVM (0x...) or Solana address, or an ENS name (e.g. vitalik.eth) which is resolved to an address."
46604660
},
46614661
{ "$ref": "#/components/parameters/IdempotencyKey" }
46624662
],
@@ -4745,7 +4745,7 @@
47454745
"schema": {
47464746
"type": "string"
47474747
},
4748-
"description": "Wallet address (EVM 0x... or Solana base58)"
4748+
"description": "Wallet address. Accepts an EVM (0x...) or Solana address, or an ENS name (e.g. vitalik.eth) which is resolved to an address."
47494749
},
47504750
{ "$ref": "#/components/parameters/IdempotencyKey" }
47514751
],

api/profiles/get.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ The API key needs to have the **read permission for profiles** in the API settin
2828

2929
## Path parameters
3030

31-
- `address` (string): EVM Wallet address e.g. `0x0000000000000000000000000000000000000000`.
31+
- `address` (string): A wallet address or ENS name. Accepts an EVM address (e.g. `0x0000000000000000000000000000000000000000`), a Solana address, or an ENS name (e.g. `vitalik.eth`). ENS names are resolved to an address before lookup.
3232

3333
## Query parameters
3434

@@ -294,7 +294,7 @@ Array of token holdings:
294294

295295
| Status | Code | Description |
296296
|--------|------|-------------|
297-
| 400 | `BAD_REQUEST` | Invalid wallet address format |
297+
| 400 | `BAD_REQUEST` | Invalid address or ENS name, or the ENS name could not be resolved |
298298
| 401 | `UNAUTHORIZED` | Missing or invalid API key |
299299
| 403 | `FORBIDDEN` | API key does not have `profiles:read` permission |
300300
| 404 | `PROFILE_NOT_FOUND` | Profile does not exist |

api/profiles/search.mdx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,17 @@ The API key needs to have the **read permission for profiles** in the API settin
2222

2323
### `address`
2424

25-
Filter by a specific wallet address (exact match).
25+
Filter by a specific wallet address (exact match). Accepts an EVM address, a Solana address, or an ENS name (e.g. `vitalik.eth`) which is resolved to an address before filtering. An unresolvable ENS name or an otherwise invalid value returns a `400 BAD_REQUEST`.
2626

2727
```bash
2828
curl -sS -X GET \
2929
-H "Authorization: Bearer <your_workspace_api_key>" \
3030
"https://api.formo.so/v0/profiles?address=0x1234..."
31+
32+
# ENS names are resolved automatically
33+
curl -sS -X GET \
34+
-H "Authorization: Bearer <your_workspace_api_key>" \
35+
"https://api.formo.so/v0/profiles?address=vitalik.eth"
3136
```
3237

3338
### `search`

0 commit comments

Comments
 (0)