GET_WITHDRAWAL
Retrieve details of a single withdrawal using its unique UUID. Requires private API access for secure retrieval.
Instructions
Get a single withdrawal by UUID (requires private API)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| uuid | Yes |
Implementation Reference
- src/tools/get-withdrawal.ts:14-26 (handler)The execute handler function that makes the authenticated GET /withdraw API call with a uuid parameter.
execute: async ({ uuid }: Params) => { ensurePrivateEnabled(); const baseURL = `${config.upbit.baseUrl}${config.upbit.apiBasePath}`; const client = createHttpClient(baseURL); const query = { uuid }; const token = signJwtToken(query); const data = await fetchJson<unknown>(client, "/withdraw", { params: query, headers: { Authorization: `Bearer ${token}` }, }); return JSON.stringify(data, null, 2); }, } as const; - src/tools/get-withdrawal.ts:6-6 (schema)Zod schema defining the required 'uuid' string parameter.
const paramsSchema = z.object({ uuid: z.string().min(1) }); - src/index.ts:41-41 (registration)Registration of the getWithdrawalTool on the MCP server via server.addTool(getWithdrawalTool).
server.addTool(getWithdrawalTool); - src/index.ts:17-17 (registration)Import of getWithdrawalTool from the tools module.
import { getWithdrawalTool } from "./tools/get-withdrawal.js"; - src/tools/get-withdrawal.ts:1-4 (helper)Imports for config, HTTP client, and Upbit auth helpers (ensurePrivateEnabled, signJwtToken).
import { z } from "zod"; import { config } from "../lib/config.js"; import { createHttpClient, fetchJson } from "../lib/http.js"; import { ensurePrivateEnabled, signJwtToken } from "../lib/upbit-auth.js";