@usex/mikrotik-mcp 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (484) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +296 -0
  3. package/dist/cli.js +12165 -0
  4. package/dist/index.d.ts +153 -0
  5. package/dist/index.js +11955 -0
  6. package/package.json +107 -0
  7. package/prompts/backup-and-document.md +31 -0
  8. package/prompts/choose-vpn-solution.md +45 -0
  9. package/prompts/diagnose-connectivity.md +38 -0
  10. package/prompts/harden-router.md +38 -0
  11. package/prompts/setup-guest-wifi.md +44 -0
  12. package/prompts/setup-ipsec-site-to-site.md +50 -0
  13. package/prompts/setup-l2tp-ipsec-roadwarrior.md +41 -0
  14. package/prompts/setup-tunnel-between-sites.md +56 -0
  15. package/prompts/setup-wireguard-vpn.md +41 -0
  16. package/schemas/README.md +14 -0
  17. package/schemas/config.schema.json +128 -0
  18. package/schemas/tool-catalog.json +14938 -0
  19. package/schemas/tools/add_address_list_entry.json +32 -0
  20. package/schemas/tools/add_bfd_configuration.json +41 -0
  21. package/schemas/tools/add_bgp_connection.json +90 -0
  22. package/schemas/tools/add_bgp_template.json +45 -0
  23. package/schemas/tools/add_blackhole_route.json +26 -0
  24. package/schemas/tools/add_bridge_port.json +33 -0
  25. package/schemas/tools/add_bridge_vlan.json +28 -0
  26. package/schemas/tools/add_default_route.json +29 -0
  27. package/schemas/tools/add_dns_regexp.json +31 -0
  28. package/schemas/tools/add_dns_static.json +63 -0
  29. package/schemas/tools/add_igmp_proxy_interface.json +39 -0
  30. package/schemas/tools/add_ip_address.json +33 -0
  31. package/schemas/tools/add_logging_action.json +71 -0
  32. package/schemas/tools/add_logging_rule.json +28 -0
  33. package/schemas/tools/add_netwatch.json +39 -0
  34. package/schemas/tools/add_ospf_area.json +45 -0
  35. package/schemas/tools/add_ospf_area_range.json +34 -0
  36. package/schemas/tools/add_ospf_instance.json +54 -0
  37. package/schemas/tools/add_ospf_interface_template.json +85 -0
  38. package/schemas/tools/add_pimsm_instance.json +40 -0
  39. package/schemas/tools/add_pimsm_interface_template.json +38 -0
  40. package/schemas/tools/add_pimsm_rp.json +32 -0
  41. package/schemas/tools/add_radius_server.json +63 -0
  42. package/schemas/tools/add_rip_instance.json +44 -0
  43. package/schemas/tools/add_rip_interface_template.json +35 -0
  44. package/schemas/tools/add_rip_static_neighbor.json +27 -0
  45. package/schemas/tools/add_route.json +56 -0
  46. package/schemas/tools/add_routing_filter_num_list.json +23 -0
  47. package/schemas/tools/add_routing_filter_rule.json +32 -0
  48. package/schemas/tools/add_routing_id.json +31 -0
  49. package/schemas/tools/add_routing_rule.json +63 -0
  50. package/schemas/tools/add_routing_table.json +29 -0
  51. package/schemas/tools/add_rpki_session.json +51 -0
  52. package/schemas/tools/add_script.json +29 -0
  53. package/schemas/tools/add_user.json +34 -0
  54. package/schemas/tools/add_user_group.json +27 -0
  55. package/schemas/tools/add_user_manager_limitation.json +34 -0
  56. package/schemas/tools/add_user_manager_profile.json +39 -0
  57. package/schemas/tools/add_user_manager_router.json +36 -0
  58. package/schemas/tools/add_user_manager_user.json +41 -0
  59. package/schemas/tools/add_wireguard_peer.json +47 -0
  60. package/schemas/tools/assign_user_manager_profile.json +20 -0
  61. package/schemas/tools/backup_info.json +14 -0
  62. package/schemas/tools/bandwidth_test.json +50 -0
  63. package/schemas/tools/change_password.json +20 -0
  64. package/schemas/tools/check_for_updates.json +7 -0
  65. package/schemas/tools/check_route_path.json +20 -0
  66. package/schemas/tools/check_wireless_support.json +7 -0
  67. package/schemas/tools/clear_logs.json +7 -0
  68. package/schemas/tools/commit_safe_mode.json +7 -0
  69. package/schemas/tools/create_backup.json +26 -0
  70. package/schemas/tools/create_basic_firewall_setup.json +7 -0
  71. package/schemas/tools/create_bridge.json +44 -0
  72. package/schemas/tools/create_certificate.json +48 -0
  73. package/schemas/tools/create_dhcp_network.json +51 -0
  74. package/schemas/tools/create_dhcp_pool.json +25 -0
  75. package/schemas/tools/create_dhcp_server.json +48 -0
  76. package/schemas/tools/create_eoip_tunnel.json +48 -0
  77. package/schemas/tools/create_export.json +51 -0
  78. package/schemas/tools/create_filter_rule.json +96 -0
  79. package/schemas/tools/create_gre_tunnel.json +53 -0
  80. package/schemas/tools/create_ip_pool.json +25 -0
  81. package/schemas/tools/create_ipip_tunnel.json +41 -0
  82. package/schemas/tools/create_ipsec_identity.json +58 -0
  83. package/schemas/tools/create_ipsec_peer.json +52 -0
  84. package/schemas/tools/create_ipsec_policy.json +66 -0
  85. package/schemas/tools/create_ipsec_profile.json +49 -0
  86. package/schemas/tools/create_ipsec_proposal.json +37 -0
  87. package/schemas/tools/create_l2tp_client.json +57 -0
  88. package/schemas/tools/create_nat_rule.json +71 -0
  89. package/schemas/tools/create_ovpn_client.json +73 -0
  90. package/schemas/tools/create_ppp_profile.json +62 -0
  91. package/schemas/tools/create_ppp_secret.json +54 -0
  92. package/schemas/tools/create_pptp_client.json +44 -0
  93. package/schemas/tools/create_queue_tree.json +62 -0
  94. package/schemas/tools/create_queue_type.json +158 -0
  95. package/schemas/tools/create_scheduler.json +40 -0
  96. package/schemas/tools/create_simple_queue.json +66 -0
  97. package/schemas/tools/create_sstp_client.json +52 -0
  98. package/schemas/tools/create_vlan_interface.json +60 -0
  99. package/schemas/tools/create_vxlan_tunnel.json +51 -0
  100. package/schemas/tools/create_wireguard_interface.json +35 -0
  101. package/schemas/tools/create_wireless_access_list.json +7 -0
  102. package/schemas/tools/create_wireless_interface.json +74 -0
  103. package/schemas/tools/create_wireless_security_profile.json +14 -0
  104. package/schemas/tools/disable_address_list_entry.json +15 -0
  105. package/schemas/tools/disable_dns_static.json +14 -0
  106. package/schemas/tools/disable_filter_rule.json +14 -0
  107. package/schemas/tools/disable_interface.json +14 -0
  108. package/schemas/tools/disable_ip_service.json +15 -0
  109. package/schemas/tools/disable_l2tp_client.json +14 -0
  110. package/schemas/tools/disable_nat_rule.json +14 -0
  111. package/schemas/tools/disable_ovpn_client.json +14 -0
  112. package/schemas/tools/disable_queue_tree.json +14 -0
  113. package/schemas/tools/disable_radius_server.json +15 -0
  114. package/schemas/tools/disable_route.json +15 -0
  115. package/schemas/tools/disable_scheduler.json +14 -0
  116. package/schemas/tools/disable_simple_queue.json +14 -0
  117. package/schemas/tools/disable_user.json +14 -0
  118. package/schemas/tools/disable_wireguard_interface.json +14 -0
  119. package/schemas/tools/disable_wireguard_peer.json +15 -0
  120. package/schemas/tools/disable_wireless_interface.json +14 -0
  121. package/schemas/tools/disconnect_ppp_active.json +15 -0
  122. package/schemas/tools/disconnect_user.json +14 -0
  123. package/schemas/tools/download_file.json +23 -0
  124. package/schemas/tools/enable_address_list_entry.json +15 -0
  125. package/schemas/tools/enable_dns_static.json +14 -0
  126. package/schemas/tools/enable_filter_rule.json +14 -0
  127. package/schemas/tools/enable_interface.json +14 -0
  128. package/schemas/tools/enable_ip_service.json +15 -0
  129. package/schemas/tools/enable_l2tp_client.json +14 -0
  130. package/schemas/tools/enable_nat_rule.json +14 -0
  131. package/schemas/tools/enable_ovpn_client.json +14 -0
  132. package/schemas/tools/enable_queue_tree.json +14 -0
  133. package/schemas/tools/enable_radius_server.json +15 -0
  134. package/schemas/tools/enable_route.json +15 -0
  135. package/schemas/tools/enable_safe_mode.json +7 -0
  136. package/schemas/tools/enable_scheduler.json +14 -0
  137. package/schemas/tools/enable_simple_queue.json +14 -0
  138. package/schemas/tools/enable_user.json +14 -0
  139. package/schemas/tools/enable_wireguard_interface.json +14 -0
  140. package/schemas/tools/enable_wireguard_peer.json +15 -0
  141. package/schemas/tools/enable_wireless_interface.json +14 -0
  142. package/schemas/tools/expand_ip_pool.json +19 -0
  143. package/schemas/tools/export_dns_config.json +11 -0
  144. package/schemas/tools/export_logs.json +28 -0
  145. package/schemas/tools/export_section.json +27 -0
  146. package/schemas/tools/export_user_config.json +11 -0
  147. package/schemas/tools/flush_dns_cache.json +7 -0
  148. package/schemas/tools/flush_ipsec_installed_sa.json +7 -0
  149. package/schemas/tools/flush_route_cache.json +7 -0
  150. package/schemas/tools/format_disk.json +34 -0
  151. package/schemas/tools/generate_wireguard_client_config.json +48 -0
  152. package/schemas/tools/get_active_users.json +7 -0
  153. package/schemas/tools/get_address_list_entry.json +15 -0
  154. package/schemas/tools/get_bgp_connection.json +15 -0
  155. package/schemas/tools/get_bridge.json +14 -0
  156. package/schemas/tools/get_certificate.json +14 -0
  157. package/schemas/tools/get_dhcp_server.json +14 -0
  158. package/schemas/tools/get_disk.json +15 -0
  159. package/schemas/tools/get_dns_cache.json +7 -0
  160. package/schemas/tools/get_dns_cache_statistics.json +7 -0
  161. package/schemas/tools/get_dns_settings.json +7 -0
  162. package/schemas/tools/get_dns_static.json +14 -0
  163. package/schemas/tools/get_eoip_tunnel.json +14 -0
  164. package/schemas/tools/get_filter_rule.json +15 -0
  165. package/schemas/tools/get_gre_tunnel.json +14 -0
  166. package/schemas/tools/get_igmp_proxy_settings.json +7 -0
  167. package/schemas/tools/get_installed_packages.json +7 -0
  168. package/schemas/tools/get_interface.json +15 -0
  169. package/schemas/tools/get_ip_address.json +15 -0
  170. package/schemas/tools/get_ip_pool.json +14 -0
  171. package/schemas/tools/get_ip_service.json +15 -0
  172. package/schemas/tools/get_ipip_tunnel.json +14 -0
  173. package/schemas/tools/get_ipsec_active_peers.json +7 -0
  174. package/schemas/tools/get_ipsec_installed_sa.json +7 -0
  175. package/schemas/tools/get_ipsec_peer.json +14 -0
  176. package/schemas/tools/get_ipsec_profile.json +14 -0
  177. package/schemas/tools/get_ipsec_proposal.json +14 -0
  178. package/schemas/tools/get_ipsec_statistics.json +7 -0
  179. package/schemas/tools/get_l2tp_client.json +14 -0
  180. package/schemas/tools/get_l2tp_server.json +7 -0
  181. package/schemas/tools/get_leds_settings.json +7 -0
  182. package/schemas/tools/get_license.json +7 -0
  183. package/schemas/tools/get_log_statistics.json +7 -0
  184. package/schemas/tools/get_logs.json +45 -0
  185. package/schemas/tools/get_logs_by_severity.json +29 -0
  186. package/schemas/tools/get_logs_by_topic.json +22 -0
  187. package/schemas/tools/get_nat_rule.json +15 -0
  188. package/schemas/tools/get_netwatch.json +14 -0
  189. package/schemas/tools/get_note.json +7 -0
  190. package/schemas/tools/get_ntp_client.json +7 -0
  191. package/schemas/tools/get_ntp_server.json +7 -0
  192. package/schemas/tools/get_ovpn_client.json +14 -0
  193. package/schemas/tools/get_ovpn_server.json +7 -0
  194. package/schemas/tools/get_poe_monitor.json +15 -0
  195. package/schemas/tools/get_poe_settings.json +15 -0
  196. package/schemas/tools/get_port.json +15 -0
  197. package/schemas/tools/get_ppp_active.json +12 -0
  198. package/schemas/tools/get_ppp_profile.json +14 -0
  199. package/schemas/tools/get_ppp_secret.json +14 -0
  200. package/schemas/tools/get_pptp_client.json +14 -0
  201. package/schemas/tools/get_pptp_server.json +7 -0
  202. package/schemas/tools/get_queue_tree.json +14 -0
  203. package/schemas/tools/get_queue_type.json +14 -0
  204. package/schemas/tools/get_radius_incoming.json +7 -0
  205. package/schemas/tools/get_radius_server.json +15 -0
  206. package/schemas/tools/get_regulatory.json +7 -0
  207. package/schemas/tools/get_route.json +15 -0
  208. package/schemas/tools/get_route_cache.json +7 -0
  209. package/schemas/tools/get_route_statistics.json +7 -0
  210. package/schemas/tools/get_routerboard.json +7 -0
  211. package/schemas/tools/get_routing_id.json +15 -0
  212. package/schemas/tools/get_routing_nexthop_stats.json +7 -0
  213. package/schemas/tools/get_routing_rule.json +15 -0
  214. package/schemas/tools/get_routing_settings.json +7 -0
  215. package/schemas/tools/get_routing_table.json +23 -0
  216. package/schemas/tools/get_routing_table_def.json +15 -0
  217. package/schemas/tools/get_scheduler.json +14 -0
  218. package/schemas/tools/get_security_logs.json +16 -0
  219. package/schemas/tools/get_simple_queue.json +14 -0
  220. package/schemas/tools/get_sstp_client.json +14 -0
  221. package/schemas/tools/get_sstp_server.json +7 -0
  222. package/schemas/tools/get_system_clock.json +7 -0
  223. package/schemas/tools/get_system_events.json +19 -0
  224. package/schemas/tools/get_system_health.json +7 -0
  225. package/schemas/tools/get_system_history.json +7 -0
  226. package/schemas/tools/get_system_identity.json +7 -0
  227. package/schemas/tools/get_system_resources.json +7 -0
  228. package/schemas/tools/get_user.json +14 -0
  229. package/schemas/tools/get_user_group.json +14 -0
  230. package/schemas/tools/get_user_manager_settings.json +7 -0
  231. package/schemas/tools/get_user_manager_user.json +14 -0
  232. package/schemas/tools/get_vlan_interface.json +14 -0
  233. package/schemas/tools/get_vxlan_tunnel.json +14 -0
  234. package/schemas/tools/get_watchdog.json +7 -0
  235. package/schemas/tools/get_wireguard_interface.json +14 -0
  236. package/schemas/tools/get_wireguard_peer.json +15 -0
  237. package/schemas/tools/get_wireless_interface.json +14 -0
  238. package/schemas/tools/get_wireless_registration_table.json +11 -0
  239. package/schemas/tools/get_wireless_security_profile.json +14 -0
  240. package/schemas/tools/import_certificate.json +23 -0
  241. package/schemas/tools/import_configuration.json +24 -0
  242. package/schemas/tools/list_address_lists.json +24 -0
  243. package/schemas/tools/list_backups.json +18 -0
  244. package/schemas/tools/list_bfd_configurations.json +7 -0
  245. package/schemas/tools/list_bfd_sessions.json +16 -0
  246. package/schemas/tools/list_bgp_advertisements.json +12 -0
  247. package/schemas/tools/list_bgp_connections.json +12 -0
  248. package/schemas/tools/list_bgp_sessions.json +16 -0
  249. package/schemas/tools/list_bgp_templates.json +7 -0
  250. package/schemas/tools/list_bridge_hosts.json +12 -0
  251. package/schemas/tools/list_bridge_ports.json +16 -0
  252. package/schemas/tools/list_bridge_vlans.json +12 -0
  253. package/schemas/tools/list_bridges.json +12 -0
  254. package/schemas/tools/list_certificates.json +12 -0
  255. package/schemas/tools/list_dhcp_servers.json +26 -0
  256. package/schemas/tools/list_disks.json +7 -0
  257. package/schemas/tools/list_dns_static.json +29 -0
  258. package/schemas/tools/list_eoip_tunnels.json +12 -0
  259. package/schemas/tools/list_filter_rules.json +43 -0
  260. package/schemas/tools/list_gmp_group_memberships.json +16 -0
  261. package/schemas/tools/list_gmp_interfaces.json +7 -0
  262. package/schemas/tools/list_gre_tunnels.json +12 -0
  263. package/schemas/tools/list_igmp_proxy_interfaces.json +7 -0
  264. package/schemas/tools/list_igmp_proxy_mfc.json +7 -0
  265. package/schemas/tools/list_interfaces.json +42 -0
  266. package/schemas/tools/list_ip_addresses.json +29 -0
  267. package/schemas/tools/list_ip_pool_used.json +20 -0
  268. package/schemas/tools/list_ip_pools.json +21 -0
  269. package/schemas/tools/list_ip_services.json +7 -0
  270. package/schemas/tools/list_ipip_tunnels.json +12 -0
  271. package/schemas/tools/list_ipsec_identities.json +12 -0
  272. package/schemas/tools/list_ipsec_peers.json +12 -0
  273. package/schemas/tools/list_ipsec_policies.json +7 -0
  274. package/schemas/tools/list_ipsec_profiles.json +12 -0
  275. package/schemas/tools/list_ipsec_proposals.json +12 -0
  276. package/schemas/tools/list_l2tp_clients.json +12 -0
  277. package/schemas/tools/list_leds.json +7 -0
  278. package/schemas/tools/list_logging_actions.json +12 -0
  279. package/schemas/tools/list_logging_rules.json +16 -0
  280. package/schemas/tools/list_mikrotik_devices.json +7 -0
  281. package/schemas/tools/list_nat_rules.json +38 -0
  282. package/schemas/tools/list_netwatch.json +12 -0
  283. package/schemas/tools/list_ospf_area_ranges.json +7 -0
  284. package/schemas/tools/list_ospf_areas.json +7 -0
  285. package/schemas/tools/list_ospf_instances.json +7 -0
  286. package/schemas/tools/list_ospf_interface_templates.json +7 -0
  287. package/schemas/tools/list_ospf_lsa.json +12 -0
  288. package/schemas/tools/list_ospf_neighbors.json +7 -0
  289. package/schemas/tools/list_ovpn_clients.json +12 -0
  290. package/schemas/tools/list_pimsm_instances.json +7 -0
  291. package/schemas/tools/list_pimsm_interface_templates.json +7 -0
  292. package/schemas/tools/list_pimsm_neighbors.json +7 -0
  293. package/schemas/tools/list_pimsm_rps.json +7 -0
  294. package/schemas/tools/list_poe.json +12 -0
  295. package/schemas/tools/list_ports.json +12 -0
  296. package/schemas/tools/list_ppp_profiles.json +12 -0
  297. package/schemas/tools/list_ppp_secrets.json +24 -0
  298. package/schemas/tools/list_pptp_clients.json +12 -0
  299. package/schemas/tools/list_queue_trees.json +26 -0
  300. package/schemas/tools/list_queue_types.json +14 -0
  301. package/schemas/tools/list_radius_servers.json +16 -0
  302. package/schemas/tools/list_rip_instances.json +7 -0
  303. package/schemas/tools/list_rip_interface_templates.json +7 -0
  304. package/schemas/tools/list_rip_neighbors.json +7 -0
  305. package/schemas/tools/list_rip_static_neighbors.json +7 -0
  306. package/schemas/tools/list_routes.json +44 -0
  307. package/schemas/tools/list_routing_filter_num_lists.json +12 -0
  308. package/schemas/tools/list_routing_filter_rules.json +12 -0
  309. package/schemas/tools/list_routing_filter_select_rules.json +7 -0
  310. package/schemas/tools/list_routing_ids.json +12 -0
  311. package/schemas/tools/list_routing_nexthops.json +19 -0
  312. package/schemas/tools/list_routing_rules.json +19 -0
  313. package/schemas/tools/list_routing_tables.json +12 -0
  314. package/schemas/tools/list_rpki_sessions.json +12 -0
  315. package/schemas/tools/list_schedulers.json +12 -0
  316. package/schemas/tools/list_scripts.json +12 -0
  317. package/schemas/tools/list_simple_queues.json +26 -0
  318. package/schemas/tools/list_special_login.json +7 -0
  319. package/schemas/tools/list_sstp_clients.json +12 -0
  320. package/schemas/tools/list_system_console.json +7 -0
  321. package/schemas/tools/list_user_groups.json +14 -0
  322. package/schemas/tools/list_user_manager_limitations.json +12 -0
  323. package/schemas/tools/list_user_manager_profiles.json +12 -0
  324. package/schemas/tools/list_user_manager_routers.json +12 -0
  325. package/schemas/tools/list_user_manager_sessions.json +20 -0
  326. package/schemas/tools/list_user_manager_user_profiles.json +12 -0
  327. package/schemas/tools/list_user_manager_users.json +12 -0
  328. package/schemas/tools/list_user_ssh_keys.json +14 -0
  329. package/schemas/tools/list_users.json +26 -0
  330. package/schemas/tools/list_vlan_interfaces.json +28 -0
  331. package/schemas/tools/list_vxlan_tunnels.json +12 -0
  332. package/schemas/tools/list_wireguard_interfaces.json +23 -0
  333. package/schemas/tools/list_wireguard_peers.json +18 -0
  334. package/schemas/tools/list_wireless_access_list.json +7 -0
  335. package/schemas/tools/list_wireless_interfaces.json +23 -0
  336. package/schemas/tools/list_wireless_security_profiles.json +7 -0
  337. package/schemas/tools/monitor_logs.json +23 -0
  338. package/schemas/tools/move_filter_rule.json +21 -0
  339. package/schemas/tools/move_nat_rule.json +21 -0
  340. package/schemas/tools/ping.json +37 -0
  341. package/schemas/tools/reboot_system.json +15 -0
  342. package/schemas/tools/remove_address_list_entry.json +15 -0
  343. package/schemas/tools/remove_bfd_configuration.json +15 -0
  344. package/schemas/tools/remove_bgp_connection.json +15 -0
  345. package/schemas/tools/remove_bgp_template.json +15 -0
  346. package/schemas/tools/remove_bridge.json +14 -0
  347. package/schemas/tools/remove_bridge_port.json +15 -0
  348. package/schemas/tools/remove_certificate.json +14 -0
  349. package/schemas/tools/remove_dhcp_server.json +14 -0
  350. package/schemas/tools/remove_dns_static.json +14 -0
  351. package/schemas/tools/remove_eoip_tunnel.json +14 -0
  352. package/schemas/tools/remove_file.json +14 -0
  353. package/schemas/tools/remove_filter_rule.json +14 -0
  354. package/schemas/tools/remove_gre_tunnel.json +14 -0
  355. package/schemas/tools/remove_igmp_proxy_interface.json +15 -0
  356. package/schemas/tools/remove_ip_address.json +14 -0
  357. package/schemas/tools/remove_ip_pool.json +14 -0
  358. package/schemas/tools/remove_ipip_tunnel.json +14 -0
  359. package/schemas/tools/remove_ipsec_identity.json +15 -0
  360. package/schemas/tools/remove_ipsec_peer.json +14 -0
  361. package/schemas/tools/remove_ipsec_policy.json +15 -0
  362. package/schemas/tools/remove_ipsec_profile.json +14 -0
  363. package/schemas/tools/remove_ipsec_proposal.json +14 -0
  364. package/schemas/tools/remove_l2tp_client.json +14 -0
  365. package/schemas/tools/remove_logging_action.json +15 -0
  366. package/schemas/tools/remove_logging_rule.json +15 -0
  367. package/schemas/tools/remove_nat_rule.json +14 -0
  368. package/schemas/tools/remove_netwatch.json +14 -0
  369. package/schemas/tools/remove_ospf_area.json +15 -0
  370. package/schemas/tools/remove_ospf_area_range.json +15 -0
  371. package/schemas/tools/remove_ospf_instance.json +15 -0
  372. package/schemas/tools/remove_ospf_interface_template.json +15 -0
  373. package/schemas/tools/remove_ovpn_client.json +14 -0
  374. package/schemas/tools/remove_pimsm_instance.json +15 -0
  375. package/schemas/tools/remove_pimsm_interface_template.json +15 -0
  376. package/schemas/tools/remove_pimsm_rp.json +15 -0
  377. package/schemas/tools/remove_ppp_profile.json +14 -0
  378. package/schemas/tools/remove_ppp_secret.json +14 -0
  379. package/schemas/tools/remove_pptp_client.json +14 -0
  380. package/schemas/tools/remove_queue_tree.json +14 -0
  381. package/schemas/tools/remove_queue_type.json +14 -0
  382. package/schemas/tools/remove_radius_server.json +15 -0
  383. package/schemas/tools/remove_rip_instance.json +15 -0
  384. package/schemas/tools/remove_rip_interface_template.json +15 -0
  385. package/schemas/tools/remove_rip_static_neighbor.json +15 -0
  386. package/schemas/tools/remove_route.json +15 -0
  387. package/schemas/tools/remove_routing_filter_num_list.json +15 -0
  388. package/schemas/tools/remove_routing_filter_rule.json +15 -0
  389. package/schemas/tools/remove_routing_id.json +15 -0
  390. package/schemas/tools/remove_routing_rule.json +15 -0
  391. package/schemas/tools/remove_routing_table.json +15 -0
  392. package/schemas/tools/remove_rpki_session.json +15 -0
  393. package/schemas/tools/remove_scheduler.json +14 -0
  394. package/schemas/tools/remove_script.json +14 -0
  395. package/schemas/tools/remove_simple_queue.json +14 -0
  396. package/schemas/tools/remove_sstp_client.json +14 -0
  397. package/schemas/tools/remove_user.json +14 -0
  398. package/schemas/tools/remove_user_group.json +14 -0
  399. package/schemas/tools/remove_user_manager_limitation.json +14 -0
  400. package/schemas/tools/remove_user_manager_profile.json +14 -0
  401. package/schemas/tools/remove_user_manager_router.json +14 -0
  402. package/schemas/tools/remove_user_manager_user.json +14 -0
  403. package/schemas/tools/remove_user_ssh_key.json +14 -0
  404. package/schemas/tools/remove_vlan_interface.json +14 -0
  405. package/schemas/tools/remove_vxlan_tunnel.json +14 -0
  406. package/schemas/tools/remove_wireguard_interface.json +14 -0
  407. package/schemas/tools/remove_wireguard_peer.json +15 -0
  408. package/schemas/tools/remove_wireless_access_list_entry.json +14 -0
  409. package/schemas/tools/remove_wireless_interface.json +14 -0
  410. package/schemas/tools/remove_wireless_security_profile.json +14 -0
  411. package/schemas/tools/reset_configuration.json +31 -0
  412. package/schemas/tools/reset_radius_counters.json +7 -0
  413. package/schemas/tools/resolve_dns.json +19 -0
  414. package/schemas/tools/restore_backup.json +17 -0
  415. package/schemas/tools/rollback_safe_mode.json +7 -0
  416. package/schemas/tools/run_script.json +14 -0
  417. package/schemas/tools/safe_mode_status.json +7 -0
  418. package/schemas/tools/scan_wireless_networks.json +21 -0
  419. package/schemas/tools/search_logs.json +27 -0
  420. package/schemas/tools/set_bfd_configuration_enabled.json +19 -0
  421. package/schemas/tools/set_bgp_connection_enabled.json +19 -0
  422. package/schemas/tools/set_dns_servers.json +54 -0
  423. package/schemas/tools/set_igmp_proxy_interface_enabled.json +19 -0
  424. package/schemas/tools/set_ip_service.json +33 -0
  425. package/schemas/tools/set_l2tp_server.json +41 -0
  426. package/schemas/tools/set_leds_settings.json +18 -0
  427. package/schemas/tools/set_note.json +16 -0
  428. package/schemas/tools/set_ntp_client.json +16 -0
  429. package/schemas/tools/set_ntp_server.json +25 -0
  430. package/schemas/tools/set_ovpn_server.json +57 -0
  431. package/schemas/tools/set_port.json +45 -0
  432. package/schemas/tools/set_pptp_server.json +29 -0
  433. package/schemas/tools/set_radius_incoming.json +18 -0
  434. package/schemas/tools/set_routing_filter_rule_enabled.json +19 -0
  435. package/schemas/tools/set_routing_id_enabled.json +20 -0
  436. package/schemas/tools/set_routing_rule_enabled.json +20 -0
  437. package/schemas/tools/set_routing_table_enabled.json +20 -0
  438. package/schemas/tools/set_rpki_session_enabled.json +19 -0
  439. package/schemas/tools/set_sstp_server.json +37 -0
  440. package/schemas/tools/set_system_clock.json +20 -0
  441. package/schemas/tools/set_system_identity.json +15 -0
  442. package/schemas/tools/set_user_manager_settings.json +20 -0
  443. package/schemas/tools/set_user_ssh_keys.json +18 -0
  444. package/schemas/tools/set_watchdog.json +32 -0
  445. package/schemas/tools/set_wireless_security_profile.json +18 -0
  446. package/schemas/tools/shutdown_system.json +15 -0
  447. package/schemas/tools/sign_certificate.json +23 -0
  448. package/schemas/tools/test_dns_query.json +22 -0
  449. package/schemas/tools/traceroute.json +27 -0
  450. package/schemas/tools/update_bfd_configuration.json +38 -0
  451. package/schemas/tools/update_bgp_connection.json +64 -0
  452. package/schemas/tools/update_bridge.json +41 -0
  453. package/schemas/tools/update_dns_static.json +64 -0
  454. package/schemas/tools/update_filter_rule.json +71 -0
  455. package/schemas/tools/update_igmp_proxy_interface.json +32 -0
  456. package/schemas/tools/update_igmp_proxy_settings.json +19 -0
  457. package/schemas/tools/update_ip_pool.json +27 -0
  458. package/schemas/tools/update_ipsec_peer.json +44 -0
  459. package/schemas/tools/update_ipsec_profile.json +41 -0
  460. package/schemas/tools/update_ipsec_proposal.json +30 -0
  461. package/schemas/tools/update_nat_rule.json +59 -0
  462. package/schemas/tools/update_ospf_instance.json +36 -0
  463. package/schemas/tools/update_ppp_profile.json +61 -0
  464. package/schemas/tools/update_ppp_secret.json +50 -0
  465. package/schemas/tools/update_queue_tree.json +61 -0
  466. package/schemas/tools/update_queue_type.json +59 -0
  467. package/schemas/tools/update_radius_server.json +55 -0
  468. package/schemas/tools/update_rip_instance.json +36 -0
  469. package/schemas/tools/update_route.json +57 -0
  470. package/schemas/tools/update_routing_filter_rule.json +27 -0
  471. package/schemas/tools/update_routing_id.json +29 -0
  472. package/schemas/tools/update_routing_rule.json +45 -0
  473. package/schemas/tools/update_routing_settings.json +27 -0
  474. package/schemas/tools/update_routing_table.json +25 -0
  475. package/schemas/tools/update_rpki_session.json +38 -0
  476. package/schemas/tools/update_simple_queue.json +66 -0
  477. package/schemas/tools/update_user.json +32 -0
  478. package/schemas/tools/update_user_group.json +29 -0
  479. package/schemas/tools/update_user_manager_user.json +38 -0
  480. package/schemas/tools/update_vlan_interface.json +52 -0
  481. package/schemas/tools/update_wireguard_interface.json +36 -0
  482. package/schemas/tools/update_wireguard_peer.json +38 -0
  483. package/schemas/tools/update_wireless_interface.json +26 -0
  484. package/schemas/tools/upload_file.json +18 -0
package/package.json ADDED
@@ -0,0 +1,107 @@
1
+ {
2
+ "name": "@usex/mikrotik-mcp",
3
+ "version": "1.0.0",
4
+ "description": "Bun-native MCP server for MikroTik RouterOS — 200+ tools over SSH for firewall, NAT, routing, DHCP, DNS, WireGuard, wireless, QoS and more.",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "module": "dist/index.js",
8
+ "types": "dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./dist/index.d.ts",
12
+ "import": "./dist/index.js"
13
+ }
14
+ },
15
+ "files": [
16
+ "dist",
17
+ "prompts",
18
+ "schemas"
19
+ ],
20
+ "bin": {
21
+ "mikrotik-mcp": "dist/cli.js"
22
+ },
23
+ "keywords": [
24
+ "ai",
25
+ "mcp",
26
+ "mikrotik",
27
+ "mikrotik mcp",
28
+ "claude",
29
+ "bun"
30
+ ],
31
+ "author": {
32
+ "name": "Ali Torki",
33
+ "url": "https://github.com/ali-master",
34
+ "email": "ali_4286@live.com"
35
+ },
36
+ "license": "MIT",
37
+ "repository": {
38
+ "type": "git",
39
+ "url": "https://github.com/ali-master/mikrotik-mcp.git"
40
+ },
41
+ "bugs": {
42
+ "url": "https://github.com/ali-master/mikrotik-mcp/issues"
43
+ },
44
+ "homepage": "https://github.com/ali-master/mikrotik-mcp#readme",
45
+ "logo": "https://raw.githubusercontent.com/ali-master/mikrotik-mcp/main/assets/logo.svg",
46
+ "engines": {
47
+ "bun": ">=1.3.0"
48
+ },
49
+ "scripts": {
50
+ "build": "bunup && chmod +x dist/cli.js",
51
+ "dev": "bunup --watch",
52
+ "prepack": "bunup && chmod +x dist/cli.js",
53
+ "auth-check": "bun run src/cli.ts auth-check",
54
+ "gen:schemas": "bun run scripts/gen-schemas.ts",
55
+ "gen:docs": "bun run scripts/gen-tool-docs.ts",
56
+ "gen": "bun run gen:schemas && bun run gen:docs",
57
+ "start": "bun run src/cli.ts serve",
58
+ "inspect": "bunx @modelcontextprotocol/inspector bun run src/cli.ts serve",
59
+ "inspect:built": "bun run build && bunx @modelcontextprotocol/inspector bun dist/cli.js serve",
60
+ "inspect:config": "bunx @modelcontextprotocol/inspector --config mcp-inspector.config.json --server mikrotik",
61
+ "inspect:cli": "bunx @modelcontextprotocol/inspector --cli bun run src/cli.ts serve --method tools/list",
62
+ "inspect:config:local": "bunx @modelcontextprotocol/inspector --config /var/open-source/mikrotik-mcp/mcp-inspector.config.local.json --server mikrotik",
63
+ "test": "bun test",
64
+ "release": "release-it",
65
+ "test:types": "tsc --noEmit",
66
+ "format": "prettier --write \"**/*.ts\"",
67
+ "lint": "eslint \"src/**/*.ts\"",
68
+ "lint:fix": "eslint \"src/**/*.ts\" --fix"
69
+ },
70
+ "devDependencies": {
71
+ "@antfu/eslint-config": "^9.0.0",
72
+ "@resvg/resvg-js": "^2.6.2",
73
+ "@types/bun": "latest",
74
+ "@types/node": "^25.9.3",
75
+ "@types/ssh2": "^1.15.5",
76
+ "@types/update-notifier": "^6.0.8",
77
+ "bunup": "^0.16.32",
78
+ "eslint": "^10.5.0",
79
+ "eslint-plugin-format": "^2.0.1",
80
+ "prettier": "^3.8.4",
81
+ "release-it": "^20.2.0"
82
+ },
83
+ "peerDependencies": {
84
+ "typescript": "^5.7.3"
85
+ },
86
+ "dependencies": {
87
+ "@modelcontextprotocol/sdk": "^1.29.0",
88
+ "ssh2": "^1.17.0",
89
+ "zod": "^4.4.3"
90
+ },
91
+ "packageManager": "bun@1.3.14",
92
+ "changelog": {
93
+ "labels": {
94
+ "feature": "Features",
95
+ "bug": "Bug fixes",
96
+ "enhancement": "Enhancements",
97
+ "docs": "Docs",
98
+ "dependencies": "Dependencies",
99
+ "type: code style": "Code style tweaks",
100
+ "status: blocked": "Breaking changes",
101
+ "breaking change": "Breaking changes"
102
+ }
103
+ },
104
+ "publishConfig": {
105
+ "access": "public"
106
+ }
107
+ }
@@ -0,0 +1,31 @@
1
+ ---
2
+ name: backup-and-document
3
+ title: Back up and document the configuration
4
+ description: Create a safe restore point and produce a human-readable inventory of the router's configuration.
5
+ arguments: []
6
+ ---
7
+ Create a restore point for this MikroTik device and then write up a clear,
8
+ human-readable summary of how it's configured. This is read-mostly: the only
9
+ change is creating a backup/export.
10
+
11
+ 1. **Restore point** — `create_backup` (binary, for full restore) and
12
+ `create_export` (text `.rsc`, for review/diff). List them with `list_backups`.
13
+ 2. **Inventory** — gather the configuration with read tools and organize it:
14
+ - System: `get_system_identity`, `get_system_resources`, `get_routerboard`,
15
+ `get_installed_packages`.
16
+ - L2/L3: `list_interfaces`, `list_vlan_interfaces`, `list_bridges`,
17
+ `list_ip_addresses`, `list_ip_pools`.
18
+ - Services: `list_dhcp_servers`, `get_dns_settings`, `list_dns_static`,
19
+ `list_ip_services`.
20
+ - Routing: `list_routes`, `get_routing_table`.
21
+ - Security: `list_filter_rules`, `list_nat_rules`, `list_address_lists`,
22
+ `list_users`, `list_certificates`.
23
+ - VPN/QoS: `list_wireguard_interfaces` + `list_wireguard_peers`,
24
+ `list_simple_queues`, `list_queue_trees`.
25
+ - Automation: `list_schedulers`, `list_scripts`.
26
+
27
+ Produce a structured Markdown report: a one-paragraph overview, a table of
28
+ interfaces and addressing, the firewall posture, and a "things worth reviewing"
29
+ section (defaults left in place, disabled-but-present rules, expiring certs).
30
+ Reference the backup/export filenames you created so the user knows their restore
31
+ point.
@@ -0,0 +1,45 @@
1
+ ---
2
+ name: choose-vpn-solution
3
+ title: Choose the right MikroTik VPN
4
+ description: Recommend the best MikroTik VPN/tunnel technology for a given requirement, then outline the build.
5
+ arguments:
6
+ - name: use_case
7
+ description: What you need — e.g. "connect two offices", "remote access for laptops & phones", "site-to-site over the internet with another vendor's firewall", "L2 bridge between sites".
8
+ required: true
9
+ - name: clients
10
+ description: What connects — e.g. "iOS/Android/Windows built-in clients", "other MikroTik routers", "a Cisco/Fortinet device", "our laptops only". Optional.
11
+ required: false
12
+ ---
13
+ Act as a MikroTik VPN architect. Recommend the single best tunneling technology
14
+ for the requirement below, justify it against the alternatives, then sketch the
15
+ build using this server's tools. Be decisive.
16
+
17
+ Use case: {{use_case}}
18
+ Clients / peers: {{clients}}
19
+
20
+ Decision guidance — weigh these MikroTik options:
21
+
22
+ - **WireGuard** — fastest, simplest, modern. Best for MikroTik↔MikroTik and
23
+ laptops/phones with the WireGuard app. No built-in OS client on older systems.
24
+ Tools: `create_wireguard_interface`, `add_wireguard_peer`, `generate_wireguard_client_config`.
25
+ - **IPsec (IKEv2)** — the interoperability choice for site-to-site with
26
+ *other vendors* (Cisco/Fortinet/pfSense) and for native iOS/Windows IKEv2
27
+ road-warrior. Most config surface. Tools: `create_ipsec_*` (profile/peer/
28
+ identity/proposal/policy), `get_ipsec_active_peers`.
29
+ - **L2TP/IPsec** — best when clients must use the **built-in** VPN client on
30
+ Windows/macOS/iOS/Android with no app install. Tools: `set_l2tp_server`
31
+ (`use_ipsec=required`), `create_ppp_secret`, `create_ppp_profile`.
32
+ - **SSTP** — when you must traverse restrictive firewalls/proxies (TLS over 443).
33
+ Needs a certificate. Tools: `set_sstp_server`, `create_ppp_secret`.
34
+ - **OpenVPN** — cross-platform with the OpenVPN client; RouterOS 7 adds UDP.
35
+ Tools: `set_ovpn_server`, `create_ovpn_client`.
36
+ - **PPTP** — legacy/weak; only if a legacy device demands it. Recommend against.
37
+ - **GRE / IPIP / EoIP / VXLAN** — *unencrypted* transport tunnels for routing or
38
+ L2 bridging between sites (often run **over** an IPsec policy for encryption).
39
+ EoIP/VXLAN bridge layer-2; GRE/IPIP carry layer-3. Tools: `create_gre_tunnel`,
40
+ `create_eoip_tunnel`, `create_vxlan_tunnel`.
41
+
42
+ Deliver: (1) the recommendation in one sentence, (2) a short "why not the others"
43
+ table, (3) an ordered build plan referencing the exact tools and the firewall
44
+ rules required (use Safe Mode for firewall edits), and (4) what the client side
45
+ needs. Confirm the plan before making changes.
@@ -0,0 +1,38 @@
1
+ ---
2
+ name: diagnose-connectivity
3
+ title: Diagnose a connectivity problem
4
+ description: Systematically troubleshoot why a host, subnet, or the internet is unreachable from a MikroTik router.
5
+ arguments:
6
+ - name: target
7
+ description: What's unreachable — an IP, hostname, or subnet (e.g. 8.8.8.8, example.com, 192.168.50.0/24).
8
+ required: true
9
+ - name: source_interface
10
+ description: The interface/segment the affected clients are on (e.g. bridge, vlan50). Optional.
11
+ required: false
12
+ ---
13
+ Troubleshoot a connectivity issue on a MikroTik RouterOS device, reasoning from
14
+ the bottom of the stack up. Use read-only tools only — do not change config until
15
+ you've localized the fault and the user approves a fix.
16
+
17
+ Target that is unreachable: {{target}}
18
+ Affected segment/interface: {{source_interface}}
19
+
20
+ Diagnose in layers, stating what each step rules in or out:
21
+
22
+ 1. **Link** — `list_interfaces` (is the relevant interface `running`?), and for
23
+ PoE/SFP links check status. `get_interface` for details.
24
+ 2. **Addressing** — `list_ip_addresses`; confirm the segment has a valid gateway
25
+ IP and the WAN has an address (DHCP/PPPoE/static).
26
+ 3. **Routing** — `get_routing_table`, then `check_route_path` toward {{target}} to
27
+ see which route/gateway would be used and whether it's active.
28
+ 4. **Name resolution** — if {{target}} is a hostname, `resolve_dns` and
29
+ `get_dns_settings`.
30
+ 5. **Reachability** — `ping` {{target}} from the router (and with `src_address`
31
+ set to the segment's gateway if relevant); `traceroute` to find where it stops.
32
+ 6. **Firewall / NAT** — `list_filter_rules` and `list_nat_rules`; look for a drop
33
+ in `forward` or a missing `srcnat`/masquerade for the segment. Check
34
+ `list_address_lists` if rules reference one.
35
+ 7. **Logs** — `search_logs` for the interface/subnet and `get_system_events`.
36
+
37
+ Conclude with the single most likely root cause, the evidence for it, and the
38
+ specific tool call(s) that would fix it (for the user to approve).
@@ -0,0 +1,38 @@
1
+ ---
2
+ name: harden-router
3
+ title: Harden a RouterOS device
4
+ description: Audit and tighten a MikroTik router's security posture — management services, firewall input chain, users, and DNS.
5
+ arguments:
6
+ - name: wan_interface
7
+ description: The WAN-facing interface name (e.g. ether1, pppoe-out1). If unknown, discover it first.
8
+ required: false
9
+ ---
10
+ You are securing a MikroTik RouterOS device exposed through this MCP server. Work
11
+ **safely and incrementally**: inspect first, propose a plan, and prefer Safe Mode
12
+ for risky firewall changes so a mistake auto-reverts instead of locking us out.
13
+
14
+ WAN interface: {{wan_interface}}
15
+
16
+ Carry out a hardening pass in this order, explaining each finding:
17
+
18
+ 1. **Baseline** — `get_system_identity`, `get_system_resources`, `get_installed_packages`,
19
+ and `list_interfaces` to understand the device and confirm the WAN interface.
20
+ 2. **Management surface** — `list_ip_services`. Flag any enabled plaintext service
21
+ (telnet, ftp, www, api). Recommend `disable_ip_service` for telnet/ftp and
22
+ restricting the rest with `set_ip_service` (set `address=` to trusted subnets,
23
+ move ssh off port 22 if appropriate).
24
+ 3. **Users** — `list_users` and `list_user_groups`. Flag the default `admin`
25
+ account, weak/absent passwords, and over-broad group policies.
26
+ 4. **Firewall input chain** — `list_filter_rules` with `chain=input`. Verify there
27
+ is an established/related accept, an ICMP accept, a trusted-management accept,
28
+ and a final drop. If the input chain is empty or permissive, propose concrete
29
+ `create_filter_rule` calls. **Enable Safe Mode** (`enable_safe_mode`) before
30
+ applying, verify connectivity, then `commit_safe_mode`.
31
+ 5. **Discovery/Neighbour exposure** — check for MAC-server / neighbor-discovery /
32
+ bandwidth-test left open on the WAN.
33
+ 6. **DNS** — `get_dns_settings`; if `allow-remote-requests` is yes, ensure UDP/TCP
34
+ 53 from WAN is dropped.
35
+
36
+ Finish with a short prioritized checklist (Critical / Recommended / Optional) and
37
+ the exact tool calls you would run for each. Do not make changes the user hasn't
38
+ approved.
@@ -0,0 +1,44 @@
1
+ ---
2
+ name: setup-guest-wifi
3
+ title: Set up an isolated guest network
4
+ description: Create a segmented guest VLAN/network with its own DHCP, internet access, and isolation from the LAN.
5
+ arguments:
6
+ - name: subnet
7
+ description: The guest subnet in CIDR, e.g. 192.168.80.0/24.
8
+ required: true
9
+ - name: vlan_id
10
+ description: VLAN ID for the guest segment, e.g. 80. Optional if using a flat interface.
11
+ required: false
12
+ - name: wan_interface
13
+ description: The interface that reaches the internet (for the masquerade rule).
14
+ required: true
15
+ ---
16
+ Build an **isolated guest network** on this MikroTik device. Guests must reach the
17
+ internet but must NOT reach the LAN or the router's management. Plan the whole
18
+ change first, show it to the user, then apply it under Safe Mode.
19
+
20
+ Guest subnet: {{subnet}}
21
+ Guest VLAN ID: {{vlan_id}}
22
+ WAN interface: {{wan_interface}}
23
+
24
+ Proposed build (adapt to what you discover with `list_interfaces`,
25
+ `list_ip_addresses`, `list_filter_rules`):
26
+
27
+ 1. **Segment** — if a VLAN is requested, `create_vlan_interface` (vlan_id
28
+ {{vlan_id}}) on the LAN bridge/trunk; otherwise pick a dedicated interface.
29
+ 2. **Gateway IP** — `add_ip_address` using the first usable address of {{subnet}}.
30
+ 3. **DHCP** — `create_dhcp_pool`, `create_dhcp_network` (gateway + DNS), and
31
+ `create_dhcp_server` bound to the guest interface.
32
+ 4. **NAT** — ensure a `create_nat_rule` masquerade exists for {{subnet}} out
33
+ {{wan_interface}}.
34
+ 5. **Isolation (the important part)** — in the `forward` chain via
35
+ `create_filter_rule`:
36
+ - allow {{subnet}} → WAN (established/related + new),
37
+ - **drop {{subnet}} → LAN subnets (RFC1918)**,
38
+ and in the `input` chain drop {{subnet}} → router except DHCP/DNS. Consider an
39
+ `add_address_list_entry` list named `guest` to keep the rules tidy.
40
+ 6. **Verify** — re-list the rules and confirm ordering; `enable_safe_mode` before
41
+ applying, test, then `commit_safe_mode`.
42
+
43
+ Present the plan as an ordered list of exact tool calls with arguments before
44
+ executing anything.
@@ -0,0 +1,50 @@
1
+ ---
2
+ name: setup-ipsec-site-to-site
3
+ title: Build an IPsec IKEv2 site-to-site tunnel
4
+ description: Stand up an interoperable IPsec IKEv2 tunnel between this router and a remote site/peer.
5
+ arguments:
6
+ - name: local_subnet
7
+ description: The local network behind this router, in CIDR (e.g. 192.168.10.0/24).
8
+ required: true
9
+ - name: remote_subnet
10
+ description: The remote network behind the peer, in CIDR (e.g. 192.168.20.0/24).
11
+ required: true
12
+ - name: peer_address
13
+ description: The public IP / hostname of the remote peer.
14
+ required: true
15
+ ---
16
+ Build a secure IPsec **IKEv2** site-to-site tunnel. IKEv2 is the interoperability
17
+ choice — it works against other MikroTik routers and third-party firewalls
18
+ (Cisco, Fortinet, pfSense). Plan first, present the parameters for both ends to
19
+ match, then apply under Safe Mode.
20
+
21
+ Local subnet: {{local_subnet}}
22
+ Remote subnet: {{remote_subnet}}
23
+ Peer address: {{peer_address}}
24
+
25
+ Build order (use the `create_ipsec_*` tools; keep phase-1/phase-2 parameters
26
+ identical on both ends):
27
+
28
+ 1. **Profile (phase 1)** — `create_ipsec_profile` (e.g. dh-group modp2048,
29
+ enc-algorithm aes-256, hash sha256). Note the values so the remote side matches.
30
+ 2. **Proposal (phase 2)** — `create_ipsec_proposal` (e.g. auth sha256,
31
+ enc aes-256-cbc, pfs-group modp2048).
32
+ 3. **Peer** — `create_ipsec_peer` with `address={{peer_address}}`,
33
+ `exchange_mode=ike2`, and the profile from step 1.
34
+ 4. **Identity** — `create_ipsec_identity` for that peer with
35
+ `auth_method=pre-shared-key` and a strong secret (or certificates for
36
+ production). Set `generate_policy=port-strict` only if you are not defining an
37
+ explicit policy.
38
+ 5. **Policy** — `create_ipsec_policy` with `src_address={{local_subnet}}`,
39
+ `dst_address={{remote_subnet}}`, `tunnel=true`, `action=encrypt`, the peer, and
40
+ the proposal.
41
+ 6. **Firewall / NAT** — ensure UDP 500 + 4500 and IP protocol 50 (ESP) are
42
+ accepted from {{peer_address}} on the input chain, and add a NAT *bypass*
43
+ (accept/no-nat) rule so {{local_subnet}}→{{remote_subnet}} traffic is NOT
44
+ masqueraded. Apply firewall edits under `enable_safe_mode`.
45
+ 7. **Verify** — `get_ipsec_active_peers` and `get_ipsec_installed_sa` to confirm
46
+ the tunnel established; `ping` a remote host with src-address in {{local_subnet}}.
47
+
48
+ Present the matching parameter set for the remote engineer and the exact tool
49
+ calls before applying. Never echo the pre-shared key back in plaintext beyond
50
+ what is necessary to configure the peer.
@@ -0,0 +1,41 @@
1
+ ---
2
+ name: setup-l2tp-ipsec-roadwarrior
3
+ title: Set up L2TP/IPsec remote access (road warrior)
4
+ description: Configure an L2TP-over-IPsec server so laptops and phones can connect with their built-in VPN client.
5
+ arguments:
6
+ - name: vpn_pool
7
+ description: The address range handed to VPN clients, e.g. 192.168.89.10-192.168.89.254.
8
+ required: true
9
+ - name: local_gateway
10
+ description: The router's address on the VPN/LAN side that clients use as gateway/DNS, e.g. 192.168.89.1.
11
+ required: true
12
+ ---
13
+ Configure **L2TP/IPsec** remote access — the right choice when users must connect
14
+ with the **built-in** VPN client on Windows, macOS, iOS, and Android (no app to
15
+ install). Plan first, then apply (firewall under Safe Mode).
16
+
17
+ Client address pool: {{vpn_pool}}
18
+ Gateway / DNS for clients: {{local_gateway}}
19
+
20
+ Build order:
21
+
22
+ 1. **IP pool** — `create_ip_pool` for {{vpn_pool}} (e.g. name `l2tp-pool`).
23
+ 2. **PPP profile** — `create_ppp_profile` (name `l2tp-profile`,
24
+ `local_address={{local_gateway}}`, `remote_address=l2tp-pool`,
25
+ `dns_server={{local_gateway}}`, `change_tcp_mss=yes`).
26
+ 3. **User accounts** — `create_ppp_secret` per user with
27
+ `service=l2tp` and `profile=l2tp-profile`. Use strong passwords.
28
+ 4. **Enable the server** — `set_l2tp_server` with `enabled=true`,
29
+ `default_profile=l2tp-profile`, `use_ipsec=required`, and a strong
30
+ `ipsec_secret` (this is the IPsec pre-shared key clients enter).
31
+ `authentication=mschap2`.
32
+ 5. **Firewall** — accept UDP 500, UDP 4500, UDP 1701, and IP protocol 50 (ESP)
33
+ on the input chain from the internet; allow the {{vpn_pool}} range to reach the
34
+ LAN/internet in the forward chain as required. Apply under `enable_safe_mode`,
35
+ verify you can still reach the router, then `commit_safe_mode`.
36
+ 6. **Verify** — `get_l2tp_server`, then `get_ppp_active` after a test client
37
+ connects.
38
+
39
+ Finish with a short **client setup card**: server address, the IPsec pre-shared
40
+ key (treat as a secret), the username/password, and the per-OS steps (type =
41
+ "L2TP over IPsec"). Confirm before applying changes.
@@ -0,0 +1,56 @@
1
+ ---
2
+ name: setup-tunnel-between-sites
3
+ title: Build a tunnel between two MikroTik devices
4
+ description: Configure BOTH routers of a site-to-site tunnel from one conversation, then verify it end to end.
5
+ arguments:
6
+ - name: device_a
7
+ description: Name of the first configured device (see list_mikrotik_devices), e.g. site-a.
8
+ required: true
9
+ - name: device_b
10
+ description: Name of the second configured device, e.g. site-b.
11
+ required: true
12
+ - name: technology
13
+ description: Tunnel type to use — wireguard, ipsec, gre, eoip, or "recommend" to let you choose.
14
+ required: false
15
+ ---
16
+ You are configuring a **site-to-site tunnel between two MikroTik routers** that
17
+ this server can both reach. You will drive BOTH devices in one flow by passing
18
+ the `device` argument on each tool call.
19
+
20
+ Device A: {{device_a}}
21
+ Device B: {{device_b}}
22
+ Requested technology: {{technology}}
23
+
24
+ Work in this order, confirming the plan before any change:
25
+
26
+ 1. **Inventory both ends.** Call `list_mikrotik_devices` first. Then, for each of
27
+ {{device_a}} and {{device_b}}, gather facts with `device=<name>`:
28
+ `get_system_identity`, `list_interfaces`, `list_ip_addresses`,
29
+ `get_routing_table`. Note each side's WAN/public address and LAN subnet.
30
+ 2. **Choose the technology.** If `{{technology}}` is "recommend" or empty, pick
31
+ based on the facts (WireGuard for MikroTik↔MikroTik simplicity; IPsec IKEv2
32
+ for policy-based/interop; GRE/EoIP when you need routed/L2 transport — wrap it
33
+ in IPsec if it must be encrypted). State the choice and why.
34
+ 3. **Configure side A** (`device={{device_a}}`) then **side B**
35
+ (`device={{device_b}}`), keeping the two ends' parameters consistent:
36
+ - WireGuard: `create_wireguard_interface` on each, exchange the **public keys**
37
+ (read with `get_wireguard_interface`), `add_wireguard_peer` on each pointing
38
+ at the other's endpoint + public key + allowed subnet, and `add_ip_address`
39
+ on each tunnel interface.
40
+ - IPsec: matching `create_ipsec_profile` + `create_ipsec_proposal` on both,
41
+ then `create_ipsec_peer` (`exchange_mode=ike2`) → `create_ipsec_identity`
42
+ (same PSK) → `create_ipsec_policy` (A: src=A-LAN dst=B-LAN; B: mirrored).
43
+ - GRE/EoIP: `create_gre_tunnel`/`create_eoip_tunnel` on each with
44
+ remote-address = the other side's public IP, then address + a route.
45
+ 4. **Firewall, safely.** On each side, open the tunnel's port/protocol on the
46
+ `input` chain and allow the far LAN in `forward`. Use `enable_safe_mode`
47
+ (`device=<name>`) per device before firewall edits, verify, then
48
+ `commit_safe_mode` — Safe Mode is tracked per device, so each router commits
49
+ independently.
50
+ 5. **Verify end to end.** From {{device_a}} run `ping` (`device={{device_a}}`) to
51
+ the far tunnel address and a host in B's LAN (set `src_address` to A's LAN IP);
52
+ repeat from {{device_b}}. For IPsec, check `get_ipsec_active_peers` on both.
53
+ Use `traceroute` if a path is wrong.
54
+
55
+ Report the tunnel parameters used on each side, the verification results, and any
56
+ follow-ups (e.g. routes still needed). Never apply changes the user hasn't approved.
@@ -0,0 +1,41 @@
1
+ ---
2
+ name: setup-wireguard-vpn
3
+ title: Set up a WireGuard VPN + first peer
4
+ description: Stand up a WireGuard server interface on the router and generate a ready-to-use client config for one peer.
5
+ arguments:
6
+ - name: vpn_subnet
7
+ description: The VPN tunnel subnet in CIDR, e.g. 10.10.0.0/24.
8
+ required: true
9
+ - name: endpoint
10
+ description: The public hostname/IP clients will connect to (your WAN address or DDNS name).
11
+ required: true
12
+ - name: listen_port
13
+ description: UDP port for WireGuard (default 13231).
14
+ required: false
15
+ ---
16
+ Provision a WireGuard VPN on this MikroTik device and produce a working client
17
+ config. Confirm the plan with the user before applying changes.
18
+
19
+ VPN subnet: {{vpn_subnet}}
20
+ Public endpoint: {{endpoint}}
21
+ Listen port: {{listen_port}}
22
+
23
+ Steps:
24
+
25
+ 1. **Server interface** — `create_wireguard_interface` (e.g. name `wg-vpn`,
26
+ listen port {{listen_port}} or 13231). Then `get_wireguard_interface` to read
27
+ back its **public key**.
28
+ 2. **Tunnel address** — `add_ip_address` on `wg-vpn` using the router's address in
29
+ {{vpn_subnet}} (e.g. the .1).
30
+ 3. **Firewall** — `create_filter_rule` in `input` to accept UDP on the listen port
31
+ from WAN, and in `forward` to allow the VPN subnet to the LAN/internet as the
32
+ user wants. Use Safe Mode for the firewall edits.
33
+ 4. **First peer** — `add_wireguard_peer` on `wg-vpn` with the client's allowed
34
+ address (a /32 in {{vpn_subnet}}). If the client keypair is generated on the
35
+ client, collect its public key; otherwise note that the private key must be
36
+ created client-side.
37
+ 5. **Client config** — call `generate_wireguard_client_config` with the server
38
+ public key, {{endpoint}}, the listen port, and the assigned client address, and
39
+ present the resulting `[Interface]/[Peer]` config for the user to import.
40
+
41
+ Report the server public key, the peer you added, and the full client config.
@@ -0,0 +1,14 @@
1
+ # Schemas
2
+
3
+ Machine-readable JSON Schemas for `@usex/mikrotik-mcp`, **generated** from the
4
+ TypeScript source by `scripts/gen-schemas.ts` (`bun run gen:schemas`). Do not
5
+ edit by hand — regenerate instead.
6
+
7
+ | File | Contents |
8
+ |------|----------|
9
+ | `config.schema.json` | The runtime configuration object (env vars / CLI flags). |
10
+ | `tool-catalog.json` | Every one of the 466 tools: `name`, `risk`, `title`, `description`, and input JSON Schema. |
11
+ | `tools/<name>.json` | The input JSON Schema for a single tool. |
12
+
13
+ `risk` is derived from the MCP tool annotations:
14
+ `read` · `write` · `write-idempotent` · `destructive` · `dangerous`.
@@ -0,0 +1,128 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "MikrotikConfig",
4
+ "type": "object",
5
+ "properties": {
6
+ "devices": {
7
+ "default": {
8
+ "default": {
9
+ "host": "127.0.0.1",
10
+ "username": "admin",
11
+ "password": "",
12
+ "port": 22,
13
+ "timeoutMs": 10000
14
+ }
15
+ },
16
+ "type": "object",
17
+ "propertyNames": {
18
+ "type": "string"
19
+ },
20
+ "additionalProperties": {
21
+ "type": "object",
22
+ "properties": {
23
+ "host": {
24
+ "default": "127.0.0.1",
25
+ "type": "string"
26
+ },
27
+ "username": {
28
+ "default": "admin",
29
+ "type": "string"
30
+ },
31
+ "password": {
32
+ "default": "",
33
+ "type": "string"
34
+ },
35
+ "port": {
36
+ "default": 22,
37
+ "type": "integer",
38
+ "exclusiveMinimum": 0,
39
+ "maximum": 9007199254740991
40
+ },
41
+ "keyFilename": {
42
+ "type": "string"
43
+ },
44
+ "privateKey": {
45
+ "type": "string"
46
+ },
47
+ "keyPassphrase": {
48
+ "type": "string"
49
+ },
50
+ "timeoutMs": {
51
+ "default": 10000,
52
+ "type": "integer",
53
+ "exclusiveMinimum": 0,
54
+ "maximum": 9007199254740991
55
+ },
56
+ "description": {
57
+ "type": "string"
58
+ }
59
+ },
60
+ "required": [
61
+ "host",
62
+ "username",
63
+ "password",
64
+ "port",
65
+ "timeoutMs"
66
+ ],
67
+ "additionalProperties": false
68
+ }
69
+ },
70
+ "defaultDevice": {
71
+ "default": "default",
72
+ "type": "string"
73
+ },
74
+ "mcp": {
75
+ "default": {
76
+ "transport": "stdio",
77
+ "host": "0.0.0.0",
78
+ "port": 8000,
79
+ "allowedHosts": "",
80
+ "allowedOrigins": ""
81
+ },
82
+ "type": "object",
83
+ "properties": {
84
+ "transport": {
85
+ "default": "stdio",
86
+ "type": "string",
87
+ "enum": [
88
+ "stdio",
89
+ "sse",
90
+ "streamable-http"
91
+ ]
92
+ },
93
+ "host": {
94
+ "default": "0.0.0.0",
95
+ "type": "string"
96
+ },
97
+ "port": {
98
+ "default": 8000,
99
+ "type": "integer",
100
+ "exclusiveMinimum": 0,
101
+ "maximum": 9007199254740991
102
+ },
103
+ "allowedHosts": {
104
+ "default": "",
105
+ "type": "string"
106
+ },
107
+ "allowedOrigins": {
108
+ "default": "",
109
+ "type": "string"
110
+ }
111
+ },
112
+ "required": [
113
+ "transport",
114
+ "host",
115
+ "port",
116
+ "allowedHosts",
117
+ "allowedOrigins"
118
+ ],
119
+ "additionalProperties": false
120
+ }
121
+ },
122
+ "required": [
123
+ "devices",
124
+ "defaultDevice",
125
+ "mcp"
126
+ ],
127
+ "additionalProperties": false
128
+ }