GET_DEPOSIT_CHANCE
Verify deposit availability for a cryptocurrency on Upbit by specifying the currency and optional network type.
Instructions
Get deposit availability information for a currency (private)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| currency | Yes | ||
| net_type | No |
Implementation Reference
- src/tools/get-deposit-chance.ts:15-31 (handler)The main tool definition and execute handler for GET_DEPOSIT_CHANCE. It validates params, ensures private auth, builds a JWT token, and calls the Upbit /deposits/chance/coin API.
export const getDepositChanceTool = { name: "GET_DEPOSIT_CHANCE", description: "Get deposit availability information for a currency (private)", parameters: paramsSchema, execute: async ({ currency, net_type }: Params) => { ensurePrivateEnabled(); const baseURL = `${config.upbit.baseUrl}${config.upbit.apiBasePath}`; const client = createHttpClient(baseURL); const query = { currency, net_type }; const token = signJwtToken(query); const data = await fetchJson<unknown>(client, "/deposits/chance/coin", { params: query, headers: { Authorization: `Bearer ${token}` }, }); return JSON.stringify(data, null, 2); }, } as const; - src/tools/get-deposit-chance.ts:6-11 (schema)Zod schema defining input parameters: currency (required string) and net_type (optional string).
const paramsSchema = z .object({ currency: z.string(), net_type: z.string().optional(), }) .strict(); - src/index.ts:44-44 (registration)Registration of getDepositChanceTool with the FastMCP server via server.addTool().
server.addTool(getDepositChanceTool); - src/index.ts:11-11 (registration)Import of getDepositChanceTool from the get-deposit-chance module.
import { getDepositChanceTool } from "./tools/get-deposit-chance.js"; - src/tools/get-deposit-chance.ts:2-4 (helper)Imports for config, HTTP client, and Upbit auth helpers (ensurePrivateEnabled, signJwtToken) used by the handler.
import { config } from "../lib/config.js"; import { createHttpClient, fetchJson } from "../lib/http.js"; import { ensurePrivateEnabled, signJwtToken } from "../lib/upbit-auth.js";