Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Export Device Inventory

    Use this API to export the device chassis information managed through Junos Space to a Microsoft Excel or comma-separated view (CSV) file.

    URI

    https://[host]/api/juniper/servicenow/device-management/devices/ exportDeviceInventory?type={type} (HTTP method = POST)

    URI Parameters

    Parameter

    Type

    Required

    Description

    devices

    String

    Exports only the listed device information. If no devices are specified, exports all found devices.

    type

    String

    Defines the output format. Valid options are: excel and csv.

    If type is not defined, the output is generated as a Microsoft Excel document.

    In the following example (listed both as XML and JSON) only the two specified devices are exported.

    <export>
         <devices>
              <device uri="/api/juniper/servicenow/device-management/devices/622592"/>
              <device uri="/api/juniper/servicenow/device-management/devices/622593"/>
         </devices>
    </export>
    
    export:{
            devices:{
                device:[
                    {
                        uri:'/api/juniper/servicenow/device-management/devices/622592'
                    },
                    {
                        uri:'/api/juniper/servicenow/device-management/devices/622593'
                    }
                ]
            }
        }
    

    Consumes

    • application/vnd.juniper.servicenow.device-management.export+xml;version=1 ;charset=UTF-8
    • application/vnd.juniper.servicenow.device-management.export+json;version=1 ;charset=UTF-8

    Request Elements

    Produces

    application/octet-stream

    Response

    The response is an Octet-Stream and the file is downloaded in either Excel or CSV format.

    Response Status Code

    Message

    Description

    404 Not Found

    Invalid device ID.

    400 Bad Request

    Invalid type specified. The type element must be Excel or CSVs.

    Modified: 2016-08-11