mikrotik-rest-mcp

v0.1.2
io.github.Sogl/mikrotik-rest-mcp Checked 1 day ago Published 2 months ago

MikroTik RouterOS 7 REST MCP: filtered reads, guarded writes, timed rollback

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

get_containers

List RouterOS containers with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_dhcp_leases

List DHCP leases with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_dhcp_servers

List DHCP servers with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_files

List RouterOS files and directories with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_firewall_connections

List firewall connections with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_filter_rules

List firewall filter rules with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_nat_rules

List NAT rules with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_mangle_rules

List mangle rules with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_routes

List routes with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_routing_rules

List routing rules with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_routing_tables

List routing tables with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_interfaces

List interfaces with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_interface_lists

List interface lists with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_veth_interfaces

List veth interfaces with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_wifi_interfaces

List Wi-Fi interfaces with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_wifi_registrations

List Wi-Fi registration table entries with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_ip_addresses

List IP addresses with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_arp

List ARP entries with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_neighbors

List neighbor entries with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_dns_cache

List DNS cache entries with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_dns_static

List static DNS records with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_address_lists

List firewall address-list entries with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_wireguard_interfaces

List WireGuard interfaces with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_scripts

List system scripts with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_schedulers

List schedulers with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_wireguard_peers

List WireGuard peers with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_dns

Get RouterOS DNS configuration.

get_system_identity

Get RouterOS system identity.

get_system_clock

Get RouterOS system clock settings.

get_system_health

Get RouterOS system health summary.

get_system_logging

List RouterOS system logging rules with optional client-side filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

get_system_resource

Get RouterOS system resource summary.

get_logs

List router log entries. Supports limit, contains, fields, sort_by plus log-oriented filters.

ParameterTypeDescription
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sincestringKeep log entries with time >= this RouterOS timestamp string.
sort_bystringSort by a field name after filtering.
topicsarrayKeep entries whose topics string contains all of these fragments.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

run_ping

Run a bounded RouterOS ping diagnostic via POST /rest/ping.

ParameterTypeDescription
address *string
countinteger
interfacestring
src_addressstring
vrfstring

run_traceroute

Run a bounded RouterOS traceroute diagnostic via POST /rest/tool/traceroute.

ParameterTypeDescription
address *string
countinteger
interfacestring
max_hopsinteger
src_addressstring
use_dnsboolean
vrfstring

run_fetch

Run a bounded RouterOS fetch diagnostic with as-value output and no file writes.

ParameterTypeDescription
url *string
addressstring
hoststring
http_methodstring
outputstring

run_wifi_monitor

Run a one-shot RouterOS Wi-Fi monitor for an interface via POST /rest/interface/wifi/monitor.

ParameterTypeDescription
interface *string

read_file

Read a RouterOS file chunk via /rest/file/read and return base64 plus text preview when possible.

ParameterTypeDescription
file *string
chunk_sizeinteger
offsetinteger

download_file

Download a RouterOS file to a local path on this computer using repeated /rest/file/read chunks.

ParameterTypeDescription
file *string
local_path *string
chunk_sizeinteger
overwritebooleanReplace an existing local file (default: refuse).

create_file

Create a small RouterOS text file via PUT /rest/file.

ParameterTypeDescription
contents *string
name *string

update_file

Update contents of a small RouterOS text file via POST /rest/file/set.

ParameterTypeDescription
contents *string
name *string

rename_file

Rename a RouterOS file or directory via POST /rest/file/set.

ParameterTypeDescription
name *string
new_name *string

delete_file

Delete a RouterOS file or directory via POST /rest/file/remove.

ParameterTypeDescription
name *string
confirmbooleanSet true only after the user explicitly approves this deletion.

upload_file

Upload a small local UTF-8 text file to RouterOS via PUT /rest/file.

ParameterTypeDescription
local_path *string
remote_name *string

save_backup

Create a RouterOS binary backup file on the router via POST /rest/system/backup/save.

ParameterTypeDescription
name *string
dont_encryptboolean
passwordstring

save_export

Create a RouterOS text export file on the router via POST /rest/export.

ParameterTypeDescription
file *string
compactboolean
show_sensitiveboolean
terseboolean
verboseboolean

routeros_get

GET a RouterOS REST path starting with /rest/, then optionally filter the result.

ParameterTypeDescription
path *string
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
descendingbooleanReverse sort order when sort_by is set.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

routeros_write

Mutate a whitelisted RouterOS REST path using POST, PUT, PATCH or DELETE.

ParameterTypeDescription
method *string
path *string
confirmbooleanSet true only after the user explicitly approves a destructive/disruptive operation.
dataobject | array | string | number | boolean | null

patch_resource_by_id

PATCH a whitelisted RouterOS collection item by .id.

ParameterTypeDescription
collection_path *string
data *object
item_id *string
confirmbooleanSet true only after the user explicitly approves a destructive/disruptive operation.

flush_dns_cache

Flush MikroTik DNS cache.

ParameterTypeDescription
confirmbooleanSet true only after the user explicitly approves this operation.

run_script

Run RouterOS system script by name using /rest/system/script/run.

ParameterTypeDescription
name *string
confirmbooleanSet true only after the user explicitly approves running this script.

container_shell

Execute a shell command inside a RouterOS container by .id or name.

ParameterTypeDescription
cmd *string
container *stringContainer name or .id
timeout_secondsnumberOverride REST request timeout for long-running commands (default MIKROTIK_TIMEOUT=10s).

apply_safe

Apply a whitelisted mutation with automatic timed rollback. Snapshots the target, applies the change, and auto-reverts after window_seconds unless commit_safe is called. Rollback runs via an on-router scheduler when possible, else an in-process timer.

ParameterTypeDescription
method *string
path *stringItem path for PATCH/DELETE (/rest/<coll>/<.id>), collection path for PUT
dataobject
window_secondsinteger

container_apply_safe

Run a shell command inside a RouterOS container with snapshot + timed rollback. Copies snapshot_paths aside, runs cmd, optionally runs check_cmd (auto-rollback on non-zero), then arms an in-container watchdog that restores the snapshot after window_seconds unless container_commit_safe is called.

ParameterTypeDescription
cmd *stringMutation command to run
container *stringContainer name or .id
check_cmdstringValidation command; non-zero exit triggers immediate rollback
rollback_cmdstringExtra command appended to rollback (e.g. restart the service)
snapshot_pathsarrayFiles/dirs inside the container to back up before cmd
window_secondsinteger

container_commit_safe

Commit a change made via container_apply_safe, disarming its in-container rollback watchdog.

ParameterTypeDescription
pending_id *string

routeros_batch

Run up to 16 RouterOS GETs in parallel. Each request accepts the same filters as routeros_get (where/fields/limit/compact).

ParameterTypeDescription
requests *array

describe_path

Introspect a REST path: fetch up to N items and report their field names plus a sample. Useful before writing filters.

ParameterTypeDescription
path *string
sampleinteger

interface_traffic

Measure live rx/tx bitrate and packet rate of an interface over a short sampling window (0.5-10s).

ParameterTypeDescription
name *string
secondsnumber

routeros_watch

Sample a REST path N times with an interval; optionally report per-item deltas of numeric fields (diff=true). Useful for watching counters, traffic, registrations.

ParameterTypeDescription
path *string
compactbooleanEmit compact single-line JSON per item instead of pretty-printed output.
containsstringCase-insensitive substring search across the rendered item.
countinteger
descendingbooleanReverse sort order when sort_by is set.
diffbooleanReport field deltas between first and last sample instead of raw samples.
fieldsarrayClient-side field projection applied after any RouterOS .proplist request.
intervalnumber
limitintegerLimit returned items after filtering and sorting.
proplistOptional RouterOS .proplist for server-side property selection on POST .../print.
query_wordsarrayOptional RouterOS .query stack for server-side filtering on POST .../print.
sort_bystringSort by a field name after filtering.
whereobjectClient-side filters applied after any RouterOS .query/.proplist request. Exact match by field, or use suffixes __contains / __in / __not / __startswith / __endswith / __gt / __gte / __lt / __lte.

run_script_inline

Create a temporary RouterOS script, execute it, and remove it. Requires a policy-capable user (yolo mode); always asks for confirmation in careful mode.

ParameterTypeDescription
script *string
confirmbooleanSet true only after the user explicitly approves executing this script.

commit_safe

Commit a change made via apply_safe, cancelling its automatic rollback.

ParameterTypeDescription
pending_id *string

safe_status

List pending apply_safe operations and their rollback state.