Datasheet
API command notes
178
All this boils down to this, where XX is encoded word legth, aaaa is word and 0x00 is terminating zero single line
sentence
XXaaaa0x00
multiple line sentence
XXaaaa
XXaaaa0x00
or
XXaaaa
XXaaaa
XXaaaa0x00
Note: Usually API implementations takes care of encoding word length part and user only have to worry to
make sure that correct method/function is used to send words over to router and make sure words make
meaningful sentence for execution
Scripting and API
It is possible to access RouterOS scripting global variables through the API if user have enough permissions to read
this menu.
/system/script/environment
Users are able to remove or alter value of the variable. Keep in mind, that variable type is automatically determined
by scripting engine. Be aware that variable type can change while you are working with it.
Also, no other scripting constructs are available in API (:if, :for etc.)
Note: Through API it is not possible to create new variables
Note: Find command have many constructs that are part of scripting, thus not available through API
API login
since RouterOS 4.7 it is possible to monitor all API connections to RouterOS under /user active
menu in console (or corresponding menu in winbox). Same way that can be done for telnet, ssh,
winbox and webfig logins.










