Skip to main content
Glama
ahnlabio

BICScan MCP Server

by ahnlabio

get_risk_score

Assess risk for blockchain addresses, domains, and hostnames by retrieving a security score from 0 to 100 to identify potential threats.

Instructions

Get Risk Score for Crypto, Domain Name, ENS, CNS, KNS or even Hostname Address

Args:
    address: EOA, CA, ENS, CNS, KNS or even HostName
Returns:
    Dict: where summary.bicscan_score is from 0 to 100. 100 is high risk.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYes

Implementation Reference

  • The handler function for the 'get_risk_score' tool. It is decorated with @mcp.tool() which registers it as an MCP tool. Takes an address parameter, makes a POST request to the BICScan API, and returns the risk score dictionary.
    async def get_risk_score(address: str) -> dict:
        """Get Risk Score for Crypto, Domain Name, ENS, CNS, KNS or even Hostname Address
    
        Args:
            address: EOA, CA, ENS, CNS, KNS or even HostName
        Returns:
            Dict: where summary.bicscan_score is from 0 to 100. 100 is high risk.
        """
    
        logger.info(f"Getting risk score for address: {address}")
        endpoint = "/v1/scan"
        data = {
            "query": address,
            "sync": True,
            "assets": False,
        }
    
        return await post_request(endpoint, data=data)
  • Supporting helper function used by get_risk_score to make authenticated POST requests to the BICScan API endpoint.
    async def post_request(
        endpoint: str, data: dict[str, Any] | None = None
    ) -> dict[str, Any] | None:
        """Make a request to BICScan API with proper error handling."""
        headers = {
            "User-Agent": "bicscan-mcp/1.0",
            "Accept": "application/json",
            "X-Api-Key": BICSCAN_API_KEY,
        }
        url = urljoin(BICSCAN_API_BASE, endpoint)
    
        async with httpx.AsyncClient() as client:
            try:
                logger.info(f"Making request to {url}")
                logger.debug(f"{headers=} {data=}")
                response = await client.post(url, headers=headers, json=data, timeout=30)
                response.raise_for_status()
                logger.info(f"Received response: {response.status_code}")
                return response.json()
            except httpx.HTTPStatusError as http_err:
                logger.error(f"Received response: {http_err}, {response.text}")
                return response.json()
            except Exception as e:
                logger.exception(f"Received response: {e}, {response.text}")
                return {}
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It adds some context by explaining the return format and risk score range (0-100, where 100 is high risk), which is useful beyond basic functionality. However, it lacks details on error handling, rate limits, or authentication needs, leaving gaps in behavioral understanding.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and front-loaded, with the purpose stated first, followed by parameter and return details. It avoids unnecessary fluff, but the formatting with 'Args:' and 'Returns:' could be more integrated for better flow.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (risk scoring with various address types), no annotations, and no output schema, the description is moderately complete. It covers purpose, parameter semantics, and return format, but lacks usage guidelines, error details, or behavioral traits like rate limits, making it adequate but with clear gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 0%, so the description must compensate. It adds meaning by listing examples of address types (EOA, CA, ENS, CNS, KNS, HostName), which clarifies the parameter's semantics beyond the schema's generic 'string' type. This significantly enhances understanding, though it could be more detailed on format constraints.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Get Risk Score for Crypto, Domain Name, ENS, CNS, KNS or even Hostname Address.' It specifies the verb 'Get' and the resource 'Risk Score,' with explicit examples of address types. However, it doesn't differentiate from the sibling tool 'get_assets,' which might have overlapping functionality, preventing a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives, such as the sibling tool 'get_assets.' It lists address types but doesn't specify contexts or exclusions for usage, leaving the agent without clear direction on tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ahnlabio/bicscan-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server