GET
/
find-wallet
cURL
# Example 1: Find by userID
curl -X GET 'https://core-api-server.onrender.com/find-wallet?userID=user-12345'

# Example 2: Find by wallet address
curl -X GET 'https://core-api-server.onrender.com/find-wallet?walletAddress=9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM'
{
"success": true,
"message": "Wallet relation found successfully using userID.",
"details": {
"searchType": "userID",
"searchValue": "user-12345",
"relation": {
"userId": "user-12345",
"walletAddress": "9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM",
"createdAt": "2024-01-15T10:30:45.123Z",
"relationPDA": "xyz789abc123def456ghi..."
}
}
}

What This Endpoint Does

1

Parameter Validation

Ensures that exactly one of userID or walletAddress is provided.
2

On-Chain Search

Queries the Solana blockchain to find the relationship Program Derived Address (PDA).
3

Fetches Relation

Retrieves and deserializes the on-chain data for the user-key relationship.

Query Parameters

userID
string

User ID to search for (provide either this OR walletAddress)

Example:

"user-12345"

walletAddress
string

Wallet address to search for (provide either this OR userID)

Example:

"9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM"

Response

200
application/json

Wallet relation found successfully

The response is of type object.