API wireless scan ap status ?

Hi to all,

I’m trying to make an api wireless scan call (command /interface/wireless/scan =.id=wlan1) but I notice that doesnt’ return the AP status (I’m mainly interested in P - Privacy flag) as it does in command shell and in winbox. Is there any way to know whether an access point is protected or not (even with another command)?

Thank you in advance

what version of ROS?

What’s new in 3.30:

*) api - ‘torch’ and ‘wireless scan’ commands now return same values
in ‘!re’ responses as in console (before they didn’t return
anything), ‘.proplist’ is also correctly handled;

Hi, and thanks for your answer,

I’m using the 4.1 version.

thanx again

*) api - ‘torch’ and ‘wireless scan’ commands now return same values
in ‘!re’ responses as in console

yeah, that’s not really a truth =) not the same… I think, you should send this as a request to support@mikrotik.com, and they will add that possibility in future version(s) :slight_smile:

Is there any shell command that can return AP status ? (except from scan)

I really don’t have problem since my program uses both ssh and API to communicate with the router. You may wonder why I don’t parse scan command?..? Unfortunely this is not possible due to terminal restrictions (scan refreshes terminal). So if there is a command that returns AP info (for a specific AP), I may be able to do my job until a future ROS releases fixes these issues.

Thank you all for your help

does it refresh even if you set ‘duration’ parameter?..

Yes unfortunely, so I cannot parse it (I’m using C#)