Skip to main content
Glama
jikime

Naver Search MCP Server

check_adult_query

Identify adult content in search queries to filter inappropriate results and maintain safe search environments.

Instructions

Determines if the input query is an adult search term.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes

Implementation Reference

  • The main handler function for the 'check_adult_query' tool. It takes a query string, calls the shared _make_api_call helper with the Naver adult check endpoint, and returns a formatted string result.
    async def check_adult_query(query: str) -> str: """ Determines if the input query is an adult search term. Args: query (str): The keyword to search for """ params = {"query": query} return await _make_api_call("adult.json", params, AdultResult, "Adult Search Term")
  • Pydantic BaseModel defining the output schema for the adult query check API response, with a single 'adult' field (likely 0 or 1 indicating if it's adult content).
    class AdultResult(BaseModel): adult: str
  • server.py:419-422 (registration)
    MCP decorator that registers the 'check_adult_query' tool, specifying its name and description. The input schema is inferred from the function signature (query: str).
    @mcp.tool( name="check_adult_query", description="Determines if the input query is an adult search term." )
  • Specific handling logic within the shared _make_api_call helper function for formatting AdultResult responses into Korean text ("일반 검색어" or "성인 검색어"). This is called by the handler.
    elif isinstance(result, AdultResult): prompt_string = f"네이버 {search_type_name} 확인 결과:" if result.adult == 0: return f"{prompt_string} 일반 검색어" else: return f"{prompt_string} 성인 검색어"

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/jikime/py-mcp-naver-search'

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