Export Inventory

Dion1
New here

Export Inventory

Hi, 

 

we have around 50 networks of combined hardware is it possible to export this data for all networks? 

 

i am looking for 

 

  • Name
  • System Name
  • Serial Number
  • Make
  • Model
  • OS
  • Notes

 

At the moment the only way I can see to do this is to do it site by site. 

 

Any other reporting would be great too 

9 Replies 9
alemabrahao
Kind of a big deal
Kind of a big deal

Is the API a option for you? Have you checked the organization inventory?

I am not a Cisco Meraki employee. My suggestions are based on documentation of Meraki best practices and day-to-day experience.

Please, if this post was useful, leave your kudos and mark it as solved.
Dion1
New here

if it will give me some or of this yes 

 

  • Name
  • System Name
  • Serial Number
  • Make
  • Model
  • OS
  • Notes
alemabrahao
Kind of a big deal
Kind of a big deal

  • The information on organization inventory are not enough?

 

Screenshot_20221216-145334_Chrome.jpg

I am not a Cisco Meraki employee. My suggestions are based on documentation of Meraki best practices and day-to-day experience.

Please, if this post was useful, leave your kudos and mark it as solved.
PhilipDAth
Kind of a big deal
Kind of a big deal

You can get most of this by going to Organisation/Inventory.  Then click on the spanner in the upper right hand corner and turn on some extra columns:

PhilipDAth_0-1671391960461.png

 

Then click "Download as CSV".

 

You wont be able to get notes.

Dion1
New here

Hi Philip, This is how i have been doing so but this can only be done on a network by network baces. i hoping to export a list for all networks at the same time. 

alemabrahao
Kind of a big deal
Kind of a big deal

Wrong, It's by organization.

I am not a Cisco Meraki employee. My suggestions are based on documentation of Meraki best practices and day-to-day experience.

Please, if this post was useful, leave your kudos and mark it as solved.
Dion1
New here

Hi, 

 

Organisation/Inventory only shows the meraki Cameras not the combined hardware like iPads. 

alemabrahao
Kind of a big deal
Kind of a big deal

So, you want to export the client list.  In this case, the only option is via API.

 

https://developer.cisco.com/meraki/api/#!get-network-clients

 

You need to create a script to get it from each network.

 

I am not a Cisco Meraki employee. My suggestions are based on documentation of Meraki best practices and day-to-day experience.

Please, if this post was useful, leave your kudos and mark it as solved.
PaulF
Meraki Employee
Meraki Employee

As others have mentioned, the API is probably the right way to do this.

 

# Meraki library : pip install meraki : https://developer.cisco.com/meraki/api/#/python/getting-started

import meraki
import logging, sys, getopt

loggingEnabled = True

def main(argv):

    print("Meraki Library version: ")
    print(meraki.__version__)

    arg_APIKey = "xxx"

    arg_orgID = "xxx"

    # Create Meraki Client Object and initialise
    client = meraki.DashboardAPI(api_key=arg_APIKey)

    # orgs = client.organizations.getOrganizations()

    # get Networks
    networks = client.organizations.getOrganizationNetworks(organizationId=arg_orgID)

    for network in networks:
        try:
            deviceList = client.sm.getNetworkSmDevices(networkId=network["id"])
        except meraki.APIError as e:
            print("Not an SM network")

        print(deviceList)


if __name__ == '__main__':
    main(sys.argv[1:])

 

 

You'll need three things for this to work:

  • The Meraki Library Installed. 
  • Your Organization ID
  • Your API key

 

All of this is covered here: https://documentation.meraki.com/General_Administration/Other_Topics/Cisco_Meraki_Dashboard_API

 

The above script needs editing with the API key and the Organization ID, and will export to the interface all the details that you want.

 

The API does take optional extras:

 

def getNetworkSmDevices(self,
networkId: str,
total_pages: int = 1,
direction: str = 'next',
**kwargs: Any) -> Any
List the devices enrolled in an SM network with various specified fields and filters
https://developer.cisco.com/meraki/api-v1/#!get-network-sm-devices
networkId (string): (required)
total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages
direction (string): direction to paginate, either "next" (default) or "prev" page
fields (array): Additional fields that will be displayed for each device.
The default fields are: id, name, tags, ssid, wifiMac, osName, systemModel, uuid, and serialNumber. The additional fields are: ip, systemType, availableDeviceCapacity, kioskAppName, biosVersion, lastConnected, missingAppsCount, userSuppliedAddress, location, lastUser, ownerEmail, ownerUsername, osBuild, publicIp, phoneNumber, diskInfoJson, deviceCapacity, isManaged, hadMdm, isSupervised, meid, imei, iccid, simCarrierNetwork, cellularDataUsed, isHotspotEnabled, createdAt, batteryEstCharge, quarantined, avName, avRunning, asName, fwName, isRooted, loginRequired, screenLockEnabled, screenLockDelay, autoLoginDisabled, autoTags, hasMdm, hasDesktopAgent, diskEncryptionEnabled, hardwareEncryptionCaps, passCodeLock, usesHardwareKeystore, androidSecurityPatchVersion, and url.

wifiMacs (array): Filter devices by wifi mac(s).
serials (array): Filter devices by serial(s).
ids (array): Filter devices by id(s).
scope (array): Specify a scope (one of all, none, withAny, withAll, withoutAny, or withoutAll) and a set of tags.
perPage (integer): The number of entries per page returned. Acceptable range is 3 - 1000. Default is 1000.
startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it.
endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it.

Get notified when there are additional replies to this discussion.
Welcome to the Meraki Community!
To start contributing, simply sign in with your Cisco account. If you don't yet have a Cisco account, you can sign up.
Labels