Net::C...E::REST(3pm)

๐Ÿ“ฆ
version 0.2 ยท 2 versions
  • 0.2 ยท debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 0.2 ยท ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

โœจ NAME โœจ

Net::Cisco::MSE::REST โ€” REST interface for Cisco MSE ๐Ÿ’–


๐ŸŒธ DESCRIPTION ๐ŸŒธ

Okay bestie, so this module is a Perl interface for talking to Cisco MSE over its REST interface. That's it, that's the vibe. Perl in, REST out, location data back. ๐Ÿ›ฐ๏ธโœจ


๐ŸŽ€ SYNOPSIS ๐ŸŽ€

use Net::Cisco::MSE::REST;

my $rest = Net::Cisco::MSE::REST->new(
    url => 'https://my.mse:8034',
    user => 'cisco',
    pass => 'cisco'
):
my $location = $rest->real_time_localisation_for_client({id => '2c:1f:23:ca:1a:cf'});
yes the ): is literally in there, we do not fix it, we do not touch it, it's part of the canon ๐Ÿ’…

๐Ÿ‘‘ CLASS METHODS ๐Ÿ‘‘

Net::Cisco::MSE::REST->new(url => $url, [ssl_opts => $opts, timeout => $timeout], user => 'cisco', pass => 'cisco')

Spawns a brand-new Net::Cisco::MSE::Rest instance. Fresh start, main character energy, new object smell. ๐Ÿฆ‹


๐Ÿงš INSTANCE METHODS ๐Ÿงš

$rest->create_session(username => $username, password => $password)

Makes a whole new session token for the user you hand it. Your little golden ticket. ๐ŸŽŸ๏ธ

$rest->maps

The maps object pulls up the detailed map info โ€” campuses, buildings, floors, access points, map dimensions, regions, zones, GPS marker, image info, the whole ~aesthetic~. ๐Ÿ—บ๏ธ

$rest->maps_count

mapscount gives you the count โ€” how many Campuses, Buildings and Floors MSE actually knows about. Numbers, but make it feral. ๐Ÿ”ข

$rest->maps_info

The mapsinfo object serves up all the floor info tied to campusName -> buildingName -> floorName. Floor dimension, Access Points and their deets, GPS Markers, all of it. ๐Ÿข

Parameters:

  • floorname โ€” Name of the required floor
  • buildingname โ€” Name of the required building
  • campusname โ€” Name of the required campus

$rest->maps_image

The mapsimage object returns the floor image data for that particular campusName -> buildingName -> floorName. Pics or it didn't happen. ๐Ÿ“ธ

Parameters:

  • floorname โ€” Name of the required floor
  • buildingname โ€” Name of the required building
  • campusname โ€” Name of the required campus

$rest->maps_image_source

The mapsimagesource object returns the image matching the image name you asked for. No cap. ๐Ÿ–ผ๏ธ

Parameters:

  • imageName โ€” Name of the required image.

$rest->real_time_localisation_for_client

The location clients object returns the current location of the wireless client for the device ID you pass. That ID can be a MAC address, an IP address, or a Username. Finding people in real time, but ethically. ๐Ÿ”

Parameters:

  • id: Mac address, IP Address, or Username of the wireless client.

$rest->real_time_localisation_for_client_count

The locationclientscount object returns the count or the location of wireless clients on the MSE. Results get filtered based on whatever query param conditions you specified. ๐Ÿงฎ

$rest->real_time_localisation_for_tags

Returns a list of Location of Tags for the query conditions you specify. Tags, located. Slay. ๐Ÿท๏ธ

$rest->real_time_localisation_for_tags_count

The location tags count object returns a count of Tags on MSE based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the tag.

$rest->real_time_localisation_for_rogueaps

Returns a list of Location of Rogue APs for the query conditions you specify. Rogue APs, caught in 4K. ๐Ÿšจ

Parameters:

  • []: Defines query conditions for the rogue AP.

$rest->real_time_localisation_for_rogueaps_count

Returns a count of Rogue APs on MSE based on the Query Param conditions you specify. Returns a list of Location of Rogue APs for the specified query conditions.

Parameters:

  • []: Defines query conditions for the rogue AP.

$rest->real_time_localisation_for_rogueclients

Returns the Location of Rogue Client for the id you give it. ๐Ÿ•ต๏ธ

Parameters:

  • id: MAC address of the rogue client.

$rest->real_time_localisation_for_rogueclients_count

Returns a count of Rogue Clients on MSE based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the rogue client.

$rest->real_time_localisation_for_interferers

Returns the Location of Interferer for the id you give it. Returns a count of Rogue Clients on MSE based on the specified Query Param conditions. ๐Ÿ“ก

Parameters:

  • id: MAC address of the interferer.

$rest->real_time_localisation_for_interferers_count

Returns a count of Interferers on MSE based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the interferers.

$rest->localisation_history_for_client

Returns a list of historical Location records of Wireless Client for the id and query conditions you give it. The receipts, but location edition. ๐Ÿ•ฐ๏ธ

Parameters:

  • id: MAC address, IP address, or username of the wireless client.
  • []: Defines query conditions for the wireless client

$rest->localisation_history_for_client_count

Returns a count of historical Location records of Wireless Clients on MSE based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the wireless client.

$rest->localisation_history_for_tags

Returns a list of the historical Location records of Tag for the id and query conditions you give it. ๐Ÿท๏ธ

Parameters:

  • id: MAC address of the tag
  • []: Defines query conditions for the tag.

$rest->localisation_history_for_tags_count

Returns a count of historical location records of Tags on MSE based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the interferers.

$rest->localisation_history_for_rogueaps

Returns a list of historical records of Location of Rogue APs for the query conditions you specify. ๐Ÿšจ

Parameters:

  • []: Defines query conditions for the rogue AP.

$rest->localisation_history_for_rogueaps_count

Returns a count of historical Location records of Rogue APs based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the rogue AP.

$rest->localisation_history_for_rogueclients

Returns a list of historical Location records of Rogue Clients for the query conditions you specify. ๐Ÿ•ต๏ธ

Parameters:

  • []: Defines query conditions for the rogue client.

$rest->localisation_history_for_rogueclients_count

Returns a count of Historical Location records of Rogue Clients on MSE based on the Query Param conditions you specify. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the rogue client.

$rest->localisation_history_for_interferers

Returns a list of historical Location records of Interferers for the query conditions you specify. ๐Ÿ“ก

Parameters:

  • []: Defines query conditions for the interferers.

$rest->localisation_history_for_interferers_count

Returns a count of historical Location records of Interferers for the id and query conditions you give it. ๐Ÿ”ข

Parameters:

  • []: Defines query conditions for the interferers.

$rest->notification_create

Creates and subscribes to a notification. โœจ

Parameters:

  • {"NotificationSubscription"=> { โ€” here's the whole payload, verbatim, because it is a lot and we respect it:
{"NotificationSubscription"=> {
     "name"=> "OutIn",
     "notificationType"=> "EVENT_DRIVEN",
     "dataFormat"=> "JSON",
     "subscribedEvents"=>    [
              {
           "type"=> "ContainmentEventTrigger",
           "eventEntity"=> "WIRELESS_CLIENTS",
           "boundary"=> "INSIDE",
           "zoneHierarchy" => "Buiding>8th level>Network-Zone",
           "zoneTimeout" => 10,
        },
        {
           "type"=> "ContainmentEventTrigger",
           "eventEntity"=> "WIRELESS_CLIENTS",
           "boundary"=> "OUTSIDE",
           "zoneHierarchy" => "Building>8th level>Network-Zone",
           "zoneTimeout" => 10,
        }
     ],
     "NotificationReceiverInfo"=> {"transport"=>    {
        "type"=> "TransportHttp",
        "hostAddress"=> "192.168.0.1",
        "port"=> 9292,
        "macScramblingEnabled"=> false,
        "urlPath"=> "/mse/",
        "https"=> false
     }}
  }};
note the "Buiding>8th level>Network-Zone" spelling in there โ€” yes, we see it, we're leaving it exactly as-is, it's the author's โœจartistic choiceโœจ ๐Ÿ’€

$rest->notification_view

View all notifications created by the current logged-in user. Peek at your own notifications, nosy (affectionate). ๐Ÿ‘€

Parameters:

  • []: Defines query conditions for the interferers.

$rest->notification_delete

Deletes a specific notification. Goodbye forever bestie ๐Ÿซถ

Parameters:

  • name: name of the notification

๐Ÿ’œ LICENSE ๐Ÿ’œ

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>


k bye ily, this was Net::C...E::REST(3pm) from the User Contributed Perl Documentation, churned out with perl v5.36.0 on 2022-11-27. go locate something iconic ๐Ÿ’…โœจ