POST
/
search
cURL
# Example 1: Search by content hash only
curl -X POST 'https://core-api-server.onrender.com/search' \
  -H 'Content-Type: application/json' \
  -d '{
    "contentHash": "a665a45920422f9d417e4867efdc4fb8a04a1f3fff1fa07e998e86f7f7a27ae3"
  }'

# Example 2: Search by content hash and wallet address
curl -X POST 'https://core-api-server.onrender.com/search' \
  -H 'Content-Type: application/json' \
  -d '{
    "contentHash": "a665a45920422f9d417e4867efdc4fb8a04a1f3fff1fa07e998e86f7f7a27ae3",
    "walletAddress": "9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM"
  }'
{
"searchMode": "content_hash_only",
"message": "Found 2 registration(s) for this content hash.",
"searchCriteria": {
"contentHash": "a665a45920422f9d417e4867efdc4fb8a04a1f3fff1fa07e998e86f7f7a27ae3"
},
"totalResults": 2,
"registrations": [
{
"title": "Test File",
"contentHash": "a665a45920422f9d417e4867efdc4fb8a04a1f3fff1fa07e998e86f7f7a27ae3",
"pdaAddress": "8kQv2gFhgRmHq7ZPBx4N9TqJbSx3jDw5mVpL1WzNfEtY",
"ipfsCid": "QmX7Rt8VBgKdNzF4mP6YvWzNfEtY2jDw5mVpL1WzNfEtYz",
"registeredBy": "9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM",
"userID": "user_123456789",
"timestamp": "2024-01-15T14:30:25.000Z",
"explorerUrl": "https://explorer.solana.com/address/8kQv2gFhgRmHq7ZPBx4N9TqJbSx3jDw5mVpL1WzNfEtY?cluster=devnet",
"status": "registered",
"metadata": "Test File Metadata",
"identity_data": {
"verified_name": "John Doe",
"verified_nationality": "United States",
"verified_date_of_birth": "1990-01-01",
"verified_gender": null,
"verified_passport_number": null,
"verified_issuing_state": null,
"verified_expiry_date": null,
"verified_at": "2024-01-15T14:30:25.000Z",
"provider": "self"
}
}
]
}

What This Endpoint Does

1

Hash Validation

Validates the provided content hash format
2

On-Chain Search

Queries the Solana blockchain for matching content registration records
3

Data Enrichment

Fetches complete registration details and metadata
4

User Lookup

Attempts to find associated user IDs for the file creators
5

Result Formatting

Returns comprehensive registration information and metadata

Search Modes:
  • Content Hash Only: Returns all registrations for this file hash
  • Content Hash + Wallet: Returns specific registration by this wallet for this file hash

Pro Tip: Use the walletAddress parameter to find specific registrations when multiple users have registered the same file.

Body

application/json

Response

200
application/json

Search completed successfully with results found

The response is of type object.