随机数生成工具

myalone/random-number
Hosted
2 Stars 2.1k 次浏览 transfer 更新于 2026-08-23
该服务暂未提供标准配置,请参考 README 手动接入

可用工具 (7 个)

该服务在 MCP 协议中暴露的工具,AI 可按需调用

random_int 2 个参数 需填 2 项

必填参数:low、high

random_float 2 个参数

该工具无需必填参数,直接调用即可

random_choices 3 个参数 需填 1 项

必填参数:population

random_shuffle 1 个参数 需填 1 项

必填参数:items

random_sample 2 个参数 需填 2 项

必填参数:population、k

secure_token_hex 1 个参数

该工具无需必填参数,直接调用即可

secure_random_int 1 个参数 需填 1 项

必填参数:upper_bound

服务介绍

随机数生成工具 random-number

提供伪随机和加密安全的随机数生成功能,包括整数、浮点数、加权选择、列表洗牌和安全令牌生成。
null## 工具列表 Tool List

本MCP服务封装下列工具,可让模型通过标准化接口调用以下功能。 本MCP服务封装下列工具,可让模型通过标准化接口调用以下功能。

工具 Tool 描述 Description
random_int Generate a random integer between low and high (inclusive). Args: low: Lower bound (inclusive) high: Upper bound (inclusive) Returns: Random integer between low and high
random_float Generate a random float between low and high. Args: low: Lower bound (default 0.0) high: Upper bound (default 1.0) Returns: Random float between low and high
random_choices Choose k items from population with replacement, optionally weighted. Args: population: List of items to choose from k: Number of items to choose (default 1) weights: Optional weights for each item (default None for equal weights) Returns: List of k chosen items
random_shuffle Return a new list with items in random order. Args: items: List of items to shuffle Returns: New list with items in random order
random_sample Choose k unique items from population without replacement. Args: population: List of items to choose from k: Number of items to choose Returns: List of k unique chosen items
secure_token_hex Generate a secure random hex token. Args: nbytes: Number of random bytes to generate (default 32) Returns: Hex string containing 2*nbytes characters
secure_random_int Generate a secure random integer below upper_bound. Args: upper_bound: Upper bound (exclusive) Returns: Random integer in range [0, upper_bound)

检查服务 ## Inspector

工具在线测试: https://mcp.xiaobenyang.com/inspector/1777419067540483

Online Tool test https://mcp.xiaobenyang.com/inspector/1777419067540483

服务配置 MCP Server Config

如何获取 XBY-APIKEY ? How to get XBY-APIKEY ?

访问小笨羊科技网站 https://xiaobenyang.com,注册用户即可获得APIKEY
Visit XiaoBenYang website https://xiaobenyang.com, register and get the APIKEY.

SSE

{
  "mcpServers": {
    "随机数生成工具": {
      "headers": {
        "XBY-APIKEY": "<YOUR_XBY_APIKEY>"
      },
      "type": "sse",
      "url": "https://mcp.xiaobenyang.com/1777419067540483/sse"
    }
  }
}

STREAMABLE HTTP

{
  "mcpServers": {
    "随机数生成工具": {
      "headers": {
        "XBY-APIKEY": "<YOUR_XBY_APIKEY>"
      },
      "type": "streamable_http",
      "url": "https://mcp.xiaobenyang.com/1777419067540483/mcp"
    }
  }
}

STDIO

{
    "mcpServers": {
        "随机数生成工具": {
          "command": "npx",
          "args": [
            "-y",
            "xiaobenyang-mcp"
          ],
          "env": {
            "XBY_APIKEY": "<YOUR_XBY_APIKEY>",
            "mcpId": "1777419067540483",
          },
          "transport": "stdio"
        }
      }
}

相关 MCP 服务