Skip to main content
Glama
solangii

Upbit MCP Server

get_order

Retrieve detailed information about a specific order on the Upbit cryptocurrency exchange using its UUID or custom identifier.

Instructions

업비트에서 특정 주문의 정보를 조회합니다.

Args:
    uuid (str, optional): 주문 UUID
    identifier (str, optional): 조회용 사용자 지정 값
    
Returns:
    dict: 주문 정보

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
uuidNo
identifierNo

Implementation Reference

  • The main handler function implementing the 'get_order' tool. It queries the Upbit API for order information using either a UUID or identifier, handles authentication, errors, and returns the order details as a dictionary.
    async def get_order(
        uuid: Optional[str] = None,
        identifier: Optional[str] = None,
        ctx: Context = None
    ) -> dict:
        """
        업비트에서 특정 주문의 정보를 조회합니다.
        
        Args:
            uuid (str, optional): 주문 UUID
            identifier (str, optional): 조회용 사용자 지정 값
            
        Returns:
            dict: 주문 정보
        """
        if not UPBIT_ACCESS_KEY:
            if ctx:
                ctx.error("API 키가 설정되지 않았습니다. .env 파일에 UPBIT_ACCESS_KEY와 UPBIT_SECRET_KEY를 설정해주세요.")
            return {"error": "API 키가 설정되지 않았습니다."}
        
        if not uuid and not identifier:
            if ctx:
                ctx.error("uuid 또는 identifier 중 하나는 필수입니다.")
            return {"error": "uuid 또는 identifier 중 하나는 필수입니다."}
        
        url = f"{API_BASE}/order"
        query_params = {}
        
        if uuid:
            query_params['uuid'] = uuid
        
        if identifier:
            query_params['identifier'] = identifier
        
        headers = {
            "Authorization": f"Bearer {generate_upbit_token(query_params)}"
        }
        
        if ctx:
            ctx.info(f"주문 정보 조회 중: {uuid or identifier}")
        async with httpx.AsyncClient() as client:
            try:
                res = await client.get(url, params=query_params, headers=headers)
                if res.status_code != 200:
                    if ctx:
                        ctx.error(f"업비트 API 오류: {res.status_code} - {res.text}")
                    return {"error": f"업비트 API 오류: {res.status_code}"}
                return res.json()
            except Exception as e:
                if ctx:
                    ctx.error(f"API 호출 중 오류 발생: {str(e)}")
                return {"error": f"API 호출 중 오류 발생: {str(e)}"}
  • main.py:48-48 (registration)
    Registration of the 'get_order' tool using the FastMCP decorator mcp.tool().
    mcp.tool()(get_order)
  • main.py:12-12 (registration)
    Import statement for the get_order handler function, necessary for registration.
    from tools.get_order import get_order
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states this is a retrieval operation ('조회합니다'), which implies read-only behavior, but doesn't mention authentication requirements, rate limits, error conditions, or what happens when parameters are omitted. The description adds minimal behavioral context beyond the basic operation.

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 efficiently structured with a clear purpose statement followed by Args and Returns sections. It's appropriately sized for a simple lookup tool, though the parameter documentation could be more detailed given the lack of schema coverage. Every sentence serves a purpose.

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

Completeness2/5

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

For a financial API tool with no annotations, no output schema, and 0% schema description coverage, the description is insufficient. It doesn't explain the return format beyond 'dict: 주문 정보' (dictionary: order information), doesn't mention authentication requirements for the Upbit platform, and provides minimal guidance on parameter usage. Given the complexity of financial APIs, more context is needed.

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

Parameters3/5

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

The description provides parameter information in the Args section, explaining that 'uuid' is the order UUID and 'identifier' is a user-defined value for lookup. However, with 0% schema description coverage, the schema provides no parameter documentation. The description adds meaningful semantics but doesn't fully compensate for the complete lack of schema documentation, especially regarding the relationship between the two optional parameters.

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: '업비트에서 특정 주문의 정보를 조회합니다' (Retrieves information about a specific order from Upbit). It specifies the verb ('조회합니다' - retrieves/checks) and resource ('특정 주문' - specific order), but doesn't explicitly differentiate from sibling tools like 'get_orders' (plural) which might retrieve multiple orders.

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. It doesn't mention sibling tools like 'get_orders' (for multiple orders) or 'cancel_order' (for order management), nor does it specify prerequisites or appropriate contexts for using this specific order lookup tool.

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/solangii/upbit-mcp-server'

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