Skip to main content
Glama
unifi-mcp-server

unifi-mcp-server

by PainInTheNic

Generate Hotspot Vouchers

unifi_generate_vouchers

Generate guest WiFi hotspot voucher codes with optional time, data, and bandwidth limits; returns codes to share with guests for access.

Instructions

Generate new guest hotspot voucher codes with optional time/data/bandwidth limits. Returns the generated codes — share them with guests to grant WiFi access.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>"
    },
    "name": "unifi_generate_vouchers"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesLabel for this batch of vouchers, e.g. 'Weekend guests'. Must not contain the text "[redacted]" (the placeholder reads show for credentials): a label containing it is refused.
countNoHow many voucher codes to generate (default 1)
siteIdNoSite ID (UUID from unifi_list_sites). Optional — when the console has exactly one site it is used automatically.
rxRateLimitKbpsNoDownload rate limit in Kbps (omit for unlimited)
txRateLimitKbpsNoUpload rate limit in Kbps (omit for unlimited)
timeLimitMinutesNoMinutes each voucher grants access for (default 1440 = 24h)
authorizedGuestLimitNoHow many guests may redeem one voucher (omit for unlimited)
dataUsageLimitMBytesNoData cap per guest in megabytes (omit for unlimited)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=false, idempotentHint=false, destructiveHint=false and openWorldHint=true, so the agent knows this is a non-idempotent, non-destructive write. The description adds that the codes are returned for distribution, but says nothing about whether repeated calls accumulate batches, whether codes can be re-fetched later, or what permissions are needed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tightly scoped sentences: the first states the action and its knobs, the second states the return and the real-world purpose. Nothing is padded or repeated from the schema.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter mutation with no output schema, the description covers the action and the shape of the result (generated codes) and the schema covers every parameter thoroughly. Minor gaps remain around batch lifecycle (re-listing vouchers, idempotency implications), which the sibling list could otherwise supply.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, including defaults, ranges, the site UUID resolution fallback, and the '[redacted]'-in-name refusal rule, so the schema carries nearly all parameter meaning. The description only alludes generally to 'time/data/bandwidth limits', adding no detail beyond the schema — baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource ('Generate new guest hotspot voucher codes') plus the limit dimensions the codes can carry, and states what comes back ('Returns the generated codes'). It does not explicitly contrast with the voucher siblings (unifi_list_vouchers, unifi_delete_vouchers), but 'generate new' is unambiguous enough on its own.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by the sentence 'share them with guests to grant WiFi access', which frames the scenario. However, there is no explicit when-to-use versus when-to-list/delete guidance, and no stated prerequisites such as a configured hotspot network or which site the vouchers land in.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools