- Change .py files to use 4-space indents and no hard tab characters.
[plcapi.git] / PLC / Methods / GetSliceTicket.py
index 822d003..90c0f63 100644 (file)
@@ -1,3 +1,6 @@
+# $Id$
+# $URL$
+
 import time
 
 from PLC.Faults import *
@@ -6,6 +9,7 @@ from PLC.Parameter import Parameter, Mixed
 from PLC.Slices import Slice, Slices
 from PLC.Auth import Auth
 from PLC.GPG import gpg_sign, gpg_verify
+from PLC.InitScripts import InitScript, InitScripts
 
 from PLC.Methods.GetSlivers import get_slivers
 
@@ -54,9 +58,12 @@ class GetSliceTicket(Method):
         # Tickets are the canonicalized XML-RPC methodResponse
         # representation of a partial GetSlivers() response, i.e.,
 
+        initscripts = InitScripts(self.api, {'enabled': True})
+
         data = {
             'timestamp': int(time.time()),
-            'slivers': get_slivers(self.api, [slice['slice_id']]),
+            'initscripts': initscripts,
+            'slivers': get_slivers(self.api, auth, [slice['slice_id']]),
             }
 
         # Sign ticket