File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -350,7 +350,8 @@ def create(self,
350350 startup_script_id : str = None ,
351351 volumes : List [Dict ] = None ,
352352 os_volume : Dict = None ,
353- is_spot : bool = False ) -> Instance :
353+ is_spot : bool = False ,
354+ coupon : str = None ) -> Instance :
354355 """Creates (deploys) a new instance
355356
356357 :param instance_type: instance type. e.g. '8V100.48M'
@@ -373,6 +374,8 @@ def create(self,
373374 :type os_volume: Dict, optional
374375 :param is_spot: Is spot instance
375376 :type is_spot: bool, optional
377+ :param coupon: coupon code
378+ :type is_spot: str, optional
376379 :return: the new instance object
377380 :rtype: id
378381 """
@@ -386,7 +389,8 @@ def create(self,
386389 "location" : location ,
387390 "os_volume" : os_volume ,
388391 "volumes" : volumes ,
389- "is_spot" : is_spot
392+ "is_spot" : is_spot ,
393+ "coupon" : coupon
390394 }
391395 id = self ._http_client .post (INSTANCES_ENDPOINT , json = payload ).text
392396 instance = self .get_by_id (id )
You can’t perform that action at this time.
0 commit comments