UUID, 숫자, 문자열, 비밀번호, 가우시안 분포, 주사위 굴리기, 카드 뽑기 등 다양한 난수 생성 유틸리티를 제공하는 MCP(모델 컨텍스트 프로토콜) 서버입니다.
// Generate UUID
const uuid = await client.callTool('generate_uuid', {});
console.log(uuid); // e.g., "550e8400-e29b-41d4-a716-446655440000"
// Generate random number
const number = await client.callTool('generate_random_number', {
min: 1,
max: 100
});
console.log(number); // e.g., 42
// Generate Gaussian random number
const gaussian = await client.callTool('generate_gaussian', {});
console.log(gaussian); // e.g., 0.6827
// Generate random string
const string = await client.callTool('generate_string', {
length: 15,
charset: 'alphanumeric'
});
console.log(string); // e.g., "aB9cD8eF7gH6iJ5"
// Generate password
const password = await client.callTool('generate_password', {
length: 20
});
console.log(password); // e.g., "aB9#cD8$eF7@gH6*iJ5"
// Roll dice
const rolls = await client.callTool('roll_dice', {
dice: ['2d6', '1d20', '4d4']
});
console.log(rolls);
/* Output example:
[
{
"dice": "2d6",
"rolls": [3, 1],
"total": 4
},
{
"dice": "1d20",
"rolls": [4],
"total": 4
},
{
"dice": "4d4",
"rolls": [2, 3, 2, 3],
"total": 10
}
]
*/
// Draw cards
const draw1 = await client.callTool('draw_cards', {
count: 5
});
console.log(draw1);
/* Output example:
{
"drawnCards": [
{ "suit": "hearts", "value": "A" },
{ "suit": "diamonds", "value": "7" },
{ "suit": "clubs", "value": "K" },
{ "suit": "spades", "value": "2" },
{ "suit": "hearts", "value": "10" }
],
"remainingCount": 47,
"deckState": "t//+///bDw=="
}
*/
// Draw more cards using previous deck state
const draw2 = await client.callTool('draw_cards', {
count: 3,
deckState: draw1.deckState
});
console.log(draw2);
/* Output example:
{
"drawnCards": [
{ "suit": "diamonds", "value": "Q" },
{ "suit": "clubs", "value": "5" },
{ "suit": "spades", "value": "J" }
],
"remainingCount": 44,
"deckState": "l//+//zbDw=="
}
*/