@@ -21,6 +21,16 @@ def __init__(
2121 instance_id : str | None = None ,
2222 ssh_key_ids : list [str ] = [],
2323 deleted_at : str | None = None ,
24+ pseudo_path : str | None = None ,
25+ mount_command : str | None = None ,
26+ create_directory_command : str | None = None ,
27+ filesystem_to_fstab_command : str | None = None ,
28+ instances : list [dict ] | None = None ,
29+ contract : str | None = None ,
30+ base_hourly_cost : float | None = None ,
31+ monthly_price : float | None = None ,
32+ currency : str | None = None ,
33+ long_term : dict | None = None ,
2434 ) -> None :
2535 """Initialize the volume object.
2636
@@ -48,6 +58,26 @@ def __init__(
4858 :type ssh_key_ids: list[str]
4959 :param deleted_at: the time the volume was deleted (UTC), defaults to None
5060 :type deleted_at: str, optional
61+ :param pseudo_path: volume pseudo path for NFS export, defaults to None
62+ :type pseudo_path: str, optional
63+ :param mount_command: ready-to-use NFS mount command, defaults to None
64+ :type mount_command: str, optional
65+ :param create_directory_command: mkdir command for mount point, defaults to None
66+ :type create_directory_command: str, optional
67+ :param filesystem_to_fstab_command: fstab entry command for persistent mounts, defaults to None
68+ :type filesystem_to_fstab_command: str, optional
69+ :param instances: list of attached instance details, defaults to None
70+ :type instances: list[dict], optional
71+ :param contract: volume contract type e.g. "LONG_TERM", "PAY_AS_YOU_GO", defaults to None
72+ :type contract: str, optional
73+ :param base_hourly_cost: volume base hourly cost, defaults to None
74+ :type base_hourly_cost: float, optional
75+ :param monthly_price: volume monthly price, defaults to None
76+ :type monthly_price: float, optional
77+ :param currency: volume currency e.g. "usd", "eur", defaults to None
78+ :type currency: str, optional
79+ :param long_term: long term contract details, defaults to None
80+ :type long_term: dict, optional
5181 """
5282 self ._id = id
5383 self ._status = status
@@ -61,6 +91,16 @@ def __init__(
6191 self ._instance_id = instance_id
6292 self ._ssh_key_ids = ssh_key_ids
6393 self ._deleted_at = deleted_at
94+ self ._pseudo_path = pseudo_path
95+ self ._mount_command = mount_command
96+ self ._create_directory_command = create_directory_command
97+ self ._filesystem_to_fstab_command = filesystem_to_fstab_command
98+ self ._instances = instances
99+ self ._contract = contract
100+ self ._base_hourly_cost = base_hourly_cost
101+ self ._monthly_price = monthly_price
102+ self ._currency = currency
103+ self ._long_term = long_term
64104
65105 @property
66106 def id (self ) -> str :
@@ -170,6 +210,96 @@ def deleted_at(self) -> str | None:
170210 """
171211 return self ._deleted_at
172212
213+ @property
214+ def pseudo_path (self ) -> str | None :
215+ """Get the volume pseudo path for NFS export.
216+
217+ :return: volume pseudo path
218+ :rtype: str, optional
219+ """
220+ return self ._pseudo_path
221+
222+ @property
223+ def mount_command (self ) -> str | None :
224+ """Get the ready-to-use NFS mount command.
225+
226+ :return: mount command
227+ :rtype: str, optional
228+ """
229+ return self ._mount_command
230+
231+ @property
232+ def create_directory_command (self ) -> str | None :
233+ """Get the mkdir command for creating the mount point directory.
234+
235+ :return: create directory command
236+ :rtype: str, optional
237+ """
238+ return self ._create_directory_command
239+
240+ @property
241+ def filesystem_to_fstab_command (self ) -> str | None :
242+ """Get the fstab entry command for persistent mounts.
243+
244+ :return: fstab command
245+ :rtype: str, optional
246+ """
247+ return self ._filesystem_to_fstab_command
248+
249+ @property
250+ def instances (self ) -> list [dict ] | None :
251+ """Get the list of attached instance details.
252+
253+ :return: list of instance details
254+ :rtype: list[dict], optional
255+ """
256+ return self ._instances
257+
258+ @property
259+ def contract (self ) -> str | None :
260+ """Get the volume contract type.
261+
262+ :return: contract type e.g. "LONG_TERM", "PAY_AS_YOU_GO"
263+ :rtype: str, optional
264+ """
265+ return self ._contract
266+
267+ @property
268+ def base_hourly_cost (self ) -> float | None :
269+ """Get the volume base hourly cost.
270+
271+ :return: base hourly cost
272+ :rtype: float, optional
273+ """
274+ return self ._base_hourly_cost
275+
276+ @property
277+ def monthly_price (self ) -> float | None :
278+ """Get the volume monthly price.
279+
280+ :return: monthly price
281+ :rtype: float, optional
282+ """
283+ return self ._monthly_price
284+
285+ @property
286+ def currency (self ) -> str | None :
287+ """Get the volume currency.
288+
289+ :return: currency e.g. "usd", "eur"
290+ :rtype: str, optional
291+ """
292+ return self ._currency
293+
294+ @property
295+ def long_term (self ) -> dict | None :
296+ """Get the long term contract details.
297+
298+ :return: long term contract details
299+ :rtype: dict, optional
300+ """
301+ return self ._long_term
302+
173303 @classmethod
174304 def create_from_dict (cls : 'Volume' , volume_dict : dict ) -> 'Volume' :
175305 """Create a Volume object from a dictionary.
@@ -192,6 +322,16 @@ def create_from_dict(cls: 'Volume', volume_dict: dict) -> 'Volume':
192322 instance_id = volume_dict ['instance_id' ],
193323 ssh_key_ids = volume_dict ['ssh_key_ids' ],
194324 deleted_at = volume_dict .get ('deleted_at' ),
325+ pseudo_path = volume_dict .get ('pseudo_path' ),
326+ mount_command = volume_dict .get ('mount_command' ),
327+ create_directory_command = volume_dict .get ('create_directory_command' ),
328+ filesystem_to_fstab_command = volume_dict .get ('filesystem_to_fstab_command' ),
329+ instances = volume_dict .get ('instances' ),
330+ contract = volume_dict .get ('contract' ),
331+ base_hourly_cost = volume_dict .get ('base_hourly_cost' ),
332+ monthly_price = volume_dict .get ('monthly_price' ),
333+ currency = volume_dict .get ('currency' ),
334+ long_term = volume_dict .get ('long_term' ),
195335 )
196336
197337 def __str__ (self ) -> str :
0 commit comments