Skip to main content
Glama

set_client_bandwidth

Limit or update a client's bandwidth by configuring a RouterOS Simple Queue with upload/download rates; preview changes before confirming.

Instructions

Limit a client's bandwidth via a RouterOS Simple Queue (/queue/simple).

target is the client's IP address or subnet (e.g. "10.0.0.5" or "10.0.0.0/24"). max_limit is a RouterOS rate pair in "upload/download" form (e.g. "10M/5M"); limit_at is the optional guaranteed-rate (CIR) pair in the same form. If a Simple Queue already targets target, its max-limit/limit-at is UPDATED; otherwise a new one is CREATED with a name derived from target - the returned operation field ("set_client_bandwidth_update" vs "set_client_bandwidth_add") tells you which happened (or would happen, with confirm=False).

WRITE tool, guarded: blocked entirely unless the server is running with MIKROTIK_ALLOW_WRITE=true. Call with confirm=False (the default) to get a before/after preview without changing anything; call again with confirm=True to actually apply it.

GOTCHA - FastTrack: if the device has a FastTrack rule in its firewall (common on RouterOS's own quick-set wizards), fasttracked connections bypass queueing entirely, so this queue may have no visible effect on a client whose traffic is already fasttracked - see README's "Security model" section.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
targetYes
confirmNo
limit_atNo
max_limitYes
device_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.11.0

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations provided, the description carries the full burden and does so: it discloses that this is a guarded WRITE operation, the environment flag required, the preview/apply two-step, the update-vs-create branching behavior, and the operation field that reveals which occurred. It even flags the non-obvious FastTrack caveat that can silently negate the queue's effect.

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?

The purpose and required arguments are front-loaded, followed by the confirm workflow and then the FastTrack gotcha. Despite its length, every paragraph adds operational information an agent needs, with no filler.

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

Completeness5/5

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

For a five-parameter write tool with an output schema, the description covers the mutation semantics, the safety gate, the preview/apply workflow, the branching return indicator, and a critical environmental caveat. Nothing an agent needs in order to invoke it correctly is missing.

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

Parameters4/5

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

Schema description coverage is 0%, so the description must compensate, and it defines target (IP or subnet with examples), max_limit (upload/download rate pair), limit_at (optional CIR pair), and confirm (default preview behavior). Only device_name goes unexplained, leaving one of five parameters undocumented.

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

Purpose5/5

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

The description states a specific verb and resource - limiting a client's bandwidth by creating or updating a RouterOS Simple Queue - and names the underlying path (/queue/simple). It is clearly distinguishable from siblings such as remove_simple_queue and simple_queues, which read or delete rather than set.

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

Usage Guidelines4/5

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

It gives an explicit usage protocol: call with confirm=False for a preview, then confirm=True to apply, and it warns that the tool is blocked unless MIKROTIK_ALLOW_WRITE=true. It does not explicitly point to sibling alternatives (e.g., remove_simple_queue for teardown), so it falls just short of a 5.

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