useSignal
QR codes, JSON diff/format, hashes, JWT, cron, timestamps, placeholders, flowcharts, forms, regex.
我該用這個嗎
品質與安全性
發現項目(3)
- HIGH
- MEDIUM在 usesignal_placeholder_image 中
- INFO在 usesignal_placeholder_image 中
根據工具定義與協定合規性的自動化分析。
上下文成本
這是每次將伺服器的工具載入模型上下文時所消耗的約略 token 數量。數量越高,可用於其他工作的注意力就越少。
安裝
一鍵安裝
將以下內容加入你的 `claude_desktop_config.json` 檔案:
{
"mcpServers": {
"usesignal": {
"url": "https://www.usesignal.dev/mcp"
}
}
}遠端端點
https://www.usesignal.dev/mcpstreamable-http它能做什麼
工具清單
工具(12)
🟢usesignal_generate_form(json, title, overrides)
Generate an editable form from a JSON object. Returns nested field paths, JSON Schema, HTML, React JSX and config exports. Arrays and nulls use JSON textareas. Values are processed in memory; avoid secrets. To show an interactive preview, call usesignal_open_workbench with this result input.
輸入結構描述
{
"type": "object",
"properties": {
"json": {
"type": "string",
"maxLength": 50000
},
"title": {
"type": "string",
"maxLength": 120,
"default": "Generated form"
},
"overrides": {
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "array",
"items": {
"type": "string"
},
"maxItems": 9
},
"label": {
"type": "string",
"maxLength": 120
},
"type": {
"type": "string",
"enum": [
"text",
"email",
"number",
"checkbox",
"textarea"
]
},
"required": {
"type": "boolean"
}
},
"required": [
"path"
],
"additionalProperties": false
},
"maxItems": 100,
"default": []
}
},
"required": [
"json"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_generate_colors(baseColor)
Generate light and dark semantic color tokens from a six-digit hex brand color. Returns a shade scale, measured text contrast checks and CSS, JSON and Tailwind exports. This measures listed color pairs only, not whole-page accessibility. Call usesignal_open_workbench with the result input to preview.
輸入結構描述
{
"type": "object",
"properties": {
"baseColor": {
"type": "string",
"pattern": "^#[0-9a-fA-F]{6}$"
}
},
"required": [
"baseColor"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_test_regex(pattern, flags, text, tests)
Execute a JavaScript regular expression against text and expected match/non-match test cases. Returns indexed matches and capture groups. Flags use JavaScript semantics. Execution times out after 500ms. Call usesignal_open_workbench with result input to highlight matches.
輸入結構描述
{
"type": "object",
"properties": {
"pattern": {
"type": "string",
"maxLength": 1000
},
"flags": {
"type": "string",
"maxLength": 8,
"default": "g"
},
"text": {
"type": "string",
"maxLength": 20000
},
"tests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"text": {
"type": "string",
"maxLength": 2000
},
"shouldMatch": {
"type": "boolean"
}
},
"required": [
"text",
"shouldMatch"
],
"additionalProperties": false
},
"maxItems": 50,
"default": []
}
},
"required": [
"pattern",
"text"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_generate_qr(type, values, dark, light, moduleStyle, ...)
Generate a scannable QR code for a link, text, Wi-Fi network, contact card (vCard), email, SMS, phone number, WhatsApp chat or UPI payment. Returns the encoded payload, an SVG file and a PNG preview image. values by type: url{url}; text{text}; wifi{ssid,password,security:WPA|WEP|nopass,hidden}; vcard{firstName,lastName,phone,email,org,title,website,address}; email{to,subject,body}; sms{phone,message}; phone{phone}; whatsapp{phone,message}; upi{vpa,name,amount,note}.
輸入結構描述
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"url",
"text",
"wifi",
"upi",
"vcard",
"whatsapp",
"email",
"sms",
"phone"
]
},
"values": {
"type": "object",
"additionalProperties": {
"anyOf": [
{
"type": "string",
"maxLength": 2000
},
{
"type": "boolean"
},
{
"type": "number"
}
]
}
},
"dark": {
"type": "string",
"pattern": "^#[0-9a-fA-F]{6}$",
"default": "#111111"
},
"light": {
"$ref": "#/properties/dark",
"default": "#FFFFFF"
},
"moduleStyle": {
"type": "string",
"enum": [
"square",
"rounded",
"dots"
],
"default": "square"
},
"errorCorrection": {
"type": "string",
"enum": [
"L",
"M",
"Q",
"H"
],
"default": "M"
},
"margin": {
"type": "integer",
"minimum": 0,
"maximum": 16,
"default": 4
}
},
"required": [
"type",
"values"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_encode_decode(operation, text)
Exact text transforms: Base64 encode/decode (UTF-8), URL encode/decode, decode a JWT header and payload with readable exp/iat/nbf dates (the signature is not verified), or hash text with MD5, SHA-1, SHA-256 and SHA-512. Use this instead of computing hashes or Base64 by hand.
輸入結構描述
{
"type": "object",
"properties": {
"operation": {
"type": "string",
"enum": [
"base64_encode",
"base64_decode",
"url_encode",
"url_decode",
"jwt_decode",
"hash"
]
},
"text": {
"type": "string",
"maxLength": 100000
}
},
"required": [
"operation",
"text"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_explain_cron(expression, timeZone, count)
Explain a standard 5-field cron expression (minute hour day-of-month month day-of-week) in plain English and list its next run times in a given time zone, handling daylight saving time.
輸入結構描述
{
"type": "object",
"properties": {
"expression": {
"type": "string",
"maxLength": 200
},
"timeZone": {
"type": "string",
"maxLength": 64,
"default": "UTC",
"description": "IANA time zone, e.g. Asia/Kolkata or America/New_York"
},
"count": {
"type": "integer",
"minimum": 1,
"maximum": 20,
"default": 5
}
},
"required": [
"expression"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_convert_timestamp(value, timeZone)
Convert a Unix timestamp (seconds or milliseconds) or an ISO 8601 date into ISO, UTC, epoch seconds/milliseconds, a relative time and the local time in a given time zone.
輸入結構描述
{
"type": "object",
"properties": {
"value": {
"type": "string",
"maxLength": 100
},
"timeZone": {
"type": "string",
"maxLength": 64,
"default": "UTC",
"description": "IANA time zone, e.g. Asia/Kolkata or America/New_York"
}
},
"required": [
"value"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_diff_json(left, right, arrays)
Compare two JSON documents structurally and list every added, removed and changed value with its JSONPath. Numbers compare exactly. Arrays match by content by default, so an inserted item shows as one addition; use arrays:"position" to compare index by index.
輸入結構描述
{
"type": "object",
"properties": {
"left": {
"type": "string",
"maxLength": 200000
},
"right": {
"type": "string",
"maxLength": 200000
},
"arrays": {
"type": "string",
"enum": [
"content",
"position"
],
"default": "content"
}
},
"required": [
"left",
"right"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_format_json(json, mode, indent, sortKeys, repair)
Validate, pretty-print or minify JSON, optionally sorting keys. Invalid JSON reports the exact line and column; with repair (default on) it fixes common problems such as trailing commas, single quotes, comments and unquoted keys, and lists each fix.
輸入結構描述
{
"type": "object",
"properties": {
"json": {
"type": "string",
"maxLength": 200000
},
"mode": {
"type": "string",
"enum": [
"format",
"minify"
],
"default": "format"
},
"indent": {
"type": "string",
"enum": [
"2",
"4",
"tab"
],
"default": "2"
},
"sortKeys": {
"type": "boolean",
"default": false
},
"repair": {
"type": "boolean",
"default": true
}
},
"required": [
"json"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_placeholder_image(width, height, text, background, color, ...)
Create a placeholder image URL (served by usesignal.dev) plus HTML, Markdown and CSS snippets, for mockups, prototypes, seed data and layouts. Width and height up to 4000 px.
輸入結構描述
{
"type": "object",
"properties": {
"width": {
"type": "integer",
"minimum": 1,
"maximum": 4000
},
"height": {
"type": "integer",
"minimum": 1,
"maximum": 4000
},
"text": {
"type": "string",
"maxLength": 120
},
"background": {
"type": "string",
"pattern": "^#[0-9a-fA-F]{6}$"
},
"color": {
"$ref": "#/properties/background"
},
"style": {
"type": "string",
"enum": [
"minimal",
"grid",
"gradient",
"dark",
"glass"
],
"default": "minimal"
},
"pattern": {
"type": "string",
"enum": [
"plain",
"grid",
"diagonal",
"dots",
"minimal"
]
},
"radius": {
"type": "integer",
"minimum": 0,
"maximum": 999
}
},
"required": [
"width",
"height"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_flowchart(mode, input, direction)
Turn JavaScript/TypeScript code, arrow steps or Mermaid-style arrows into a flowchart, returned as Mermaid source and an SVG diagram. Steps mode uses one flow per line: "Start -> Validate -> Save" and branches like "Validate -- No --> Show error".
輸入結構描述
{
"type": "object",
"properties": {
"mode": {
"type": "string",
"enum": [
"code",
"steps",
"mermaid"
]
},
"input": {
"type": "string",
"maxLength": 20000
},
"direction": {
"type": "string",
"enum": [
"vertical",
"horizontal"
],
"default": "vertical"
}
},
"required": [
"mode",
"input"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}🟢usesignal_open_workbench(tool, input)
Show the editable useSignal UI. First call a useSignal data tool, then pass its returned input and matching tool name. Recomputes from validated inputs; no shared state.
輸入結構描述
{
"type": "object",
"properties": {
"tool": {
"type": "string",
"enum": [
"usesignal_generate_form",
"usesignal_generate_colors",
"usesignal_test_regex",
"usesignal_generate_qr",
"usesignal_encode_decode",
"usesignal_explain_cron",
"usesignal_convert_timestamp",
"usesignal_diff_json",
"usesignal_format_json",
"usesignal_placeholder_image",
"usesignal_flowchart"
]
},
"input": {
"type": "object",
"additionalProperties": {}
}
},
"required": [
"tool",
"input"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}社群
證據