LogoLogo
  • ENTER THE GR1D
    • Overview
    • GR1D Blockchain
    • GR1D Token
    • GR1D Network Utility
      • Blockchain Gaming
      • On-Chain Intellectual Property
      • Multi-Chain Consumer Applications
  • GR1D Network
    • GR1D Protocol
    • Multi-Chain Asset Orchestration
      • Multi-Chain Asset Verification SDK
        • Verify Ethereum Asset
        • Verify Solana Asset
      • GR1D MCAO Solutions
    • Intent Layer
      • GR1D Intent Architecture
      • GR1D Intent Technical Underpinnings
    • GR1D Multi-Chain Apps
      • GR1D TERM1NAL
  • Build with GR1D
    • GR1D Chain Info
      • GR1D Testnet Network Info
      • Connect to GR1D Testnet
      • Bridge to GR1D Testnet
      • Smart Contracts on GR1D Testnet
      • Explorer on GR1D Testnet
    • GR1D SDKs & APIs
    • Guide: Enter the GR1D Testnet
  • Circuit Nodes 101
    • Circuit Nodes Explained
    • Circuit Chip
    • Power your Circuit Node
      • Hardware Requirements for GR1D Circuit Node
      • How to Run GR1D Circuit Node
    • Node Operator Rewards
  • GR1D Tokenomics
    • Token Utility
    • Token Value Accrual
    • Staking and Redemptions
    • Rewards and Emissions
    • Token Overview
    • Token Distribution
  • GR1D Ecosystem
    • Amazon.com
    • Reddit.com
Powered by GitBook
On this page
Export as PDF
  1. GR1D Network
  2. Multi-Chain Asset Orchestration
  3. Multi-Chain Asset Verification SDK

Verify Solana Asset

Solana Asset Verification API

The Solana Asset Verification API allows developers to verify whether a user holds specific assets on the Solana mainnet, including Solana Fungible Tokens (SPL Tokens) and NFTs. This API is essential for integrating asset verification into decentralized applications (dApps) and services built on Solana.


Asset Verification API for Solana

Endpoint:

POST https://alpha.gr1d.network/api/ccq-svm

Headers:

  • Authorization: <GR1D_API_KEY> (Contact [email protected] to get early access)

  • Content-Type: application/json

Request Body:

{
    "owner_address": "6jm9hBqmTxb1KMHdu88YBtLZzipLLccNDadAeMYeEF5d",
    "token_mint_address": "BfGBv5n9YoJBNudqNwBZMyqMsHwNreyLTb7BWQR6SXCp"
}
  • owner_address: The Solana address of the user whose asset holdings are being verified.

  • token_mint_address: The mint address of the Solana Fungible Token or NFT.

Sample Response:

{
    "status": 200,
    "message": "Assets Fetched Successfully",
    "data": {
        "owner_address": "6jm9hBqmTxb1KMHdu88YBtLZzipLLccNDadAeMYeEF5d",
        "asset": {
            "balance": 5,
            "QueryResult": "9e621d04b95250c5c6540568987b208b7856422e704edbffe3c43846df20115d553ebfc0f7f04824ab5db898e6c8116411584c40947b632f10789ee7de02d53c0500000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
        }
    }
}
  • status: HTTP status code (200 indicates success).

  • message: A message indicating the result of the query.

  • data:

    • owner_address: The Solana address queried.

    • asset.balance: The number of tokens or NFTs the user holds.

    • asset.QueryResult: A hexadecimal string representing the encoded query result.


Error Handling

In the event of an error, the API will return a response with the appropriate HTTP status code and an error message. Common error codes include:

  • 400: Bad Request - The request parameters are invalid.

  • 401: Unauthorized - The GR1D_API_KEY is missing or invalid.

  • 404: Not Found - The specified token_mint_address or owner_address is invalid.

  • 500: Internal Server Error - An unexpected error occurred on the server.


Security Considerations

  • API Key Management: Ensure that the GR1D_API_KEY is kept secure and never exposed in client-side code or public repositories.

  • Data Integrity: The query results are verified to ensure data integrity.

  • Rate Limiting: Be aware of any rate limits imposed on the API to prevent abuse and ensure fair usage.


Examples and Edge Cases

  • Solana Fungible Token Verification:

    {
        "owner_address": "6jm9hBqmTxb1KMHdu88YBtLZzipLLccNDadAeMYeEF5d",
        "token_mint_address": "BfGBv5n9YoJBNudqNwBZMyqMsHwNreyLTb7BWQR6SXCp"
    }

    Expected response: The balance field will indicate the number of Solana Fungible Tokens held by the user.

  • Solana NFT Verification:

    {
        "owner_address": "6jm9hBqmTxb1KMHdu88YBtLZzipLLccNDadAeMYeEF5d",
        "token_mint_address": "BfGBv5n9YoJBNudqNwBZMyqMsHwNreyLTb7BWQR6SXCp"
    }

    Expected response: The balance field will indicate the number of NFTs held by the user.

  • No Asset Held:

    {
        "owner_address": "6jm9hBqmTxb1KMHdu88YBtLZzipLLccNDadAeMYeEF5d",
        "token_mint_address": "BfGBv5n9YoJBNudqNwBZMyqMsHwNreyLTb7BWQR6SXCp"
    }

    Expected response: The balance field will be 0, and the QueryResult will reflect that no assets were found.

PreviousVerify Ethereum AssetNextGR1D MCAO Solutions
Page cover image