NetApp / ontap-rest-python

This repository contains sample code illustrating how to access the ONTAP REST API using Python. This Repository also contains ONTAPI Usage reporting code that helps to identify ONTAPI usage in your environment using ONTAP REST APIs.
BSD 3-Clause "New" or "Revised" License
62 stars 41 forks source link

Size field not available in Snapshot #42

Open ItsDevMonk opened 1 year ago

ItsDevMonk commented 1 year ago

I want to collect the list of snapshot along with its size. But under this api /api/storage/volumes/{volume.uuid}/snapshots, I couldn't find the size of the snapshot. Is there any other api to get the size?

github-actions[bot] commented 1 year ago

Thank you for reporting an issue! If you haven't already joined our Discord community, then we invite you to do so. This is a great place to get help and ask questions from our community.

noorbuchi commented 1 year ago

Hello, Every snapshot object returned by /storage/volumes/{volume.uuid}/snapshots and /storage/volumes/{volume.uuid}/snapshots/{uuid} has a property called size. You can find the documentation on it here: https://library.netapp.com/ecmdocs/ECMLP2885777/html/resources/snapshot.html#netapp_ontap.resources.snapshot.SnapshotSchema.size

Is this what you're looking for?