Hook up Unit.run() to api
[osm/N2VC.git] / juju / client / _client.py
1 # DO NOT CHANGE THIS FILE! This file is auto-generated by facade.py.
2 # Changes will be overwritten/lost when the file is regenerated.
3
4 from juju.client.facade import Type, ReturnMapping
5
6
7 class Action(Type):
8 _toSchema = {'parameters': 'parameters', 'receiver': 'receiver', 'tag': 'tag', 'name': 'name'}
9 _toPy = {'parameters': 'parameters', 'receiver': 'receiver', 'tag': 'tag', 'name': 'name'}
10 def __init__(self, name=None, parameters=None, receiver=None, tag=None):
11 '''
12 name : str
13 parameters : typing.Mapping[str, typing.Any]
14 receiver : str
15 tag : str
16 '''
17 self.name = name
18 self.parameters = parameters
19 self.receiver = receiver
20 self.tag = tag
21
22
23 class ActionResult(Type):
24 _toSchema = {'action': 'action', 'completed': 'completed', 'output': 'output', 'started': 'started', 'enqueued': 'enqueued', 'message': 'message', 'error': 'error', 'status': 'status'}
25 _toPy = {'action': 'action', 'completed': 'completed', 'output': 'output', 'started': 'started', 'enqueued': 'enqueued', 'message': 'message', 'error': 'error', 'status': 'status'}
26 def __init__(self, action=None, completed=None, enqueued=None, error=None, message=None, output=None, started=None, status=None):
27 '''
28 action : Action
29 completed : str
30 enqueued : str
31 error : Error
32 message : str
33 output : typing.Mapping[str, typing.Any]
34 started : str
35 status : str
36 '''
37 self.action = Action.from_json(action) if action else None
38 self.completed = completed
39 self.enqueued = enqueued
40 self.error = Error.from_json(error) if error else None
41 self.message = message
42 self.output = output
43 self.started = started
44 self.status = status
45
46
47 class ActionResults(Type):
48 _toSchema = {'results': 'results'}
49 _toPy = {'results': 'results'}
50 def __init__(self, results=None):
51 '''
52 results : typing.Sequence[~ActionResult]
53 '''
54 self.results = [ActionResult.from_json(o) for o in results or []]
55
56
57 class ActionSpec(Type):
58 _toSchema = {'description': 'Description', 'params': 'Params'}
59 _toPy = {'Description': 'description', 'Params': 'params'}
60 def __init__(self, description=None, params=None):
61 '''
62 description : str
63 params : typing.Mapping[str, typing.Any]
64 '''
65 self.description = description
66 self.params = params
67
68
69 class Actions(Type):
70 _toSchema = {'actionspecs': 'ActionSpecs'}
71 _toPy = {'ActionSpecs': 'actionspecs'}
72 def __init__(self, actionspecs=None):
73 '''
74 actionspecs : typing.Mapping[str, ~ActionSpec]
75 '''
76 self.actionspecs = {k: ActionSpec.from_json(v) for k, v in (actionspecs or dict()).items()}
77
78
79 class ActionsByName(Type):
80 _toSchema = {'name': 'name', 'actions': 'actions', 'error': 'error'}
81 _toPy = {'name': 'name', 'actions': 'actions', 'error': 'error'}
82 def __init__(self, actions=None, error=None, name=None):
83 '''
84 actions : typing.Sequence[~ActionResult]
85 error : Error
86 name : str
87 '''
88 self.actions = [ActionResult.from_json(o) for o in actions or []]
89 self.error = Error.from_json(error) if error else None
90 self.name = name
91
92
93 class ActionsByNames(Type):
94 _toSchema = {'actions': 'actions'}
95 _toPy = {'actions': 'actions'}
96 def __init__(self, actions=None):
97 '''
98 actions : typing.Sequence[~ActionsByName]
99 '''
100 self.actions = [ActionsByName.from_json(o) for o in actions or []]
101
102
103 class ActionsByReceiver(Type):
104 _toSchema = {'receiver': 'receiver', 'actions': 'actions', 'error': 'error'}
105 _toPy = {'receiver': 'receiver', 'actions': 'actions', 'error': 'error'}
106 def __init__(self, actions=None, error=None, receiver=None):
107 '''
108 actions : typing.Sequence[~ActionResult]
109 error : Error
110 receiver : str
111 '''
112 self.actions = [ActionResult.from_json(o) for o in actions or []]
113 self.error = Error.from_json(error) if error else None
114 self.receiver = receiver
115
116
117 class ActionsByReceivers(Type):
118 _toSchema = {'actions': 'actions'}
119 _toPy = {'actions': 'actions'}
120 def __init__(self, actions=None):
121 '''
122 actions : typing.Sequence[~ActionsByReceiver]
123 '''
124 self.actions = [ActionsByReceiver.from_json(o) for o in actions or []]
125
126
127 class ApplicationCharmActionsResult(Type):
128 _toSchema = {'applicationtag': 'ApplicationTag', 'actions': 'actions', 'error': 'error'}
129 _toPy = {'actions': 'actions', 'ApplicationTag': 'applicationtag', 'error': 'error'}
130 def __init__(self, applicationtag=None, actions=None, error=None):
131 '''
132 applicationtag : str
133 actions : Actions
134 error : Error
135 '''
136 self.applicationtag = applicationtag
137 self.actions = Actions.from_json(actions) if actions else None
138 self.error = Error.from_json(error) if error else None
139
140
141 class ApplicationsCharmActionsResults(Type):
142 _toSchema = {'results': 'results'}
143 _toPy = {'results': 'results'}
144 def __init__(self, results=None):
145 '''
146 results : typing.Sequence[~ApplicationCharmActionsResult]
147 '''
148 self.results = [ApplicationCharmActionsResult.from_json(o) for o in results or []]
149
150
151 class Entities(Type):
152 _toSchema = {'entities': 'Entities'}
153 _toPy = {'Entities': 'entities'}
154 def __init__(self, entities=None):
155 '''
156 entities : typing.Sequence[~Entity]
157 '''
158 self.entities = [Entity.from_json(o) for o in entities or []]
159
160
161 class Entity(Type):
162 _toSchema = {'tag': 'Tag'}
163 _toPy = {'Tag': 'tag'}
164 def __init__(self, tag=None):
165 '''
166 tag : str
167 '''
168 self.tag = tag
169
170
171 class Error(Type):
172 _toSchema = {'code': 'Code', 'message': 'Message', 'info': 'Info'}
173 _toPy = {'Code': 'code', 'Message': 'message', 'Info': 'info'}
174 def __init__(self, code=None, info=None, message=None):
175 '''
176 code : str
177 info : ErrorInfo
178 message : str
179 '''
180 self.code = code
181 self.info = ErrorInfo.from_json(info) if info else None
182 self.message = message
183
184
185 class ErrorInfo(Type):
186 _toSchema = {'macaroonpath': 'MacaroonPath', 'macaroon': 'Macaroon'}
187 _toPy = {'Macaroon': 'macaroon', 'MacaroonPath': 'macaroonpath'}
188 def __init__(self, macaroon=None, macaroonpath=None):
189 '''
190 macaroon : Macaroon
191 macaroonpath : str
192 '''
193 self.macaroon = Macaroon.from_json(macaroon) if macaroon else None
194 self.macaroonpath = macaroonpath
195
196
197 class FindActionsByNames(Type):
198 _toSchema = {'names': 'names'}
199 _toPy = {'names': 'names'}
200 def __init__(self, names=None):
201 '''
202 names : typing.Sequence[str]
203 '''
204 self.names = names
205
206
207 class FindTags(Type):
208 _toSchema = {'prefixes': 'prefixes'}
209 _toPy = {'prefixes': 'prefixes'}
210 def __init__(self, prefixes=None):
211 '''
212 prefixes : typing.Sequence[str]
213 '''
214 self.prefixes = prefixes
215
216
217 class FindTagsResults(Type):
218 _toSchema = {'matches': 'matches'}
219 _toPy = {'matches': 'matches'}
220 def __init__(self, matches=None):
221 '''
222 matches : typing.Sequence[~Entity]
223 '''
224 self.matches = [Entity.from_json(o) for o in matches or []]
225
226
227 class Macaroon(Type):
228 _toSchema = {'caveats': 'caveats', 'location': 'location', 'data': 'data', 'id_': 'id', 'sig': 'sig'}
229 _toPy = {'caveats': 'caveats', 'location': 'location', 'data': 'data', 'sig': 'sig', 'id': 'id_'}
230 def __init__(self, caveats=None, data=None, id_=None, location=None, sig=None):
231 '''
232 caveats : typing.Sequence[~caveat]
233 data : typing.Sequence[int]
234 id_ : packet
235 location : packet
236 sig : typing.Sequence[int]
237 '''
238 self.caveats = [caveat.from_json(o) for o in caveats or []]
239 self.data = data
240 self.id_ = packet.from_json(id_) if id_ else None
241 self.location = packet.from_json(location) if location else None
242 self.sig = sig
243
244
245 class RunParams(Type):
246 _toSchema = {'units': 'Units', 'applications': 'Applications', 'commands': 'Commands', 'machines': 'Machines', 'timeout': 'Timeout'}
247 _toPy = {'Applications': 'applications', 'Commands': 'commands', 'Timeout': 'timeout', 'Units': 'units', 'Machines': 'machines'}
248 def __init__(self, applications=None, commands=None, machines=None, timeout=None, units=None):
249 '''
250 applications : typing.Sequence[str]
251 commands : str
252 machines : typing.Sequence[str]
253 timeout : int
254 units : typing.Sequence[str]
255 '''
256 self.applications = applications
257 self.commands = commands
258 self.machines = machines
259 self.timeout = timeout
260 self.units = units
261
262
263 class caveat(Type):
264 _toSchema = {'caveatid': 'caveatId', 'location': 'location', 'verificationid': 'verificationId'}
265 _toPy = {'verificationId': 'verificationid', 'location': 'location', 'caveatId': 'caveatid'}
266 def __init__(self, caveatid=None, location=None, verificationid=None):
267 '''
268 caveatid : packet
269 location : packet
270 verificationid : packet
271 '''
272 self.caveatid = packet.from_json(caveatid) if caveatid else None
273 self.location = packet.from_json(location) if location else None
274 self.verificationid = packet.from_json(verificationid) if verificationid else None
275
276
277 class packet(Type):
278 _toSchema = {'start': 'start', 'totallen': 'totalLen', 'headerlen': 'headerLen'}
279 _toPy = {'start': 'start', 'totalLen': 'totallen', 'headerLen': 'headerlen'}
280 def __init__(self, headerlen=None, start=None, totallen=None):
281 '''
282 headerlen : int
283 start : int
284 totallen : int
285 '''
286 self.headerlen = headerlen
287 self.start = start
288 self.totallen = totallen
289
290
291 class BoolResult(Type):
292 _toSchema = {'result': 'Result', 'error': 'Error'}
293 _toPy = {'Result': 'result', 'Error': 'error'}
294 def __init__(self, error=None, result=None):
295 '''
296 error : Error
297 result : bool
298 '''
299 self.error = Error.from_json(error) if error else None
300 self.result = result
301
302
303 class EntitiesWatchResult(Type):
304 _toSchema = {'changes': 'Changes', 'error': 'Error', 'entitywatcherid': 'EntityWatcherId'}
305 _toPy = {'Changes': 'changes', 'Error': 'error', 'EntityWatcherId': 'entitywatcherid'}
306 def __init__(self, changes=None, entitywatcherid=None, error=None):
307 '''
308 changes : typing.Sequence[str]
309 entitywatcherid : str
310 error : Error
311 '''
312 self.changes = changes
313 self.entitywatcherid = entitywatcherid
314 self.error = Error.from_json(error) if error else None
315
316
317 class ErrorResult(Type):
318 _toSchema = {'code': 'Code', 'message': 'Message', 'info': 'Info'}
319 _toPy = {'Code': 'code', 'Message': 'message', 'Info': 'info'}
320 def __init__(self, code=None, info=None, message=None):
321 '''
322 code : str
323 info : ErrorInfo
324 message : str
325 '''
326 self.code = code
327 self.info = ErrorInfo.from_json(info) if info else None
328 self.message = message
329
330
331 class AgentGetEntitiesResult(Type):
332 _toSchema = {'jobs': 'Jobs', 'life': 'Life', 'error': 'Error', 'containertype': 'ContainerType'}
333 _toPy = {'Life': 'life', 'ContainerType': 'containertype', 'Error': 'error', 'Jobs': 'jobs'}
334 def __init__(self, containertype=None, error=None, jobs=None, life=None):
335 '''
336 containertype : str
337 error : Error
338 jobs : typing.Sequence[str]
339 life : str
340 '''
341 self.containertype = containertype
342 self.error = Error.from_json(error) if error else None
343 self.jobs = jobs
344 self.life = life
345
346
347 class AgentGetEntitiesResults(Type):
348 _toSchema = {'entities': 'Entities'}
349 _toPy = {'Entities': 'entities'}
350 def __init__(self, entities=None):
351 '''
352 entities : typing.Sequence[~AgentGetEntitiesResult]
353 '''
354 self.entities = [AgentGetEntitiesResult.from_json(o) for o in entities or []]
355
356
357 class EntityPassword(Type):
358 _toSchema = {'password': 'Password', 'tag': 'Tag'}
359 _toPy = {'Tag': 'tag', 'Password': 'password'}
360 def __init__(self, password=None, tag=None):
361 '''
362 password : str
363 tag : str
364 '''
365 self.password = password
366 self.tag = tag
367
368
369 class EntityPasswords(Type):
370 _toSchema = {'changes': 'Changes'}
371 _toPy = {'Changes': 'changes'}
372 def __init__(self, changes=None):
373 '''
374 changes : typing.Sequence[~EntityPassword]
375 '''
376 self.changes = [EntityPassword.from_json(o) for o in changes or []]
377
378
379 class ErrorResults(Type):
380 _toSchema = {'results': 'Results'}
381 _toPy = {'Results': 'results'}
382 def __init__(self, results=None):
383 '''
384 results : typing.Sequence[~ErrorResult]
385 '''
386 self.results = [ErrorResult.from_json(o) for o in results or []]
387
388
389 class IsMasterResult(Type):
390 _toSchema = {'master': 'Master'}
391 _toPy = {'Master': 'master'}
392 def __init__(self, master=None):
393 '''
394 master : bool
395 '''
396 self.master = master
397
398
399 class ModelConfigResult(Type):
400 _toSchema = {'config': 'Config'}
401 _toPy = {'Config': 'config'}
402 def __init__(self, config=None):
403 '''
404 config : typing.Mapping[str, typing.Any]
405 '''
406 self.config = config
407
408
409 class NotifyWatchResult(Type):
410 _toSchema = {'notifywatcherid': 'NotifyWatcherId', 'error': 'Error'}
411 _toPy = {'NotifyWatcherId': 'notifywatcherid', 'Error': 'error'}
412 def __init__(self, error=None, notifywatcherid=None):
413 '''
414 error : Error
415 notifywatcherid : str
416 '''
417 self.error = Error.from_json(error) if error else None
418 self.notifywatcherid = notifywatcherid
419
420
421 class StateServingInfo(Type):
422 _toSchema = {'apiport': 'APIPort', 'stateport': 'StatePort', 'cert': 'Cert', 'caprivatekey': 'CAPrivateKey', 'systemidentity': 'SystemIdentity', 'sharedsecret': 'SharedSecret', 'privatekey': 'PrivateKey'}
423 _toPy = {'SharedSecret': 'sharedsecret', 'CAPrivateKey': 'caprivatekey', 'Cert': 'cert', 'PrivateKey': 'privatekey', 'StatePort': 'stateport', 'SystemIdentity': 'systemidentity', 'APIPort': 'apiport'}
424 def __init__(self, apiport=None, caprivatekey=None, cert=None, privatekey=None, sharedsecret=None, stateport=None, systemidentity=None):
425 '''
426 apiport : int
427 caprivatekey : str
428 cert : str
429 privatekey : str
430 sharedsecret : str
431 stateport : int
432 systemidentity : str
433 '''
434 self.apiport = apiport
435 self.caprivatekey = caprivatekey
436 self.cert = cert
437 self.privatekey = privatekey
438 self.sharedsecret = sharedsecret
439 self.stateport = stateport
440 self.systemidentity = systemidentity
441
442
443 class AllWatcherNextResults(Type):
444 _toSchema = {'deltas': 'Deltas'}
445 _toPy = {'Deltas': 'deltas'}
446 def __init__(self, deltas=None):
447 '''
448 deltas : typing.Sequence[~Delta]
449 '''
450 self.deltas = [Delta.from_json(o) for o in deltas or []]
451
452
453 class Delta(Type):
454 _toSchema = {'entity': 'Entity', 'removed': 'Removed'}
455 _toPy = {'Removed': 'removed', 'Entity': 'entity'}
456 def __init__(self, entity=None, removed=None):
457 '''
458 entity : typing.Mapping[str, typing.Any]
459 removed : bool
460 '''
461 self.entity = entity
462 self.removed = removed
463
464
465 class AnnotationsGetResult(Type):
466 _toSchema = {'entitytag': 'EntityTag', 'annotations': 'Annotations', 'error': 'Error'}
467 _toPy = {'Error': 'error', 'Annotations': 'annotations', 'EntityTag': 'entitytag'}
468 def __init__(self, annotations=None, entitytag=None, error=None):
469 '''
470 annotations : typing.Mapping[str, str]
471 entitytag : str
472 error : ErrorResult
473 '''
474 self.annotations = annotations
475 self.entitytag = entitytag
476 self.error = ErrorResult.from_json(error) if error else None
477
478
479 class AnnotationsGetResults(Type):
480 _toSchema = {'results': 'Results'}
481 _toPy = {'Results': 'results'}
482 def __init__(self, results=None):
483 '''
484 results : typing.Sequence[~AnnotationsGetResult]
485 '''
486 self.results = [AnnotationsGetResult.from_json(o) for o in results or []]
487
488
489 class AnnotationsSet(Type):
490 _toSchema = {'annotations': 'Annotations'}
491 _toPy = {'Annotations': 'annotations'}
492 def __init__(self, annotations=None):
493 '''
494 annotations : typing.Sequence[~EntityAnnotations]
495 '''
496 self.annotations = [EntityAnnotations.from_json(o) for o in annotations or []]
497
498
499 class EntityAnnotations(Type):
500 _toSchema = {'entitytag': 'EntityTag', 'annotations': 'Annotations'}
501 _toPy = {'Annotations': 'annotations', 'EntityTag': 'entitytag'}
502 def __init__(self, annotations=None, entitytag=None):
503 '''
504 annotations : typing.Mapping[str, str]
505 entitytag : str
506 '''
507 self.annotations = annotations
508 self.entitytag = entitytag
509
510
511 class AddApplicationUnits(Type):
512 _toSchema = {'numunits': 'NumUnits', 'applicationname': 'ApplicationName', 'placement': 'Placement'}
513 _toPy = {'NumUnits': 'numunits', 'Placement': 'placement', 'ApplicationName': 'applicationname'}
514 def __init__(self, applicationname=None, numunits=None, placement=None):
515 '''
516 applicationname : str
517 numunits : int
518 placement : typing.Sequence[~Placement]
519 '''
520 self.applicationname = applicationname
521 self.numunits = numunits
522 self.placement = [Placement.from_json(o) for o in placement or []]
523
524
525 class AddApplicationUnitsResults(Type):
526 _toSchema = {'units': 'Units'}
527 _toPy = {'Units': 'units'}
528 def __init__(self, units=None):
529 '''
530 units : typing.Sequence[str]
531 '''
532 self.units = units
533
534
535 class AddRelation(Type):
536 _toSchema = {'endpoints': 'Endpoints'}
537 _toPy = {'Endpoints': 'endpoints'}
538 def __init__(self, endpoints=None):
539 '''
540 endpoints : typing.Sequence[str]
541 '''
542 self.endpoints = endpoints
543
544
545 class AddRelationResults(Type):
546 _toSchema = {'endpoints': 'Endpoints'}
547 _toPy = {'Endpoints': 'endpoints'}
548 def __init__(self, endpoints=None):
549 '''
550 endpoints : typing.Mapping[str, ~Relation]
551 '''
552 self.endpoints = {k: Relation.from_json(v) for k, v in (endpoints or dict()).items()}
553
554
555 class ApplicationCharmRelations(Type):
556 _toSchema = {'applicationname': 'ApplicationName'}
557 _toPy = {'ApplicationName': 'applicationname'}
558 def __init__(self, applicationname=None):
559 '''
560 applicationname : str
561 '''
562 self.applicationname = applicationname
563
564
565 class ApplicationCharmRelationsResults(Type):
566 _toSchema = {'charmrelations': 'CharmRelations'}
567 _toPy = {'CharmRelations': 'charmrelations'}
568 def __init__(self, charmrelations=None):
569 '''
570 charmrelations : typing.Sequence[str]
571 '''
572 self.charmrelations = charmrelations
573
574
575 class ApplicationDeploy(Type):
576 _toSchema = {'resources': 'Resources', 'channel': 'Channel', 'numunits': 'NumUnits', 'charmurl': 'CharmUrl', 'endpointbindings': 'EndpointBindings', 'configyaml': 'ConfigYAML', 'series': 'Series', 'storage': 'Storage', 'placement': 'Placement', 'config': 'Config', 'constraints': 'Constraints', 'applicationname': 'ApplicationName'}
577 _toPy = {'Storage': 'storage', 'ApplicationName': 'applicationname', 'Channel': 'channel', 'CharmUrl': 'charmurl', 'Constraints': 'constraints', 'Config': 'config', 'ConfigYAML': 'configyaml', 'Resources': 'resources', 'EndpointBindings': 'endpointbindings', 'NumUnits': 'numunits', 'Placement': 'placement', 'Series': 'series'}
578 def __init__(self, applicationname=None, channel=None, charmurl=None, config=None, configyaml=None, constraints=None, endpointbindings=None, numunits=None, placement=None, resources=None, series=None, storage=None):
579 '''
580 applicationname : str
581 channel : str
582 charmurl : str
583 config : typing.Mapping[str, str]
584 configyaml : str
585 constraints : Value
586 endpointbindings : typing.Mapping[str, str]
587 numunits : int
588 placement : typing.Sequence[~Placement]
589 resources : typing.Mapping[str, str]
590 series : str
591 storage : typing.Mapping[str, ~Constraints]
592 '''
593 self.applicationname = applicationname
594 self.channel = channel
595 self.charmurl = charmurl
596 self.config = config
597 self.configyaml = configyaml
598 self.constraints = Value.from_json(constraints) if constraints else None
599 self.endpointbindings = endpointbindings
600 self.numunits = numunits
601 self.placement = [Placement.from_json(o) for o in placement or []]
602 self.resources = resources
603 self.series = series
604 self.storage = {k: Constraints.from_json(v) for k, v in (storage or dict()).items()}
605
606
607 class ApplicationDestroy(Type):
608 _toSchema = {'applicationname': 'ApplicationName'}
609 _toPy = {'ApplicationName': 'applicationname'}
610 def __init__(self, applicationname=None):
611 '''
612 applicationname : str
613 '''
614 self.applicationname = applicationname
615
616
617 class ApplicationExpose(Type):
618 _toSchema = {'applicationname': 'ApplicationName'}
619 _toPy = {'ApplicationName': 'applicationname'}
620 def __init__(self, applicationname=None):
621 '''
622 applicationname : str
623 '''
624 self.applicationname = applicationname
625
626
627 class ApplicationGet(Type):
628 _toSchema = {'applicationname': 'ApplicationName'}
629 _toPy = {'ApplicationName': 'applicationname'}
630 def __init__(self, applicationname=None):
631 '''
632 applicationname : str
633 '''
634 self.applicationname = applicationname
635
636
637 class ApplicationGetResults(Type):
638 _toSchema = {'charm': 'Charm', 'config': 'Config', 'application': 'Application', 'constraints': 'Constraints'}
639 _toPy = {'Constraints': 'constraints', 'Charm': 'charm', 'Application': 'application', 'Config': 'config'}
640 def __init__(self, application=None, charm=None, config=None, constraints=None):
641 '''
642 application : str
643 charm : str
644 config : typing.Mapping[str, typing.Any]
645 constraints : Value
646 '''
647 self.application = application
648 self.charm = charm
649 self.config = config
650 self.constraints = Value.from_json(constraints) if constraints else None
651
652
653 class ApplicationMetricCredential(Type):
654 _toSchema = {'metriccredentials': 'MetricCredentials', 'applicationname': 'ApplicationName'}
655 _toPy = {'MetricCredentials': 'metriccredentials', 'ApplicationName': 'applicationname'}
656 def __init__(self, applicationname=None, metriccredentials=None):
657 '''
658 applicationname : str
659 metriccredentials : typing.Sequence[int]
660 '''
661 self.applicationname = applicationname
662 self.metriccredentials = metriccredentials
663
664
665 class ApplicationMetricCredentials(Type):
666 _toSchema = {'creds': 'Creds'}
667 _toPy = {'Creds': 'creds'}
668 def __init__(self, creds=None):
669 '''
670 creds : typing.Sequence[~ApplicationMetricCredential]
671 '''
672 self.creds = [ApplicationMetricCredential.from_json(o) for o in creds or []]
673
674
675 class ApplicationSet(Type):
676 _toSchema = {'options': 'Options', 'applicationname': 'ApplicationName'}
677 _toPy = {'Options': 'options', 'ApplicationName': 'applicationname'}
678 def __init__(self, applicationname=None, options=None):
679 '''
680 applicationname : str
681 options : typing.Mapping[str, str]
682 '''
683 self.applicationname = applicationname
684 self.options = options
685
686
687 class ApplicationSetCharm(Type):
688 _toSchema = {'forceseries': 'forceseries', 'charmurl': 'charmurl', 'resourceids': 'resourceids', 'forceunits': 'forceunits', 'cs_channel': 'cs-channel', 'applicationname': 'applicationname'}
689 _toPy = {'forceseries': 'forceseries', 'charmurl': 'charmurl', 'forceunits': 'forceunits', 'cs-channel': 'cs_channel', 'applicationname': 'applicationname', 'resourceids': 'resourceids'}
690 def __init__(self, applicationname=None, charmurl=None, cs_channel=None, forceseries=None, forceunits=None, resourceids=None):
691 '''
692 applicationname : str
693 charmurl : str
694 cs_channel : str
695 forceseries : bool
696 forceunits : bool
697 resourceids : typing.Mapping[str, str]
698 '''
699 self.applicationname = applicationname
700 self.charmurl = charmurl
701 self.cs_channel = cs_channel
702 self.forceseries = forceseries
703 self.forceunits = forceunits
704 self.resourceids = resourceids
705
706
707 class ApplicationUnexpose(Type):
708 _toSchema = {'applicationname': 'ApplicationName'}
709 _toPy = {'ApplicationName': 'applicationname'}
710 def __init__(self, applicationname=None):
711 '''
712 applicationname : str
713 '''
714 self.applicationname = applicationname
715
716
717 class ApplicationUnset(Type):
718 _toSchema = {'options': 'Options', 'applicationname': 'ApplicationName'}
719 _toPy = {'Options': 'options', 'ApplicationName': 'applicationname'}
720 def __init__(self, applicationname=None, options=None):
721 '''
722 applicationname : str
723 options : typing.Sequence[str]
724 '''
725 self.applicationname = applicationname
726 self.options = options
727
728
729 class ApplicationUpdate(Type):
730 _toSchema = {'forceseries': 'ForceSeries', 'charmurl': 'CharmUrl', 'settingsyaml': 'SettingsYAML', 'constraints': 'Constraints', 'forcecharmurl': 'ForceCharmUrl', 'settingsstrings': 'SettingsStrings', 'applicationname': 'ApplicationName', 'minunits': 'MinUnits'}
731 _toPy = {'Constraints': 'constraints', 'SettingsYAML': 'settingsyaml', 'SettingsStrings': 'settingsstrings', 'ApplicationName': 'applicationname', 'MinUnits': 'minunits', 'ForceCharmUrl': 'forcecharmurl', 'CharmUrl': 'charmurl', 'ForceSeries': 'forceseries'}
732 def __init__(self, applicationname=None, charmurl=None, constraints=None, forcecharmurl=None, forceseries=None, minunits=None, settingsstrings=None, settingsyaml=None):
733 '''
734 applicationname : str
735 charmurl : str
736 constraints : Value
737 forcecharmurl : bool
738 forceseries : bool
739 minunits : int
740 settingsstrings : typing.Mapping[str, str]
741 settingsyaml : str
742 '''
743 self.applicationname = applicationname
744 self.charmurl = charmurl
745 self.constraints = Value.from_json(constraints) if constraints else None
746 self.forcecharmurl = forcecharmurl
747 self.forceseries = forceseries
748 self.minunits = minunits
749 self.settingsstrings = settingsstrings
750 self.settingsyaml = settingsyaml
751
752
753 class ApplicationsDeploy(Type):
754 _toSchema = {'applications': 'Applications'}
755 _toPy = {'Applications': 'applications'}
756 def __init__(self, applications=None):
757 '''
758 applications : typing.Sequence[~ApplicationDeploy]
759 '''
760 self.applications = [ApplicationDeploy.from_json(o) for o in applications or []]
761
762
763 class Constraints(Type):
764 _toSchema = {'pool': 'Pool', 'size': 'Size', 'count': 'Count'}
765 _toPy = {'Count': 'count', 'Pool': 'pool', 'Size': 'size'}
766 def __init__(self, count=None, pool=None, size=None):
767 '''
768 count : int
769 pool : str
770 size : int
771 '''
772 self.count = count
773 self.pool = pool
774 self.size = size
775
776
777 class DestroyApplicationUnits(Type):
778 _toSchema = {'unitnames': 'UnitNames'}
779 _toPy = {'UnitNames': 'unitnames'}
780 def __init__(self, unitnames=None):
781 '''
782 unitnames : typing.Sequence[str]
783 '''
784 self.unitnames = unitnames
785
786
787 class DestroyRelation(Type):
788 _toSchema = {'endpoints': 'Endpoints'}
789 _toPy = {'Endpoints': 'endpoints'}
790 def __init__(self, endpoints=None):
791 '''
792 endpoints : typing.Sequence[str]
793 '''
794 self.endpoints = endpoints
795
796
797 class GetApplicationConstraints(Type):
798 _toSchema = {'applicationname': 'ApplicationName'}
799 _toPy = {'ApplicationName': 'applicationname'}
800 def __init__(self, applicationname=None):
801 '''
802 applicationname : str
803 '''
804 self.applicationname = applicationname
805
806
807 class GetConstraintsResults(Type):
808 _toSchema = {'root_disk': 'root-disk', 'mem': 'mem', 'container': 'container', 'virt_type': 'virt-type', 'cpu_power': 'cpu-power', 'cpu_cores': 'cpu-cores', 'tags': 'tags', 'arch': 'arch', 'spaces': 'spaces', 'instance_type': 'instance-type'}
809 _toPy = {'spaces': 'spaces', 'container': 'container', 'cpu-cores': 'cpu_cores', 'instance-type': 'instance_type', 'mem': 'mem', 'cpu-power': 'cpu_power', 'tags': 'tags', 'arch': 'arch', 'root-disk': 'root_disk', 'virt-type': 'virt_type'}
810 def __init__(self, arch=None, container=None, cpu_cores=None, cpu_power=None, instance_type=None, mem=None, root_disk=None, spaces=None, tags=None, virt_type=None):
811 '''
812 arch : str
813 container : str
814 cpu_cores : int
815 cpu_power : int
816 instance_type : str
817 mem : int
818 root_disk : int
819 spaces : typing.Sequence[str]
820 tags : typing.Sequence[str]
821 virt_type : str
822 '''
823 self.arch = arch
824 self.container = container
825 self.cpu_cores = cpu_cores
826 self.cpu_power = cpu_power
827 self.instance_type = instance_type
828 self.mem = mem
829 self.root_disk = root_disk
830 self.spaces = spaces
831 self.tags = tags
832 self.virt_type = virt_type
833
834
835 class Placement(Type):
836 _toSchema = {'directive': 'Directive', 'scope': 'Scope'}
837 _toPy = {'Directive': 'directive', 'Scope': 'scope'}
838 def __init__(self, directive=None, scope=None):
839 '''
840 directive : str
841 scope : str
842 '''
843 self.directive = directive
844 self.scope = scope
845
846
847 class Relation(Type):
848 _toSchema = {'role': 'Role', 'limit': 'Limit', 'optional': 'Optional', 'name': 'Name', 'scope': 'Scope', 'interface': 'Interface'}
849 _toPy = {'Name': 'name', 'Role': 'role', 'Scope': 'scope', 'Limit': 'limit', 'Interface': 'interface', 'Optional': 'optional'}
850 def __init__(self, interface=None, limit=None, name=None, optional=None, role=None, scope=None):
851 '''
852 interface : str
853 limit : int
854 name : str
855 optional : bool
856 role : str
857 scope : str
858 '''
859 self.interface = interface
860 self.limit = limit
861 self.name = name
862 self.optional = optional
863 self.role = role
864 self.scope = scope
865
866
867 class SetConstraints(Type):
868 _toSchema = {'constraints': 'Constraints', 'applicationname': 'ApplicationName'}
869 _toPy = {'Constraints': 'constraints', 'ApplicationName': 'applicationname'}
870 def __init__(self, applicationname=None, constraints=None):
871 '''
872 applicationname : str
873 constraints : Value
874 '''
875 self.applicationname = applicationname
876 self.constraints = Value.from_json(constraints) if constraints else None
877
878
879 class StringResult(Type):
880 _toSchema = {'result': 'Result', 'error': 'Error'}
881 _toPy = {'Result': 'result', 'Error': 'error'}
882 def __init__(self, error=None, result=None):
883 '''
884 error : Error
885 result : str
886 '''
887 self.error = Error.from_json(error) if error else None
888 self.result = result
889
890
891 class Value(Type):
892 _toSchema = {'root_disk': 'root-disk', 'mem': 'mem', 'container': 'container', 'virt_type': 'virt-type', 'cpu_power': 'cpu-power', 'cpu_cores': 'cpu-cores', 'tags': 'tags', 'arch': 'arch', 'spaces': 'spaces', 'instance_type': 'instance-type'}
893 _toPy = {'spaces': 'spaces', 'container': 'container', 'cpu-cores': 'cpu_cores', 'instance-type': 'instance_type', 'mem': 'mem', 'cpu-power': 'cpu_power', 'tags': 'tags', 'arch': 'arch', 'root-disk': 'root_disk', 'virt-type': 'virt_type'}
894 def __init__(self, arch=None, container=None, cpu_cores=None, cpu_power=None, instance_type=None, mem=None, root_disk=None, spaces=None, tags=None, virt_type=None):
895 '''
896 arch : str
897 container : str
898 cpu_cores : int
899 cpu_power : int
900 instance_type : str
901 mem : int
902 root_disk : int
903 spaces : typing.Sequence[str]
904 tags : typing.Sequence[str]
905 virt_type : str
906 '''
907 self.arch = arch
908 self.container = container
909 self.cpu_cores = cpu_cores
910 self.cpu_power = cpu_power
911 self.instance_type = instance_type
912 self.mem = mem
913 self.root_disk = root_disk
914 self.spaces = spaces
915 self.tags = tags
916 self.virt_type = virt_type
917
918
919 class StringsWatchResult(Type):
920 _toSchema = {'changes': 'Changes', 'stringswatcherid': 'StringsWatcherId', 'error': 'Error'}
921 _toPy = {'Changes': 'changes', 'Error': 'error', 'StringsWatcherId': 'stringswatcherid'}
922 def __init__(self, changes=None, error=None, stringswatcherid=None):
923 '''
924 changes : typing.Sequence[str]
925 error : Error
926 stringswatcherid : str
927 '''
928 self.changes = changes
929 self.error = Error.from_json(error) if error else None
930 self.stringswatcherid = stringswatcherid
931
932
933 class BackupsCreateArgs(Type):
934 _toSchema = {'notes': 'Notes'}
935 _toPy = {'Notes': 'notes'}
936 def __init__(self, notes=None):
937 '''
938 notes : str
939 '''
940 self.notes = notes
941
942
943 class BackupsInfoArgs(Type):
944 _toSchema = {'id_': 'ID'}
945 _toPy = {'ID': 'id_'}
946 def __init__(self, id_=None):
947 '''
948 id_ : str
949 '''
950 self.id_ = id_
951
952
953 class BackupsListArgs(Type):
954 _toSchema = {}
955 _toPy = {}
956 def __init__(self):
957 '''
958
959 '''
960 pass
961
962
963 class BackupsListResult(Type):
964 _toSchema = {'list_': 'List'}
965 _toPy = {'List': 'list_'}
966 def __init__(self, list_=None):
967 '''
968 list_ : typing.Sequence[~BackupsMetadataResult]
969 '''
970 self.list_ = [BackupsMetadataResult.from_json(o) for o in list_ or []]
971
972
973 class BackupsMetadataResult(Type):
974 _toSchema = {'checksumformat': 'ChecksumFormat', 'started': 'Started', 'stored': 'Stored', 'cacert': 'CACert', 'version': 'Version', 'machine': 'Machine', 'checksum': 'Checksum', 'series': 'Series', 'id_': 'ID', 'hostname': 'Hostname', 'size': 'Size', 'finished': 'Finished', 'caprivatekey': 'CAPrivateKey', 'model': 'Model', 'notes': 'Notes'}
975 _toPy = {'Finished': 'finished', 'ChecksumFormat': 'checksumformat', 'CAPrivateKey': 'caprivatekey', 'Started': 'started', 'ID': 'id_', 'Notes': 'notes', 'Stored': 'stored', 'Hostname': 'hostname', 'Model': 'model', 'Size': 'size', 'Checksum': 'checksum', 'Machine': 'machine', 'Version': 'version', 'CACert': 'cacert', 'Series': 'series'}
976 def __init__(self, cacert=None, caprivatekey=None, checksum=None, checksumformat=None, finished=None, hostname=None, id_=None, machine=None, model=None, notes=None, series=None, size=None, started=None, stored=None, version=None):
977 '''
978 cacert : str
979 caprivatekey : str
980 checksum : str
981 checksumformat : str
982 finished : str
983 hostname : str
984 id_ : str
985 machine : str
986 model : str
987 notes : str
988 series : str
989 size : int
990 started : str
991 stored : str
992 version : Number
993 '''
994 self.cacert = cacert
995 self.caprivatekey = caprivatekey
996 self.checksum = checksum
997 self.checksumformat = checksumformat
998 self.finished = finished
999 self.hostname = hostname
1000 self.id_ = id_
1001 self.machine = machine
1002 self.model = model
1003 self.notes = notes
1004 self.series = series
1005 self.size = size
1006 self.started = started
1007 self.stored = stored
1008 self.version = Number.from_json(version) if version else None
1009
1010
1011 class BackupsRemoveArgs(Type):
1012 _toSchema = {'id_': 'ID'}
1013 _toPy = {'ID': 'id_'}
1014 def __init__(self, id_=None):
1015 '''
1016 id_ : str
1017 '''
1018 self.id_ = id_
1019
1020
1021 class Number(Type):
1022 _toSchema = {'minor': 'Minor', 'major': 'Major', 'patch': 'Patch', 'tag': 'Tag', 'build': 'Build'}
1023 _toPy = {'Patch': 'patch', 'Major': 'major', 'Minor': 'minor', 'Tag': 'tag', 'Build': 'build'}
1024 def __init__(self, build=None, major=None, minor=None, patch=None, tag=None):
1025 '''
1026 build : int
1027 major : int
1028 minor : int
1029 patch : int
1030 tag : str
1031 '''
1032 self.build = build
1033 self.major = major
1034 self.minor = minor
1035 self.patch = patch
1036 self.tag = tag
1037
1038
1039 class RestoreArgs(Type):
1040 _toSchema = {'backupid': 'BackupId'}
1041 _toPy = {'BackupId': 'backupid'}
1042 def __init__(self, backupid=None):
1043 '''
1044 backupid : str
1045 '''
1046 self.backupid = backupid
1047
1048
1049 class Block(Type):
1050 _toSchema = {'type_': 'type', 'id_': 'id', 'message': 'message', 'tag': 'tag'}
1051 _toPy = {'type': 'type_', 'id': 'id_', 'message': 'message', 'tag': 'tag'}
1052 def __init__(self, id_=None, message=None, tag=None, type_=None):
1053 '''
1054 id_ : str
1055 message : str
1056 tag : str
1057 type_ : str
1058 '''
1059 self.id_ = id_
1060 self.message = message
1061 self.tag = tag
1062 self.type_ = type_
1063
1064
1065 class BlockResult(Type):
1066 _toSchema = {'result': 'result', 'error': 'error'}
1067 _toPy = {'result': 'result', 'error': 'error'}
1068 def __init__(self, error=None, result=None):
1069 '''
1070 error : Error
1071 result : Block
1072 '''
1073 self.error = Error.from_json(error) if error else None
1074 self.result = Block.from_json(result) if result else None
1075
1076
1077 class BlockResults(Type):
1078 _toSchema = {'results': 'results'}
1079 _toPy = {'results': 'results'}
1080 def __init__(self, results=None):
1081 '''
1082 results : typing.Sequence[~BlockResult]
1083 '''
1084 self.results = [BlockResult.from_json(o) for o in results or []]
1085
1086
1087 class BlockSwitchParams(Type):
1088 _toSchema = {'type_': 'type', 'message': 'message'}
1089 _toPy = {'type': 'type_', 'message': 'message'}
1090 def __init__(self, message=None, type_=None):
1091 '''
1092 message : str
1093 type_ : str
1094 '''
1095 self.message = message
1096 self.type_ = type_
1097
1098
1099 class CharmInfo(Type):
1100 _toSchema = {'charmurl': 'CharmURL'}
1101 _toPy = {'CharmURL': 'charmurl'}
1102 def __init__(self, charmurl=None):
1103 '''
1104 charmurl : str
1105 '''
1106 self.charmurl = charmurl
1107
1108
1109 class CharmsList(Type):
1110 _toSchema = {'names': 'Names'}
1111 _toPy = {'Names': 'names'}
1112 def __init__(self, names=None):
1113 '''
1114 names : typing.Sequence[str]
1115 '''
1116 self.names = names
1117
1118
1119 class CharmsListResult(Type):
1120 _toSchema = {'charmurls': 'CharmURLs'}
1121 _toPy = {'CharmURLs': 'charmurls'}
1122 def __init__(self, charmurls=None):
1123 '''
1124 charmurls : typing.Sequence[str]
1125 '''
1126 self.charmurls = charmurls
1127
1128
1129 class IsMeteredResult(Type):
1130 _toSchema = {'metered': 'Metered'}
1131 _toPy = {'Metered': 'metered'}
1132 def __init__(self, metered=None):
1133 '''
1134 metered : bool
1135 '''
1136 self.metered = metered
1137
1138
1139 class APIHostPortsResult(Type):
1140 _toSchema = {'servers': 'Servers'}
1141 _toPy = {'Servers': 'servers'}
1142 def __init__(self, servers=None):
1143 '''
1144 servers : typing.Sequence[~HostPort]
1145 '''
1146 self.servers = [HostPort.from_json(o) for o in servers or []]
1147
1148
1149 class AddCharm(Type):
1150 _toSchema = {'url': 'URL', 'channel': 'Channel'}
1151 _toPy = {'URL': 'url', 'Channel': 'channel'}
1152 def __init__(self, channel=None, url=None):
1153 '''
1154 channel : str
1155 url : str
1156 '''
1157 self.channel = channel
1158 self.url = url
1159
1160
1161 class AddCharmWithAuthorization(Type):
1162 _toSchema = {'url': 'URL', 'channel': 'Channel', 'charmstoremacaroon': 'CharmStoreMacaroon'}
1163 _toPy = {'URL': 'url', 'CharmStoreMacaroon': 'charmstoremacaroon', 'Channel': 'channel'}
1164 def __init__(self, channel=None, charmstoremacaroon=None, url=None):
1165 '''
1166 channel : str
1167 charmstoremacaroon : Macaroon
1168 url : str
1169 '''
1170 self.channel = channel
1171 self.charmstoremacaroon = Macaroon.from_json(charmstoremacaroon) if charmstoremacaroon else None
1172 self.url = url
1173
1174
1175 class AddMachineParams(Type):
1176 _toSchema = {'jobs': 'Jobs', 'series': 'Series', 'hardwarecharacteristics': 'HardwareCharacteristics', 'nonce': 'Nonce', 'containertype': 'ContainerType', 'constraints': 'Constraints', 'disks': 'Disks', 'placement': 'Placement', 'instanceid': 'InstanceId', 'parentid': 'ParentId', 'addrs': 'Addrs'}
1177 _toPy = {'Constraints': 'constraints', 'InstanceId': 'instanceid', 'ContainerType': 'containertype', 'Nonce': 'nonce', 'Disks': 'disks', 'Addrs': 'addrs', 'HardwareCharacteristics': 'hardwarecharacteristics', 'Series': 'series', 'ParentId': 'parentid', 'Placement': 'placement', 'Jobs': 'jobs'}
1178 def __init__(self, addrs=None, constraints=None, containertype=None, disks=None, hardwarecharacteristics=None, instanceid=None, jobs=None, nonce=None, parentid=None, placement=None, series=None):
1179 '''
1180 addrs : typing.Sequence[~Address]
1181 constraints : Value
1182 containertype : str
1183 disks : typing.Sequence[~Constraints]
1184 hardwarecharacteristics : HardwareCharacteristics
1185 instanceid : str
1186 jobs : typing.Sequence[str]
1187 nonce : str
1188 parentid : str
1189 placement : Placement
1190 series : str
1191 '''
1192 self.addrs = [Address.from_json(o) for o in addrs or []]
1193 self.constraints = Value.from_json(constraints) if constraints else None
1194 self.containertype = containertype
1195 self.disks = [Constraints.from_json(o) for o in disks or []]
1196 self.hardwarecharacteristics = HardwareCharacteristics.from_json(hardwarecharacteristics) if hardwarecharacteristics else None
1197 self.instanceid = instanceid
1198 self.jobs = jobs
1199 self.nonce = nonce
1200 self.parentid = parentid
1201 self.placement = Placement.from_json(placement) if placement else None
1202 self.series = series
1203
1204
1205 class AddMachines(Type):
1206 _toSchema = {'machineparams': 'MachineParams'}
1207 _toPy = {'MachineParams': 'machineparams'}
1208 def __init__(self, machineparams=None):
1209 '''
1210 machineparams : typing.Sequence[~AddMachineParams]
1211 '''
1212 self.machineparams = [AddMachineParams.from_json(o) for o in machineparams or []]
1213
1214
1215 class AddMachinesResult(Type):
1216 _toSchema = {'error': 'Error', 'machine': 'Machine'}
1217 _toPy = {'Error': 'error', 'Machine': 'machine'}
1218 def __init__(self, error=None, machine=None):
1219 '''
1220 error : Error
1221 machine : str
1222 '''
1223 self.error = Error.from_json(error) if error else None
1224 self.machine = machine
1225
1226
1227 class AddMachinesResults(Type):
1228 _toSchema = {'machines': 'Machines'}
1229 _toPy = {'Machines': 'machines'}
1230 def __init__(self, machines=None):
1231 '''
1232 machines : typing.Sequence[~AddMachinesResult]
1233 '''
1234 self.machines = [AddMachinesResult.from_json(o) for o in machines or []]
1235
1236
1237 class Address(Type):
1238 _toSchema = {'value': 'Value', 'type_': 'Type', 'spacename': 'SpaceName', 'scope': 'Scope'}
1239 _toPy = {'Value': 'value', 'Type': 'type_', 'SpaceName': 'spacename', 'Scope': 'scope'}
1240 def __init__(self, scope=None, spacename=None, type_=None, value=None):
1241 '''
1242 scope : str
1243 spacename : str
1244 type_ : str
1245 value : str
1246 '''
1247 self.scope = scope
1248 self.spacename = spacename
1249 self.type_ = type_
1250 self.value = value
1251
1252
1253 class AgentVersionResult(Type):
1254 _toSchema = {'minor': 'Minor', 'major': 'Major', 'patch': 'Patch', 'tag': 'Tag', 'build': 'Build'}
1255 _toPy = {'Patch': 'patch', 'Major': 'major', 'Minor': 'minor', 'Tag': 'tag', 'Build': 'build'}
1256 def __init__(self, build=None, major=None, minor=None, patch=None, tag=None):
1257 '''
1258 build : int
1259 major : int
1260 minor : int
1261 patch : int
1262 tag : str
1263 '''
1264 self.build = build
1265 self.major = major
1266 self.minor = minor
1267 self.patch = patch
1268 self.tag = tag
1269
1270
1271 class AllWatcherId(Type):
1272 _toSchema = {'allwatcherid': 'AllWatcherId'}
1273 _toPy = {'AllWatcherId': 'allwatcherid'}
1274 def __init__(self, allwatcherid=None):
1275 '''
1276 allwatcherid : str
1277 '''
1278 self.allwatcherid = allwatcherid
1279
1280
1281 class ApplicationStatus(Type):
1282 _toSchema = {'charm': 'Charm', 'exposed': 'Exposed', 'err': 'Err', 'meterstatuses': 'MeterStatuses', 'relations': 'Relations', 'units': 'Units', 'life': 'Life', 'canupgradeto': 'CanUpgradeTo', 'subordinateto': 'SubordinateTo', 'status': 'Status'}
1283 _toPy = {'Charm': 'charm', 'Err': 'err', 'Units': 'units', 'MeterStatuses': 'meterstatuses', 'CanUpgradeTo': 'canupgradeto', 'Status': 'status', 'SubordinateTo': 'subordinateto', 'Life': 'life', 'Relations': 'relations', 'Exposed': 'exposed'}
1284 def __init__(self, canupgradeto=None, charm=None, err=None, exposed=None, life=None, meterstatuses=None, relations=None, status=None, subordinateto=None, units=None):
1285 '''
1286 canupgradeto : str
1287 charm : str
1288 err : typing.Mapping[str, typing.Any]
1289 exposed : bool
1290 life : str
1291 meterstatuses : typing.Mapping[str, ~MeterStatus]
1292 relations : typing.Sequence[str]
1293 status : DetailedStatus
1294 subordinateto : typing.Sequence[str]
1295 units : typing.Mapping[str, ~UnitStatus]
1296 '''
1297 self.canupgradeto = canupgradeto
1298 self.charm = charm
1299 self.err = err
1300 self.exposed = exposed
1301 self.life = life
1302 self.meterstatuses = {k: MeterStatus.from_json(v) for k, v in (meterstatuses or dict()).items()}
1303 self.relations = relations
1304 self.status = DetailedStatus.from_json(status) if status else None
1305 self.subordinateto = subordinateto
1306 self.units = {k: UnitStatus.from_json(v) for k, v in (units or dict()).items()}
1307
1308
1309 class Binary(Type):
1310 _toSchema = {'number': 'Number', 'series': 'Series', 'arch': 'Arch'}
1311 _toPy = {'Number': 'number', 'Arch': 'arch', 'Series': 'series'}
1312 def __init__(self, arch=None, number=None, series=None):
1313 '''
1314 arch : str
1315 number : Number
1316 series : str
1317 '''
1318 self.arch = arch
1319 self.number = Number.from_json(number) if number else None
1320 self.series = series
1321
1322
1323 class BundleChangesChange(Type):
1324 _toSchema = {'method': 'method', 'args': 'args', 'requires': 'requires', 'id_': 'id'}
1325 _toPy = {'method': 'method', 'id': 'id_', 'args': 'args', 'requires': 'requires'}
1326 def __init__(self, args=None, id_=None, method=None, requires=None):
1327 '''
1328 args : typing.Sequence[typing.Any]
1329 id_ : str
1330 method : str
1331 requires : typing.Sequence[str]
1332 '''
1333 self.args = args
1334 self.id_ = id_
1335 self.method = method
1336 self.requires = requires
1337
1338
1339 class DestroyMachines(Type):
1340 _toSchema = {'force': 'Force', 'machinenames': 'MachineNames'}
1341 _toPy = {'Force': 'force', 'MachineNames': 'machinenames'}
1342 def __init__(self, force=None, machinenames=None):
1343 '''
1344 force : bool
1345 machinenames : typing.Sequence[str]
1346 '''
1347 self.force = force
1348 self.machinenames = machinenames
1349
1350
1351 class DetailedStatus(Type):
1352 _toSchema = {'since': 'Since', 'data': 'Data', 'life': 'Life', 'version': 'Version', 'err': 'Err', 'kind': 'Kind', 'info': 'Info', 'status': 'Status'}
1353 _toPy = {'Err': 'err', 'Data': 'data', 'Since': 'since', 'Status': 'status', 'Info': 'info', 'Life': 'life', 'Version': 'version', 'Kind': 'kind'}
1354 def __init__(self, data=None, err=None, info=None, kind=None, life=None, since=None, status=None, version=None):
1355 '''
1356 data : typing.Mapping[str, typing.Any]
1357 err : typing.Mapping[str, typing.Any]
1358 info : str
1359 kind : str
1360 life : str
1361 since : str
1362 status : str
1363 version : str
1364 '''
1365 self.data = data
1366 self.err = err
1367 self.info = info
1368 self.kind = kind
1369 self.life = life
1370 self.since = since
1371 self.status = status
1372 self.version = version
1373
1374
1375 class EndpointStatus(Type):
1376 _toSchema = {'role': 'Role', 'subordinate': 'Subordinate', 'applicationname': 'ApplicationName', 'name': 'Name'}
1377 _toPy = {'Subordinate': 'subordinate', 'Name': 'name', 'Role': 'role', 'ApplicationName': 'applicationname'}
1378 def __init__(self, applicationname=None, name=None, role=None, subordinate=None):
1379 '''
1380 applicationname : str
1381 name : str
1382 role : str
1383 subordinate : bool
1384 '''
1385 self.applicationname = applicationname
1386 self.name = name
1387 self.role = role
1388 self.subordinate = subordinate
1389
1390
1391 class EntityStatus(Type):
1392 _toSchema = {'since': 'Since', 'data': 'Data', 'info': 'Info', 'status': 'Status'}
1393 _toPy = {'Since': 'since', 'Status': 'status', 'Data': 'data', 'Info': 'info'}
1394 def __init__(self, data=None, info=None, since=None, status=None):
1395 '''
1396 data : typing.Mapping[str, typing.Any]
1397 info : str
1398 since : str
1399 status : str
1400 '''
1401 self.data = data
1402 self.info = info
1403 self.since = since
1404 self.status = status
1405
1406
1407 class FindToolsParams(Type):
1408 _toSchema = {'minorversion': 'MinorVersion', 'number': 'Number', 'series': 'Series', 'arch': 'Arch', 'majorversion': 'MajorVersion'}
1409 _toPy = {'Number': 'number', 'Series': 'series', 'Arch': 'arch', 'MinorVersion': 'minorversion', 'MajorVersion': 'majorversion'}
1410 def __init__(self, arch=None, majorversion=None, minorversion=None, number=None, series=None):
1411 '''
1412 arch : str
1413 majorversion : int
1414 minorversion : int
1415 number : Number
1416 series : str
1417 '''
1418 self.arch = arch
1419 self.majorversion = majorversion
1420 self.minorversion = minorversion
1421 self.number = Number.from_json(number) if number else None
1422 self.series = series
1423
1424
1425 class FindToolsResult(Type):
1426 _toSchema = {'error': 'Error', 'list_': 'List'}
1427 _toPy = {'List': 'list_', 'Error': 'error'}
1428 def __init__(self, error=None, list_=None):
1429 '''
1430 error : Error
1431 list_ : typing.Sequence[~Tools]
1432 '''
1433 self.error = Error.from_json(error) if error else None
1434 self.list_ = [Tools.from_json(o) for o in list_ or []]
1435
1436
1437 class FullStatus(Type):
1438 _toSchema = {'modelname': 'ModelName', 'availableversion': 'AvailableVersion', 'applications': 'Applications', 'relations': 'Relations', 'machines': 'Machines'}
1439 _toPy = {'Applications': 'applications', 'Machines': 'machines', 'AvailableVersion': 'availableversion', 'ModelName': 'modelname', 'Relations': 'relations'}
1440 def __init__(self, applications=None, availableversion=None, machines=None, modelname=None, relations=None):
1441 '''
1442 applications : typing.Mapping[str, ~ApplicationStatus]
1443 availableversion : str
1444 machines : typing.Mapping[str, ~MachineStatus]
1445 modelname : str
1446 relations : typing.Sequence[~RelationStatus]
1447 '''
1448 self.applications = {k: ApplicationStatus.from_json(v) for k, v in (applications or dict()).items()}
1449 self.availableversion = availableversion
1450 self.machines = {k: MachineStatus.from_json(v) for k, v in (machines or dict()).items()}
1451 self.modelname = modelname
1452 self.relations = [RelationStatus.from_json(o) for o in relations or []]
1453
1454
1455 class GetBundleChangesParams(Type):
1456 _toSchema = {'yaml': 'yaml'}
1457 _toPy = {'yaml': 'yaml'}
1458 def __init__(self, yaml=None):
1459 '''
1460 yaml : str
1461 '''
1462 self.yaml = yaml
1463
1464
1465 class GetBundleChangesResults(Type):
1466 _toSchema = {'changes': 'changes', 'errors': 'errors'}
1467 _toPy = {'changes': 'changes', 'errors': 'errors'}
1468 def __init__(self, changes=None, errors=None):
1469 '''
1470 changes : typing.Sequence[~BundleChangesChange]
1471 errors : typing.Sequence[str]
1472 '''
1473 self.changes = [BundleChangesChange.from_json(o) for o in changes or []]
1474 self.errors = errors
1475
1476
1477 class HardwareCharacteristics(Type):
1478 _toSchema = {'rootdisk': 'RootDisk', 'cpucores': 'CpuCores', 'mem': 'Mem', 'tags': 'Tags', 'arch': 'Arch', 'availabilityzone': 'AvailabilityZone', 'cpupower': 'CpuPower'}
1479 _toPy = {'CpuPower': 'cpupower', 'RootDisk': 'rootdisk', 'AvailabilityZone': 'availabilityzone', 'Mem': 'mem', 'CpuCores': 'cpucores', 'Tags': 'tags', 'Arch': 'arch'}
1480 def __init__(self, arch=None, availabilityzone=None, cpucores=None, cpupower=None, mem=None, rootdisk=None, tags=None):
1481 '''
1482 arch : str
1483 availabilityzone : str
1484 cpucores : int
1485 cpupower : int
1486 mem : int
1487 rootdisk : int
1488 tags : typing.Sequence[str]
1489 '''
1490 self.arch = arch
1491 self.availabilityzone = availabilityzone
1492 self.cpucores = cpucores
1493 self.cpupower = cpupower
1494 self.mem = mem
1495 self.rootdisk = rootdisk
1496 self.tags = tags
1497
1498
1499 class History(Type):
1500 _toSchema = {'error': 'Error', 'statuses': 'Statuses'}
1501 _toPy = {'Error': 'error', 'Statuses': 'statuses'}
1502 def __init__(self, error=None, statuses=None):
1503 '''
1504 error : Error
1505 statuses : typing.Sequence[~DetailedStatus]
1506 '''
1507 self.error = Error.from_json(error) if error else None
1508 self.statuses = [DetailedStatus.from_json(o) for o in statuses or []]
1509
1510
1511 class HostPort(Type):
1512 _toSchema = {'address': 'Address', 'port': 'Port'}
1513 _toPy = {'Port': 'port', 'Address': 'address'}
1514 def __init__(self, address=None, port=None):
1515 '''
1516 address : Address
1517 port : int
1518 '''
1519 self.address = Address.from_json(address) if address else None
1520 self.port = port
1521
1522
1523 class MachineStatus(Type):
1524 _toSchema = {'dnsname': 'DNSName', 'hardware': 'Hardware', 'series': 'Series', 'id_': 'Id', 'hasvote': 'HasVote', 'jobs': 'Jobs', 'containers': 'Containers', 'agentstatus': 'AgentStatus', 'instanceid': 'InstanceId', 'wantsvote': 'WantsVote', 'instancestatus': 'InstanceStatus'}
1525 _toPy = {'AgentStatus': 'agentstatus', 'InstanceId': 'instanceid', 'Hardware': 'hardware', 'HasVote': 'hasvote', 'Containers': 'containers', 'Id': 'id_', 'WantsVote': 'wantsvote', 'Series': 'series', 'DNSName': 'dnsname', 'InstanceStatus': 'instancestatus', 'Jobs': 'jobs'}
1526 def __init__(self, agentstatus=None, containers=None, dnsname=None, hardware=None, hasvote=None, id_=None, instanceid=None, instancestatus=None, jobs=None, series=None, wantsvote=None):
1527 '''
1528 agentstatus : DetailedStatus
1529 containers : typing.Mapping[str, ~MachineStatus]
1530 dnsname : str
1531 hardware : str
1532 hasvote : bool
1533 id_ : str
1534 instanceid : str
1535 instancestatus : DetailedStatus
1536 jobs : typing.Sequence[str]
1537 series : str
1538 wantsvote : bool
1539 '''
1540 self.agentstatus = DetailedStatus.from_json(agentstatus) if agentstatus else None
1541 self.containers = {k: MachineStatus.from_json(v) for k, v in (containers or dict()).items()}
1542 self.dnsname = dnsname
1543 self.hardware = hardware
1544 self.hasvote = hasvote
1545 self.id_ = id_
1546 self.instanceid = instanceid
1547 self.instancestatus = DetailedStatus.from_json(instancestatus) if instancestatus else None
1548 self.jobs = jobs
1549 self.series = series
1550 self.wantsvote = wantsvote
1551
1552
1553 class MeterStatus(Type):
1554 _toSchema = {'color': 'Color', 'message': 'Message'}
1555 _toPy = {'Message': 'message', 'Color': 'color'}
1556 def __init__(self, color=None, message=None):
1557 '''
1558 color : str
1559 message : str
1560 '''
1561 self.color = color
1562 self.message = message
1563
1564
1565 class ModelConfigResults(Type):
1566 _toSchema = {'config': 'Config'}
1567 _toPy = {'Config': 'config'}
1568 def __init__(self, config=None):
1569 '''
1570 config : typing.Mapping[str, typing.Any]
1571 '''
1572 self.config = config
1573
1574
1575 class ModelInfo(Type):
1576 _toSchema = {'uuid': 'UUID', 'cloud': 'Cloud', 'life': 'Life', 'users': 'Users', 'name': 'Name', 'serveruuid': 'ServerUUID', 'defaultseries': 'DefaultSeries', 'ownertag': 'OwnerTag', 'providertype': 'ProviderType', 'status': 'Status'}
1577 _toPy = {'OwnerTag': 'ownertag', 'Cloud': 'cloud', 'DefaultSeries': 'defaultseries', 'Name': 'name', 'UUID': 'uuid', 'Status': 'status', 'ServerUUID': 'serveruuid', 'Users': 'users', 'Life': 'life', 'ProviderType': 'providertype'}
1578 def __init__(self, cloud=None, defaultseries=None, life=None, name=None, ownertag=None, providertype=None, serveruuid=None, status=None, uuid=None, users=None):
1579 '''
1580 cloud : str
1581 defaultseries : str
1582 life : str
1583 name : str
1584 ownertag : str
1585 providertype : str
1586 serveruuid : str
1587 status : EntityStatus
1588 uuid : str
1589 users : typing.Sequence[~ModelUserInfo]
1590 '''
1591 self.cloud = cloud
1592 self.defaultseries = defaultseries
1593 self.life = life
1594 self.name = name
1595 self.ownertag = ownertag
1596 self.providertype = providertype
1597 self.serveruuid = serveruuid
1598 self.status = EntityStatus.from_json(status) if status else None
1599 self.uuid = uuid
1600 self.users = [ModelUserInfo.from_json(o) for o in users or []]
1601
1602
1603 class ModelSet(Type):
1604 _toSchema = {'config': 'Config'}
1605 _toPy = {'Config': 'config'}
1606 def __init__(self, config=None):
1607 '''
1608 config : typing.Mapping[str, typing.Any]
1609 '''
1610 self.config = config
1611
1612
1613 class ModelUnset(Type):
1614 _toSchema = {'keys': 'Keys'}
1615 _toPy = {'Keys': 'keys'}
1616 def __init__(self, keys=None):
1617 '''
1618 keys : typing.Sequence[str]
1619 '''
1620 self.keys = keys
1621
1622
1623 class ModelUserInfo(Type):
1624 _toSchema = {'displayname': 'displayname', 'user': 'user', 'lastconnection': 'lastconnection', 'access': 'access'}
1625 _toPy = {'displayname': 'displayname', 'user': 'user', 'lastconnection': 'lastconnection', 'access': 'access'}
1626 def __init__(self, access=None, displayname=None, lastconnection=None, user=None):
1627 '''
1628 access : str
1629 displayname : str
1630 lastconnection : str
1631 user : str
1632 '''
1633 self.access = access
1634 self.displayname = displayname
1635 self.lastconnection = lastconnection
1636 self.user = user
1637
1638
1639 class ModelUserInfoResult(Type):
1640 _toSchema = {'result': 'result', 'error': 'error'}
1641 _toPy = {'result': 'result', 'error': 'error'}
1642 def __init__(self, error=None, result=None):
1643 '''
1644 error : Error
1645 result : ModelUserInfo
1646 '''
1647 self.error = Error.from_json(error) if error else None
1648 self.result = ModelUserInfo.from_json(result) if result else None
1649
1650
1651 class ModelUserInfoResults(Type):
1652 _toSchema = {'results': 'results'}
1653 _toPy = {'results': 'results'}
1654 def __init__(self, results=None):
1655 '''
1656 results : typing.Sequence[~ModelUserInfoResult]
1657 '''
1658 self.results = [ModelUserInfoResult.from_json(o) for o in results or []]
1659
1660
1661 class PrivateAddress(Type):
1662 _toSchema = {'target': 'Target'}
1663 _toPy = {'Target': 'target'}
1664 def __init__(self, target=None):
1665 '''
1666 target : str
1667 '''
1668 self.target = target
1669
1670
1671 class PrivateAddressResults(Type):
1672 _toSchema = {'privateaddress': 'PrivateAddress'}
1673 _toPy = {'PrivateAddress': 'privateaddress'}
1674 def __init__(self, privateaddress=None):
1675 '''
1676 privateaddress : str
1677 '''
1678 self.privateaddress = privateaddress
1679
1680
1681 class ProvisioningScriptParams(Type):
1682 _toSchema = {'disablepackagecommands': 'DisablePackageCommands', 'machineid': 'MachineId', 'datadir': 'DataDir', 'nonce': 'Nonce'}
1683 _toPy = {'MachineId': 'machineid', 'DisablePackageCommands': 'disablepackagecommands', 'DataDir': 'datadir', 'Nonce': 'nonce'}
1684 def __init__(self, datadir=None, disablepackagecommands=None, machineid=None, nonce=None):
1685 '''
1686 datadir : str
1687 disablepackagecommands : bool
1688 machineid : str
1689 nonce : str
1690 '''
1691 self.datadir = datadir
1692 self.disablepackagecommands = disablepackagecommands
1693 self.machineid = machineid
1694 self.nonce = nonce
1695
1696
1697 class ProvisioningScriptResult(Type):
1698 _toSchema = {'script': 'Script'}
1699 _toPy = {'Script': 'script'}
1700 def __init__(self, script=None):
1701 '''
1702 script : str
1703 '''
1704 self.script = script
1705
1706
1707 class PublicAddress(Type):
1708 _toSchema = {'target': 'Target'}
1709 _toPy = {'Target': 'target'}
1710 def __init__(self, target=None):
1711 '''
1712 target : str
1713 '''
1714 self.target = target
1715
1716
1717 class PublicAddressResults(Type):
1718 _toSchema = {'publicaddress': 'PublicAddress'}
1719 _toPy = {'PublicAddress': 'publicaddress'}
1720 def __init__(self, publicaddress=None):
1721 '''
1722 publicaddress : str
1723 '''
1724 self.publicaddress = publicaddress
1725
1726
1727 class RelationStatus(Type):
1728 _toSchema = {'key': 'Key', 'endpoints': 'Endpoints', 'scope': 'Scope', 'id_': 'Id', 'interface': 'Interface'}
1729 _toPy = {'Key': 'key', 'Interface': 'interface', 'Id': 'id_', 'Endpoints': 'endpoints', 'Scope': 'scope'}
1730 def __init__(self, endpoints=None, id_=None, interface=None, key=None, scope=None):
1731 '''
1732 endpoints : typing.Sequence[~EndpointStatus]
1733 id_ : int
1734 interface : str
1735 key : str
1736 scope : str
1737 '''
1738 self.endpoints = [EndpointStatus.from_json(o) for o in endpoints or []]
1739 self.id_ = id_
1740 self.interface = interface
1741 self.key = key
1742 self.scope = scope
1743
1744
1745 class ResolveCharmResult(Type):
1746 _toSchema = {'error': 'Error', 'url': 'URL'}
1747 _toPy = {'URL': 'url', 'Error': 'error'}
1748 def __init__(self, error=None, url=None):
1749 '''
1750 error : str
1751 url : URL
1752 '''
1753 self.error = error
1754 self.url = URL.from_json(url) if url else None
1755
1756
1757 class ResolveCharmResults(Type):
1758 _toSchema = {'urls': 'URLs'}
1759 _toPy = {'URLs': 'urls'}
1760 def __init__(self, urls=None):
1761 '''
1762 urls : typing.Sequence[~ResolveCharmResult]
1763 '''
1764 self.urls = [ResolveCharmResult.from_json(o) for o in urls or []]
1765
1766
1767 class ResolveCharms(Type):
1768 _toSchema = {'references': 'References'}
1769 _toPy = {'References': 'references'}
1770 def __init__(self, references=None):
1771 '''
1772 references : typing.Sequence[~URL]
1773 '''
1774 self.references = [URL.from_json(o) for o in references or []]
1775
1776
1777 class Resolved(Type):
1778 _toSchema = {'unitname': 'UnitName', 'retry': 'Retry'}
1779 _toPy = {'UnitName': 'unitname', 'Retry': 'retry'}
1780 def __init__(self, retry=None, unitname=None):
1781 '''
1782 retry : bool
1783 unitname : str
1784 '''
1785 self.retry = retry
1786 self.unitname = unitname
1787
1788
1789 class SetModelAgentVersion(Type):
1790 _toSchema = {'minor': 'Minor', 'major': 'Major', 'patch': 'Patch', 'tag': 'Tag', 'build': 'Build'}
1791 _toPy = {'Patch': 'patch', 'Major': 'major', 'Minor': 'minor', 'Tag': 'tag', 'Build': 'build'}
1792 def __init__(self, build=None, major=None, minor=None, patch=None, tag=None):
1793 '''
1794 build : int
1795 major : int
1796 minor : int
1797 patch : int
1798 tag : str
1799 '''
1800 self.build = build
1801 self.major = major
1802 self.minor = minor
1803 self.patch = patch
1804 self.tag = tag
1805
1806
1807 class StatusHistoryFilter(Type):
1808 _toSchema = {'delta': 'Delta', 'date': 'Date', 'size': 'Size'}
1809 _toPy = {'Delta': 'delta', 'Date': 'date', 'Size': 'size'}
1810 def __init__(self, date=None, delta=None, size=None):
1811 '''
1812 date : str
1813 delta : int
1814 size : int
1815 '''
1816 self.date = date
1817 self.delta = delta
1818 self.size = size
1819
1820
1821 class StatusHistoryRequest(Type):
1822 _toSchema = {'historykind': 'HistoryKind', 'filter_': 'Filter', 'tag': 'Tag', 'size': 'Size'}
1823 _toPy = {'Tag': 'tag', 'Size': 'size', 'Filter': 'filter_', 'HistoryKind': 'historykind'}
1824 def __init__(self, filter_=None, historykind=None, size=None, tag=None):
1825 '''
1826 filter_ : StatusHistoryFilter
1827 historykind : str
1828 size : int
1829 tag : str
1830 '''
1831 self.filter_ = StatusHistoryFilter.from_json(filter_) if filter_ else None
1832 self.historykind = historykind
1833 self.size = size
1834 self.tag = tag
1835
1836
1837 class StatusHistoryRequests(Type):
1838 _toSchema = {'requests': 'Requests'}
1839 _toPy = {'Requests': 'requests'}
1840 def __init__(self, requests=None):
1841 '''
1842 requests : typing.Sequence[~StatusHistoryRequest]
1843 '''
1844 self.requests = [StatusHistoryRequest.from_json(o) for o in requests or []]
1845
1846
1847 class StatusHistoryResult(Type):
1848 _toSchema = {'history': 'History', 'error': 'Error'}
1849 _toPy = {'History': 'history', 'Error': 'error'}
1850 def __init__(self, error=None, history=None):
1851 '''
1852 error : Error
1853 history : History
1854 '''
1855 self.error = Error.from_json(error) if error else None
1856 self.history = History.from_json(history) if history else None
1857
1858
1859 class StatusHistoryResults(Type):
1860 _toSchema = {'results': 'Results'}
1861 _toPy = {'Results': 'results'}
1862 def __init__(self, results=None):
1863 '''
1864 results : typing.Sequence[~StatusHistoryResult]
1865 '''
1866 self.results = [StatusHistoryResult.from_json(o) for o in results or []]
1867
1868
1869 class StatusParams(Type):
1870 _toSchema = {'patterns': 'Patterns'}
1871 _toPy = {'Patterns': 'patterns'}
1872 def __init__(self, patterns=None):
1873 '''
1874 patterns : typing.Sequence[str]
1875 '''
1876 self.patterns = patterns
1877
1878
1879 class Tools(Type):
1880 _toSchema = {'sha256': 'sha256', 'url': 'url', 'size': 'size', 'version': 'version'}
1881 _toPy = {'sha256': 'sha256', 'url': 'url', 'size': 'size', 'version': 'version'}
1882 def __init__(self, sha256=None, size=None, url=None, version=None):
1883 '''
1884 sha256 : str
1885 size : int
1886 url : str
1887 version : Binary
1888 '''
1889 self.sha256 = sha256
1890 self.size = size
1891 self.url = url
1892 self.version = Binary.from_json(version) if version else None
1893
1894
1895 class URL(Type):
1896 _toSchema = {'revision': 'Revision', 'series': 'Series', 'schema': 'Schema', 'channel': 'Channel', 'name': 'Name', 'user': 'User'}
1897 _toPy = {'Name': 'name', 'Revision': 'revision', 'User': 'user', 'Schema': 'schema', 'Channel': 'channel', 'Series': 'series'}
1898 def __init__(self, channel=None, name=None, revision=None, schema=None, series=None, user=None):
1899 '''
1900 channel : str
1901 name : str
1902 revision : int
1903 schema : str
1904 series : str
1905 user : str
1906 '''
1907 self.channel = channel
1908 self.name = name
1909 self.revision = revision
1910 self.schema = schema
1911 self.series = series
1912 self.user = user
1913
1914
1915 class UnitStatus(Type):
1916 _toSchema = {'charm': 'Charm', 'publicaddress': 'PublicAddress', 'openedports': 'OpenedPorts', 'agentstatus': 'AgentStatus', 'subordinates': 'Subordinates', 'workloadstatus': 'WorkloadStatus', 'machine': 'Machine'}
1917 _toPy = {'AgentStatus': 'agentstatus', 'Charm': 'charm', 'OpenedPorts': 'openedports', 'WorkloadStatus': 'workloadstatus', 'PublicAddress': 'publicaddress', 'Machine': 'machine', 'Subordinates': 'subordinates'}
1918 def __init__(self, agentstatus=None, charm=None, machine=None, openedports=None, publicaddress=None, subordinates=None, workloadstatus=None):
1919 '''
1920 agentstatus : DetailedStatus
1921 charm : str
1922 machine : str
1923 openedports : typing.Sequence[str]
1924 publicaddress : str
1925 subordinates : typing.Mapping[str, ~UnitStatus]
1926 workloadstatus : DetailedStatus
1927 '''
1928 self.agentstatus = DetailedStatus.from_json(agentstatus) if agentstatus else None
1929 self.charm = charm
1930 self.machine = machine
1931 self.openedports = openedports
1932 self.publicaddress = publicaddress
1933 self.subordinates = {k: UnitStatus.from_json(v) for k, v in (subordinates or dict()).items()}
1934 self.workloadstatus = DetailedStatus.from_json(workloadstatus) if workloadstatus else None
1935
1936
1937 class DestroyControllerArgs(Type):
1938 _toSchema = {'destroy_models': 'destroy-models'}
1939 _toPy = {'destroy-models': 'destroy_models'}
1940 def __init__(self, destroy_models=None):
1941 '''
1942 destroy_models : bool
1943 '''
1944 self.destroy_models = destroy_models
1945
1946
1947 class InitiateModelMigrationArgs(Type):
1948 _toSchema = {'specs': 'specs'}
1949 _toPy = {'specs': 'specs'}
1950 def __init__(self, specs=None):
1951 '''
1952 specs : typing.Sequence[~ModelMigrationSpec]
1953 '''
1954 self.specs = [ModelMigrationSpec.from_json(o) for o in specs or []]
1955
1956
1957 class InitiateModelMigrationResult(Type):
1958 _toSchema = {'id_': 'id', 'model_tag': 'model-tag', 'error': 'error'}
1959 _toPy = {'id': 'id_', 'error': 'error', 'model-tag': 'model_tag'}
1960 def __init__(self, error=None, id_=None, model_tag=None):
1961 '''
1962 error : Error
1963 id_ : str
1964 model_tag : str
1965 '''
1966 self.error = Error.from_json(error) if error else None
1967 self.id_ = id_
1968 self.model_tag = model_tag
1969
1970
1971 class InitiateModelMigrationResults(Type):
1972 _toSchema = {'results': 'results'}
1973 _toPy = {'results': 'results'}
1974 def __init__(self, results=None):
1975 '''
1976 results : typing.Sequence[~InitiateModelMigrationResult]
1977 '''
1978 self.results = [InitiateModelMigrationResult.from_json(o) for o in results or []]
1979
1980
1981 class Model(Type):
1982 _toSchema = {'uuid': 'UUID', 'ownertag': 'OwnerTag', 'name': 'Name'}
1983 _toPy = {'OwnerTag': 'ownertag', 'Name': 'name', 'UUID': 'uuid'}
1984 def __init__(self, name=None, ownertag=None, uuid=None):
1985 '''
1986 name : str
1987 ownertag : str
1988 uuid : str
1989 '''
1990 self.name = name
1991 self.ownertag = ownertag
1992 self.uuid = uuid
1993
1994
1995 class ModelBlockInfo(Type):
1996 _toSchema = {'blocks': 'blocks', 'model_uuid': 'model-uuid', 'owner_tag': 'owner-tag', 'name': 'name'}
1997 _toPy = {'owner-tag': 'owner_tag', 'blocks': 'blocks', 'model-uuid': 'model_uuid', 'name': 'name'}
1998 def __init__(self, blocks=None, model_uuid=None, name=None, owner_tag=None):
1999 '''
2000 blocks : typing.Sequence[str]
2001 model_uuid : str
2002 name : str
2003 owner_tag : str
2004 '''
2005 self.blocks = blocks
2006 self.model_uuid = model_uuid
2007 self.name = name
2008 self.owner_tag = owner_tag
2009
2010
2011 class ModelBlockInfoList(Type):
2012 _toSchema = {'models': 'models'}
2013 _toPy = {'models': 'models'}
2014 def __init__(self, models=None):
2015 '''
2016 models : typing.Sequence[~ModelBlockInfo]
2017 '''
2018 self.models = [ModelBlockInfo.from_json(o) for o in models or []]
2019
2020
2021 class ModelMigrationSpec(Type):
2022 _toSchema = {'model_tag': 'model-tag', 'target_info': 'target-info'}
2023 _toPy = {'model-tag': 'model_tag', 'target-info': 'target_info'}
2024 def __init__(self, model_tag=None, target_info=None):
2025 '''
2026 model_tag : str
2027 target_info : ModelMigrationTargetInfo
2028 '''
2029 self.model_tag = model_tag
2030 self.target_info = ModelMigrationTargetInfo.from_json(target_info) if target_info else None
2031
2032
2033 class ModelMigrationTargetInfo(Type):
2034 _toSchema = {'auth_tag': 'auth-tag', 'ca_cert': 'ca-cert', 'controller_tag': 'controller-tag', 'password': 'password', 'addrs': 'addrs'}
2035 _toPy = {'ca-cert': 'ca_cert', 'auth-tag': 'auth_tag', 'password': 'password', 'controller-tag': 'controller_tag', 'addrs': 'addrs'}
2036 def __init__(self, addrs=None, auth_tag=None, ca_cert=None, controller_tag=None, password=None):
2037 '''
2038 addrs : typing.Sequence[str]
2039 auth_tag : str
2040 ca_cert : str
2041 controller_tag : str
2042 password : str
2043 '''
2044 self.addrs = addrs
2045 self.auth_tag = auth_tag
2046 self.ca_cert = ca_cert
2047 self.controller_tag = controller_tag
2048 self.password = password
2049
2050
2051 class ModelStatus(Type):
2052 _toSchema = {'model_tag': 'model-tag', 'life': 'life', 'application_count': 'application-count', 'hosted_machine_count': 'hosted-machine-count', 'owner_tag': 'owner-tag'}
2053 _toPy = {'life': 'life', 'application-count': 'application_count', 'hosted-machine-count': 'hosted_machine_count', 'model-tag': 'model_tag', 'owner-tag': 'owner_tag'}
2054 def __init__(self, application_count=None, hosted_machine_count=None, life=None, model_tag=None, owner_tag=None):
2055 '''
2056 application_count : int
2057 hosted_machine_count : int
2058 life : str
2059 model_tag : str
2060 owner_tag : str
2061 '''
2062 self.application_count = application_count
2063 self.hosted_machine_count = hosted_machine_count
2064 self.life = life
2065 self.model_tag = model_tag
2066 self.owner_tag = owner_tag
2067
2068
2069 class ModelStatusResults(Type):
2070 _toSchema = {'models': 'models'}
2071 _toPy = {'models': 'models'}
2072 def __init__(self, models=None):
2073 '''
2074 models : typing.Sequence[~ModelStatus]
2075 '''
2076 self.models = [ModelStatus.from_json(o) for o in models or []]
2077
2078
2079 class RemoveBlocksArgs(Type):
2080 _toSchema = {'all_': 'all'}
2081 _toPy = {'all': 'all_'}
2082 def __init__(self, all_=None):
2083 '''
2084 all_ : bool
2085 '''
2086 self.all_ = all_
2087
2088
2089 class UserModel(Type):
2090 _toSchema = {'model': 'Model', 'lastconnection': 'LastConnection'}
2091 _toPy = {'Model': 'model', 'LastConnection': 'lastconnection'}
2092 def __init__(self, lastconnection=None, model=None):
2093 '''
2094 lastconnection : str
2095 model : Model
2096 '''
2097 self.lastconnection = lastconnection
2098 self.model = Model.from_json(model) if model else None
2099
2100
2101 class UserModelList(Type):
2102 _toSchema = {'usermodels': 'UserModels'}
2103 _toPy = {'UserModels': 'usermodels'}
2104 def __init__(self, usermodels=None):
2105 '''
2106 usermodels : typing.Sequence[~UserModel]
2107 '''
2108 self.usermodels = [UserModel.from_json(o) for o in usermodels or []]
2109
2110
2111 class BytesResult(Type):
2112 _toSchema = {'result': 'Result'}
2113 _toPy = {'Result': 'result'}
2114 def __init__(self, result=None):
2115 '''
2116 result : typing.Sequence[int]
2117 '''
2118 self.result = result
2119
2120
2121 class DeployerConnectionValues(Type):
2122 _toSchema = {'stateaddresses': 'StateAddresses', 'apiaddresses': 'APIAddresses'}
2123 _toPy = {'StateAddresses': 'stateaddresses', 'APIAddresses': 'apiaddresses'}
2124 def __init__(self, apiaddresses=None, stateaddresses=None):
2125 '''
2126 apiaddresses : typing.Sequence[str]
2127 stateaddresses : typing.Sequence[str]
2128 '''
2129 self.apiaddresses = apiaddresses
2130 self.stateaddresses = stateaddresses
2131
2132
2133 class LifeResult(Type):
2134 _toSchema = {'life': 'Life', 'error': 'Error'}
2135 _toPy = {'Life': 'life', 'Error': 'error'}
2136 def __init__(self, error=None, life=None):
2137 '''
2138 error : Error
2139 life : str
2140 '''
2141 self.error = Error.from_json(error) if error else None
2142 self.life = life
2143
2144
2145 class LifeResults(Type):
2146 _toSchema = {'results': 'Results'}
2147 _toPy = {'Results': 'results'}
2148 def __init__(self, results=None):
2149 '''
2150 results : typing.Sequence[~LifeResult]
2151 '''
2152 self.results = [LifeResult.from_json(o) for o in results or []]
2153
2154
2155 class StringsResult(Type):
2156 _toSchema = {'result': 'Result', 'error': 'Error'}
2157 _toPy = {'Result': 'result', 'Error': 'error'}
2158 def __init__(self, error=None, result=None):
2159 '''
2160 error : Error
2161 result : typing.Sequence[str]
2162 '''
2163 self.error = Error.from_json(error) if error else None
2164 self.result = result
2165
2166
2167 class StringsWatchResults(Type):
2168 _toSchema = {'results': 'Results'}
2169 _toPy = {'Results': 'results'}
2170 def __init__(self, results=None):
2171 '''
2172 results : typing.Sequence[~StringsWatchResult]
2173 '''
2174 self.results = [StringsWatchResult.from_json(o) for o in results or []]
2175
2176
2177 class AddSubnetParams(Type):
2178 _toSchema = {'subnetproviderid': 'SubnetProviderId', 'spacetag': 'SpaceTag', 'subnettag': 'SubnetTag', 'zones': 'Zones'}
2179 _toPy = {'SubnetTag': 'subnettag', 'SpaceTag': 'spacetag', 'Zones': 'zones', 'SubnetProviderId': 'subnetproviderid'}
2180 def __init__(self, spacetag=None, subnetproviderid=None, subnettag=None, zones=None):
2181 '''
2182 spacetag : str
2183 subnetproviderid : str
2184 subnettag : str
2185 zones : typing.Sequence[str]
2186 '''
2187 self.spacetag = spacetag
2188 self.subnetproviderid = subnetproviderid
2189 self.subnettag = subnettag
2190 self.zones = zones
2191
2192
2193 class AddSubnetsParams(Type):
2194 _toSchema = {'subnets': 'Subnets'}
2195 _toPy = {'Subnets': 'subnets'}
2196 def __init__(self, subnets=None):
2197 '''
2198 subnets : typing.Sequence[~AddSubnetParams]
2199 '''
2200 self.subnets = [AddSubnetParams.from_json(o) for o in subnets or []]
2201
2202
2203 class CreateSpaceParams(Type):
2204 _toSchema = {'providerid': 'ProviderId', 'public': 'Public', 'spacetag': 'SpaceTag', 'subnettags': 'SubnetTags'}
2205 _toPy = {'Public': 'public', 'SpaceTag': 'spacetag', 'SubnetTags': 'subnettags', 'ProviderId': 'providerid'}
2206 def __init__(self, providerid=None, public=None, spacetag=None, subnettags=None):
2207 '''
2208 providerid : str
2209 public : bool
2210 spacetag : str
2211 subnettags : typing.Sequence[str]
2212 '''
2213 self.providerid = providerid
2214 self.public = public
2215 self.spacetag = spacetag
2216 self.subnettags = subnettags
2217
2218
2219 class CreateSpacesParams(Type):
2220 _toSchema = {'spaces': 'Spaces'}
2221 _toPy = {'Spaces': 'spaces'}
2222 def __init__(self, spaces=None):
2223 '''
2224 spaces : typing.Sequence[~CreateSpaceParams]
2225 '''
2226 self.spaces = [CreateSpaceParams.from_json(o) for o in spaces or []]
2227
2228
2229 class DiscoverSpacesResults(Type):
2230 _toSchema = {'results': 'Results'}
2231 _toPy = {'Results': 'results'}
2232 def __init__(self, results=None):
2233 '''
2234 results : typing.Sequence[~ProviderSpace]
2235 '''
2236 self.results = [ProviderSpace.from_json(o) for o in results or []]
2237
2238
2239 class ListSubnetsResults(Type):
2240 _toSchema = {'results': 'Results'}
2241 _toPy = {'Results': 'results'}
2242 def __init__(self, results=None):
2243 '''
2244 results : typing.Sequence[~Subnet]
2245 '''
2246 self.results = [Subnet.from_json(o) for o in results or []]
2247
2248
2249 class ProviderSpace(Type):
2250 _toSchema = {'providerid': 'ProviderId', 'subnets': 'Subnets', 'error': 'Error', 'name': 'Name'}
2251 _toPy = {'ProviderId': 'providerid', 'Subnets': 'subnets', 'Error': 'error', 'Name': 'name'}
2252 def __init__(self, error=None, name=None, providerid=None, subnets=None):
2253 '''
2254 error : Error
2255 name : str
2256 providerid : str
2257 subnets : typing.Sequence[~Subnet]
2258 '''
2259 self.error = Error.from_json(error) if error else None
2260 self.name = name
2261 self.providerid = providerid
2262 self.subnets = [Subnet.from_json(o) for o in subnets or []]
2263
2264
2265 class Subnet(Type):
2266 _toSchema = {'staticrangelowip': 'StaticRangeLowIP', 'spacetag': 'SpaceTag', 'cidr': 'CIDR', 'providerid': 'ProviderId', 'life': 'Life', 'staticrangehighip': 'StaticRangeHighIP', 'zones': 'Zones', 'vlantag': 'VLANTag', 'status': 'Status'}
2267 _toPy = {'StaticRangeHighIP': 'staticrangehighip', 'VLANTag': 'vlantag', 'Zones': 'zones', 'SpaceTag': 'spacetag', 'Life': 'life', 'Status': 'status', 'ProviderId': 'providerid', 'StaticRangeLowIP': 'staticrangelowip', 'CIDR': 'cidr'}
2268 def __init__(self, cidr=None, life=None, providerid=None, spacetag=None, staticrangehighip=None, staticrangelowip=None, status=None, vlantag=None, zones=None):
2269 '''
2270 cidr : str
2271 life : str
2272 providerid : str
2273 spacetag : str
2274 staticrangehighip : typing.Sequence[int]
2275 staticrangelowip : typing.Sequence[int]
2276 status : str
2277 vlantag : int
2278 zones : typing.Sequence[str]
2279 '''
2280 self.cidr = cidr
2281 self.life = life
2282 self.providerid = providerid
2283 self.spacetag = spacetag
2284 self.staticrangehighip = staticrangehighip
2285 self.staticrangelowip = staticrangelowip
2286 self.status = status
2287 self.vlantag = vlantag
2288 self.zones = zones
2289
2290
2291 class SubnetsFilters(Type):
2292 _toSchema = {'spacetag': 'SpaceTag', 'zone': 'Zone'}
2293 _toPy = {'SpaceTag': 'spacetag', 'Zone': 'zone'}
2294 def __init__(self, spacetag=None, zone=None):
2295 '''
2296 spacetag : str
2297 zone : str
2298 '''
2299 self.spacetag = spacetag
2300 self.zone = zone
2301
2302
2303 class BlockDevice(Type):
2304 _toSchema = {'inuse': 'InUse', 'busaddress': 'BusAddress', 'devicename': 'DeviceName', 'size': 'Size', 'filesystemtype': 'FilesystemType', 'uuid': 'UUID', 'hardwareid': 'HardwareId', 'label': 'Label', 'mountpoint': 'MountPoint', 'devicelinks': 'DeviceLinks'}
2305 _toPy = {'FilesystemType': 'filesystemtype', 'Label': 'label', 'Size': 'size', 'UUID': 'uuid', 'MountPoint': 'mountpoint', 'BusAddress': 'busaddress', 'InUse': 'inuse', 'DeviceName': 'devicename', 'DeviceLinks': 'devicelinks', 'HardwareId': 'hardwareid'}
2306 def __init__(self, busaddress=None, devicelinks=None, devicename=None, filesystemtype=None, hardwareid=None, inuse=None, label=None, mountpoint=None, size=None, uuid=None):
2307 '''
2308 busaddress : str
2309 devicelinks : typing.Sequence[str]
2310 devicename : str
2311 filesystemtype : str
2312 hardwareid : str
2313 inuse : bool
2314 label : str
2315 mountpoint : str
2316 size : int
2317 uuid : str
2318 '''
2319 self.busaddress = busaddress
2320 self.devicelinks = devicelinks
2321 self.devicename = devicename
2322 self.filesystemtype = filesystemtype
2323 self.hardwareid = hardwareid
2324 self.inuse = inuse
2325 self.label = label
2326 self.mountpoint = mountpoint
2327 self.size = size
2328 self.uuid = uuid
2329
2330
2331 class MachineBlockDevices(Type):
2332 _toSchema = {'blockdevices': 'blockdevices', 'machine': 'machine'}
2333 _toPy = {'blockdevices': 'blockdevices', 'machine': 'machine'}
2334 def __init__(self, blockdevices=None, machine=None):
2335 '''
2336 blockdevices : typing.Sequence[~BlockDevice]
2337 machine : str
2338 '''
2339 self.blockdevices = [BlockDevice.from_json(o) for o in blockdevices or []]
2340 self.machine = machine
2341
2342
2343 class SetMachineBlockDevices(Type):
2344 _toSchema = {'machineblockdevices': 'machineblockdevices'}
2345 _toPy = {'machineblockdevices': 'machineblockdevices'}
2346 def __init__(self, machineblockdevices=None):
2347 '''
2348 machineblockdevices : typing.Sequence[~MachineBlockDevices]
2349 '''
2350 self.machineblockdevices = [MachineBlockDevices.from_json(o) for o in machineblockdevices or []]
2351
2352
2353 class MachineStorageId(Type):
2354 _toSchema = {'attachmenttag': 'attachmenttag', 'machinetag': 'machinetag'}
2355 _toPy = {'attachmenttag': 'attachmenttag', 'machinetag': 'machinetag'}
2356 def __init__(self, attachmenttag=None, machinetag=None):
2357 '''
2358 attachmenttag : str
2359 machinetag : str
2360 '''
2361 self.attachmenttag = attachmenttag
2362 self.machinetag = machinetag
2363
2364
2365 class MachineStorageIdsWatchResult(Type):
2366 _toSchema = {'changes': 'Changes', 'machinestorageidswatcherid': 'MachineStorageIdsWatcherId', 'error': 'Error'}
2367 _toPy = {'Changes': 'changes', 'Error': 'error', 'MachineStorageIdsWatcherId': 'machinestorageidswatcherid'}
2368 def __init__(self, changes=None, error=None, machinestorageidswatcherid=None):
2369 '''
2370 changes : typing.Sequence[~MachineStorageId]
2371 error : Error
2372 machinestorageidswatcherid : str
2373 '''
2374 self.changes = [MachineStorageId.from_json(o) for o in changes or []]
2375 self.error = Error.from_json(error) if error else None
2376 self.machinestorageidswatcherid = machinestorageidswatcherid
2377
2378
2379 class BoolResults(Type):
2380 _toSchema = {'results': 'Results'}
2381 _toPy = {'Results': 'results'}
2382 def __init__(self, results=None):
2383 '''
2384 results : typing.Sequence[~BoolResult]
2385 '''
2386 self.results = [BoolResult.from_json(o) for o in results or []]
2387
2388
2389 class MachinePortRange(Type):
2390 _toSchema = {'unittag': 'UnitTag', 'portrange': 'PortRange', 'relationtag': 'RelationTag'}
2391 _toPy = {'RelationTag': 'relationtag', 'UnitTag': 'unittag', 'PortRange': 'portrange'}
2392 def __init__(self, portrange=None, relationtag=None, unittag=None):
2393 '''
2394 portrange : PortRange
2395 relationtag : str
2396 unittag : str
2397 '''
2398 self.portrange = PortRange.from_json(portrange) if portrange else None
2399 self.relationtag = relationtag
2400 self.unittag = unittag
2401
2402
2403 class MachinePorts(Type):
2404 _toSchema = {'subnettag': 'SubnetTag', 'machinetag': 'MachineTag'}
2405 _toPy = {'MachineTag': 'machinetag', 'SubnetTag': 'subnettag'}
2406 def __init__(self, machinetag=None, subnettag=None):
2407 '''
2408 machinetag : str
2409 subnettag : str
2410 '''
2411 self.machinetag = machinetag
2412 self.subnettag = subnettag
2413
2414
2415 class MachinePortsParams(Type):
2416 _toSchema = {'params': 'Params'}
2417 _toPy = {'Params': 'params'}
2418 def __init__(self, params=None):
2419 '''
2420 params : typing.Sequence[~MachinePorts]
2421 '''
2422 self.params = [MachinePorts.from_json(o) for o in params or []]
2423
2424
2425 class MachinePortsResult(Type):
2426 _toSchema = {'ports': 'Ports', 'error': 'Error'}
2427 _toPy = {'Error': 'error', 'Ports': 'ports'}
2428 def __init__(self, error=None, ports=None):
2429 '''
2430 error : Error
2431 ports : typing.Sequence[~MachinePortRange]
2432 '''
2433 self.error = Error.from_json(error) if error else None
2434 self.ports = [MachinePortRange.from_json(o) for o in ports or []]
2435
2436
2437 class MachinePortsResults(Type):
2438 _toSchema = {'results': 'Results'}
2439 _toPy = {'Results': 'results'}
2440 def __init__(self, results=None):
2441 '''
2442 results : typing.Sequence[~MachinePortsResult]
2443 '''
2444 self.results = [MachinePortsResult.from_json(o) for o in results or []]
2445
2446
2447 class NotifyWatchResults(Type):
2448 _toSchema = {'results': 'Results'}
2449 _toPy = {'Results': 'results'}
2450 def __init__(self, results=None):
2451 '''
2452 results : typing.Sequence[~NotifyWatchResult]
2453 '''
2454 self.results = [NotifyWatchResult.from_json(o) for o in results or []]
2455
2456
2457 class PortRange(Type):
2458 _toSchema = {'toport': 'ToPort', 'fromport': 'FromPort', 'protocol': 'Protocol'}
2459 _toPy = {'FromPort': 'fromport', 'Protocol': 'protocol', 'ToPort': 'toport'}
2460 def __init__(self, fromport=None, protocol=None, toport=None):
2461 '''
2462 fromport : int
2463 protocol : str
2464 toport : int
2465 '''
2466 self.fromport = fromport
2467 self.protocol = protocol
2468 self.toport = toport
2469
2470
2471 class StringResults(Type):
2472 _toSchema = {'results': 'Results'}
2473 _toPy = {'Results': 'results'}
2474 def __init__(self, results=None):
2475 '''
2476 results : typing.Sequence[~StringResult]
2477 '''
2478 self.results = [StringResult.from_json(o) for o in results or []]
2479
2480
2481 class StringsResults(Type):
2482 _toSchema = {'results': 'Results'}
2483 _toPy = {'Results': 'results'}
2484 def __init__(self, results=None):
2485 '''
2486 results : typing.Sequence[~StringsResult]
2487 '''
2488 self.results = [StringsResult.from_json(o) for o in results or []]
2489
2490
2491 class ControllersChangeResult(Type):
2492 _toSchema = {'result': 'Result', 'error': 'Error'}
2493 _toPy = {'Result': 'result', 'Error': 'error'}
2494 def __init__(self, error=None, result=None):
2495 '''
2496 error : Error
2497 result : ControllersChanges
2498 '''
2499 self.error = Error.from_json(error) if error else None
2500 self.result = ControllersChanges.from_json(result) if result else None
2501
2502
2503 class ControllersChangeResults(Type):
2504 _toSchema = {'results': 'Results'}
2505 _toPy = {'Results': 'results'}
2506 def __init__(self, results=None):
2507 '''
2508 results : typing.Sequence[~ControllersChangeResult]
2509 '''
2510 self.results = [ControllersChangeResult.from_json(o) for o in results or []]
2511
2512
2513 class ControllersChanges(Type):
2514 _toSchema = {'maintained': 'maintained', 'added': 'added', 'removed': 'removed', 'promoted': 'promoted', 'converted': 'converted', 'demoted': 'demoted'}
2515 _toPy = {'maintained': 'maintained', 'added': 'added', 'removed': 'removed', 'promoted': 'promoted', 'converted': 'converted', 'demoted': 'demoted'}
2516 def __init__(self, added=None, converted=None, demoted=None, maintained=None, promoted=None, removed=None):
2517 '''
2518 added : typing.Sequence[str]
2519 converted : typing.Sequence[str]
2520 demoted : typing.Sequence[str]
2521 maintained : typing.Sequence[str]
2522 promoted : typing.Sequence[str]
2523 removed : typing.Sequence[str]
2524 '''
2525 self.added = added
2526 self.converted = converted
2527 self.demoted = demoted
2528 self.maintained = maintained
2529 self.promoted = promoted
2530 self.removed = removed
2531
2532
2533 class ControllersSpec(Type):
2534 _toSchema = {'constraints': 'constraints', 'modeltag': 'ModelTag', 'num_controllers': 'num-controllers', 'placement': 'placement', 'series': 'series'}
2535 _toPy = {'ModelTag': 'modeltag', 'series': 'series', 'num-controllers': 'num_controllers', 'placement': 'placement', 'constraints': 'constraints'}
2536 def __init__(self, modeltag=None, constraints=None, num_controllers=None, placement=None, series=None):
2537 '''
2538 modeltag : str
2539 constraints : Value
2540 num_controllers : int
2541 placement : typing.Sequence[str]
2542 series : str
2543 '''
2544 self.modeltag = modeltag
2545 self.constraints = Value.from_json(constraints) if constraints else None
2546 self.num_controllers = num_controllers
2547 self.placement = placement
2548 self.series = series
2549
2550
2551 class ControllersSpecs(Type):
2552 _toSchema = {'specs': 'Specs'}
2553 _toPy = {'Specs': 'specs'}
2554 def __init__(self, specs=None):
2555 '''
2556 specs : typing.Sequence[~ControllersSpec]
2557 '''
2558 self.specs = [ControllersSpec.from_json(o) for o in specs or []]
2559
2560
2561 class HAMember(Type):
2562 _toSchema = {'publicaddress': 'PublicAddress', 'series': 'Series', 'tag': 'Tag'}
2563 _toPy = {'Tag': 'tag', 'PublicAddress': 'publicaddress', 'Series': 'series'}
2564 def __init__(self, publicaddress=None, series=None, tag=None):
2565 '''
2566 publicaddress : Address
2567 series : str
2568 tag : str
2569 '''
2570 self.publicaddress = Address.from_json(publicaddress) if publicaddress else None
2571 self.series = series
2572 self.tag = tag
2573
2574
2575 class Member(Type):
2576 _toSchema = {'priority': 'Priority', 'slavedelay': 'SlaveDelay', 'id_': 'Id', 'hidden': 'Hidden', 'votes': 'Votes', 'buildindexes': 'BuildIndexes', 'address': 'Address', 'tags': 'Tags', 'arbiter': 'Arbiter'}
2577 _toPy = {'Hidden': 'hidden', 'Priority': 'priority', 'SlaveDelay': 'slavedelay', 'Id': 'id_', 'Arbiter': 'arbiter', 'Votes': 'votes', 'Tags': 'tags', 'Address': 'address', 'BuildIndexes': 'buildindexes'}
2578 def __init__(self, address=None, arbiter=None, buildindexes=None, hidden=None, id_=None, priority=None, slavedelay=None, tags=None, votes=None):
2579 '''
2580 address : str
2581 arbiter : bool
2582 buildindexes : bool
2583 hidden : bool
2584 id_ : int
2585 priority : float
2586 slavedelay : int
2587 tags : typing.Mapping[str, str]
2588 votes : int
2589 '''
2590 self.address = address
2591 self.arbiter = arbiter
2592 self.buildindexes = buildindexes
2593 self.hidden = hidden
2594 self.id_ = id_
2595 self.priority = priority
2596 self.slavedelay = slavedelay
2597 self.tags = tags
2598 self.votes = votes
2599
2600
2601 class MongoUpgradeResults(Type):
2602 _toSchema = {'members': 'Members', 'master': 'Master', 'rsmembers': 'RsMembers'}
2603 _toPy = {'Master': 'master', 'Members': 'members', 'RsMembers': 'rsmembers'}
2604 def __init__(self, master=None, members=None, rsmembers=None):
2605 '''
2606 master : HAMember
2607 members : typing.Sequence[~HAMember]
2608 rsmembers : typing.Sequence[~Member]
2609 '''
2610 self.master = HAMember.from_json(master) if master else None
2611 self.members = [HAMember.from_json(o) for o in members or []]
2612 self.rsmembers = [Member.from_json(o) for o in rsmembers or []]
2613
2614
2615 class ResumeReplicationParams(Type):
2616 _toSchema = {'members': 'Members'}
2617 _toPy = {'Members': 'members'}
2618 def __init__(self, members=None):
2619 '''
2620 members : typing.Sequence[~Member]
2621 '''
2622 self.members = [Member.from_json(o) for o in members or []]
2623
2624
2625 class UpgradeMongoParams(Type):
2626 _toSchema = {'minor': 'Minor', 'storageengine': 'StorageEngine', 'patch': 'Patch', 'major': 'Major'}
2627 _toPy = {'Patch': 'patch', 'Major': 'major', 'StorageEngine': 'storageengine', 'Minor': 'minor'}
2628 def __init__(self, major=None, minor=None, patch=None, storageengine=None):
2629 '''
2630 major : int
2631 minor : int
2632 patch : str
2633 storageengine : str
2634 '''
2635 self.major = major
2636 self.minor = minor
2637 self.patch = patch
2638 self.storageengine = storageengine
2639
2640
2641 class Version(Type):
2642 _toSchema = {'minor': 'Minor', 'storageengine': 'StorageEngine', 'patch': 'Patch', 'major': 'Major'}
2643 _toPy = {'Patch': 'patch', 'Major': 'major', 'StorageEngine': 'storageengine', 'Minor': 'minor'}
2644 def __init__(self, major=None, minor=None, patch=None, storageengine=None):
2645 '''
2646 major : int
2647 minor : int
2648 patch : str
2649 storageengine : str
2650 '''
2651 self.major = major
2652 self.minor = minor
2653 self.patch = patch
2654 self.storageengine = storageengine
2655
2656
2657 class SSHHostKeySet(Type):
2658 _toSchema = {'entity_keys': 'entity-keys'}
2659 _toPy = {'entity-keys': 'entity_keys'}
2660 def __init__(self, entity_keys=None):
2661 '''
2662 entity_keys : typing.Sequence[~SSHHostKeys]
2663 '''
2664 self.entity_keys = [SSHHostKeys.from_json(o) for o in entity_keys or []]
2665
2666
2667 class SSHHostKeys(Type):
2668 _toSchema = {'public_keys': 'public-keys', 'tag': 'tag'}
2669 _toPy = {'public-keys': 'public_keys', 'tag': 'tag'}
2670 def __init__(self, public_keys=None, tag=None):
2671 '''
2672 public_keys : typing.Sequence[str]
2673 tag : str
2674 '''
2675 self.public_keys = public_keys
2676 self.tag = tag
2677
2678
2679 class ImageFilterParams(Type):
2680 _toSchema = {'images': 'images'}
2681 _toPy = {'images': 'images'}
2682 def __init__(self, images=None):
2683 '''
2684 images : typing.Sequence[~ImageSpec]
2685 '''
2686 self.images = [ImageSpec.from_json(o) for o in images or []]
2687
2688
2689 class ImageMetadata(Type):
2690 _toSchema = {'created': 'created', 'arch': 'arch', 'kind': 'kind', 'series': 'series', 'url': 'url'}
2691 _toPy = {'created': 'created', 'arch': 'arch', 'kind': 'kind', 'series': 'series', 'url': 'url'}
2692 def __init__(self, arch=None, created=None, kind=None, series=None, url=None):
2693 '''
2694 arch : str
2695 created : str
2696 kind : str
2697 series : str
2698 url : str
2699 '''
2700 self.arch = arch
2701 self.created = created
2702 self.kind = kind
2703 self.series = series
2704 self.url = url
2705
2706
2707 class ImageSpec(Type):
2708 _toSchema = {'series': 'series', 'arch': 'arch', 'kind': 'kind'}
2709 _toPy = {'series': 'series', 'arch': 'arch', 'kind': 'kind'}
2710 def __init__(self, arch=None, kind=None, series=None):
2711 '''
2712 arch : str
2713 kind : str
2714 series : str
2715 '''
2716 self.arch = arch
2717 self.kind = kind
2718 self.series = series
2719
2720
2721 class ListImageResult(Type):
2722 _toSchema = {'result': 'result'}
2723 _toPy = {'result': 'result'}
2724 def __init__(self, result=None):
2725 '''
2726 result : typing.Sequence[~ImageMetadata]
2727 '''
2728 self.result = [ImageMetadata.from_json(o) for o in result or []]
2729
2730
2731 class CloudImageMetadata(Type):
2732 _toSchema = {'image_id': 'image_id', 'priority': 'priority', 'series': 'series', 'region': 'region', 'virt_type': 'virt_type', 'version': 'version', 'root_storage_size': 'root_storage_size', 'stream': 'stream', 'arch': 'arch', 'source': 'source', 'root_storage_type': 'root_storage_type'}
2733 _toPy = {'image_id': 'image_id', 'priority': 'priority', 'series': 'series', 'region': 'region', 'virt_type': 'virt_type', 'version': 'version', 'root_storage_size': 'root_storage_size', 'stream': 'stream', 'arch': 'arch', 'source': 'source', 'root_storage_type': 'root_storage_type'}
2734 def __init__(self, arch=None, image_id=None, priority=None, region=None, root_storage_size=None, root_storage_type=None, series=None, source=None, stream=None, version=None, virt_type=None):
2735 '''
2736 arch : str
2737 image_id : str
2738 priority : int
2739 region : str
2740 root_storage_size : int
2741 root_storage_type : str
2742 series : str
2743 source : str
2744 stream : str
2745 version : str
2746 virt_type : str
2747 '''
2748 self.arch = arch
2749 self.image_id = image_id
2750 self.priority = priority
2751 self.region = region
2752 self.root_storage_size = root_storage_size
2753 self.root_storage_type = root_storage_type
2754 self.series = series
2755 self.source = source
2756 self.stream = stream
2757 self.version = version
2758 self.virt_type = virt_type
2759
2760
2761 class CloudImageMetadataList(Type):
2762 _toSchema = {'metadata': 'metadata'}
2763 _toPy = {'metadata': 'metadata'}
2764 def __init__(self, metadata=None):
2765 '''
2766 metadata : typing.Sequence[~CloudImageMetadata]
2767 '''
2768 self.metadata = [CloudImageMetadata.from_json(o) for o in metadata or []]
2769
2770
2771 class ImageMetadataFilter(Type):
2772 _toSchema = {'virt_type': 'virt_type', 'series': 'series', 'region': 'region', 'arches': 'arches', 'stream': 'stream', 'root_storage_type': 'root-storage-type'}
2773 _toPy = {'virt_type': 'virt_type', 'series': 'series', 'region': 'region', 'arches': 'arches', 'stream': 'stream', 'root-storage-type': 'root_storage_type'}
2774 def __init__(self, arches=None, region=None, root_storage_type=None, series=None, stream=None, virt_type=None):
2775 '''
2776 arches : typing.Sequence[str]
2777 region : str
2778 root_storage_type : str
2779 series : typing.Sequence[str]
2780 stream : str
2781 virt_type : str
2782 '''
2783 self.arches = arches
2784 self.region = region
2785 self.root_storage_type = root_storage_type
2786 self.series = series
2787 self.stream = stream
2788 self.virt_type = virt_type
2789
2790
2791 class ListCloudImageMetadataResult(Type):
2792 _toSchema = {'result': 'result'}
2793 _toPy = {'result': 'result'}
2794 def __init__(self, result=None):
2795 '''
2796 result : typing.Sequence[~CloudImageMetadata]
2797 '''
2798 self.result = [CloudImageMetadata.from_json(o) for o in result or []]
2799
2800
2801 class MetadataImageIds(Type):
2802 _toSchema = {'image_ids': 'image_ids'}
2803 _toPy = {'image_ids': 'image_ids'}
2804 def __init__(self, image_ids=None):
2805 '''
2806 image_ids : typing.Sequence[str]
2807 '''
2808 self.image_ids = image_ids
2809
2810
2811 class MetadataSaveParams(Type):
2812 _toSchema = {'metadata': 'metadata'}
2813 _toPy = {'metadata': 'metadata'}
2814 def __init__(self, metadata=None):
2815 '''
2816 metadata : typing.Sequence[~CloudImageMetadataList]
2817 '''
2818 self.metadata = [CloudImageMetadataList.from_json(o) for o in metadata or []]
2819
2820
2821 class EntityStatusArgs(Type):
2822 _toSchema = {'data': 'Data', 'tag': 'Tag', 'info': 'Info', 'status': 'Status'}
2823 _toPy = {'Tag': 'tag', 'Status': 'status', 'Data': 'data', 'Info': 'info'}
2824 def __init__(self, data=None, info=None, status=None, tag=None):
2825 '''
2826 data : typing.Mapping[str, typing.Any]
2827 info : str
2828 status : str
2829 tag : str
2830 '''
2831 self.data = data
2832 self.info = info
2833 self.status = status
2834 self.tag = tag
2835
2836
2837 class MachineAddresses(Type):
2838 _toSchema = {'addresses': 'Addresses', 'tag': 'Tag'}
2839 _toPy = {'Addresses': 'addresses', 'Tag': 'tag'}
2840 def __init__(self, addresses=None, tag=None):
2841 '''
2842 addresses : typing.Sequence[~Address]
2843 tag : str
2844 '''
2845 self.addresses = [Address.from_json(o) for o in addresses or []]
2846 self.tag = tag
2847
2848
2849 class MachineAddressesResult(Type):
2850 _toSchema = {'addresses': 'Addresses', 'error': 'Error'}
2851 _toPy = {'Addresses': 'addresses', 'Error': 'error'}
2852 def __init__(self, addresses=None, error=None):
2853 '''
2854 addresses : typing.Sequence[~Address]
2855 error : Error
2856 '''
2857 self.addresses = [Address.from_json(o) for o in addresses or []]
2858 self.error = Error.from_json(error) if error else None
2859
2860
2861 class MachineAddressesResults(Type):
2862 _toSchema = {'results': 'Results'}
2863 _toPy = {'Results': 'results'}
2864 def __init__(self, results=None):
2865 '''
2866 results : typing.Sequence[~MachineAddressesResult]
2867 '''
2868 self.results = [MachineAddressesResult.from_json(o) for o in results or []]
2869
2870
2871 class SetMachinesAddresses(Type):
2872 _toSchema = {'machineaddresses': 'MachineAddresses'}
2873 _toPy = {'MachineAddresses': 'machineaddresses'}
2874 def __init__(self, machineaddresses=None):
2875 '''
2876 machineaddresses : typing.Sequence[~MachineAddresses]
2877 '''
2878 self.machineaddresses = [MachineAddresses.from_json(o) for o in machineaddresses or []]
2879
2880
2881 class SetStatus(Type):
2882 _toSchema = {'entities': 'Entities'}
2883 _toPy = {'Entities': 'entities'}
2884 def __init__(self, entities=None):
2885 '''
2886 entities : typing.Sequence[~EntityStatusArgs]
2887 '''
2888 self.entities = [EntityStatusArgs.from_json(o) for o in entities or []]
2889
2890
2891 class StatusResult(Type):
2892 _toSchema = {'since': 'Since', 'data': 'Data', 'info': 'Info', 'life': 'Life', 'error': 'Error', 'id_': 'Id', 'status': 'Status'}
2893 _toPy = {'Id': 'id_', 'Data': 'data', 'Since': 'since', 'Error': 'error', 'Life': 'life', 'Status': 'status', 'Info': 'info'}
2894 def __init__(self, data=None, error=None, id_=None, info=None, life=None, since=None, status=None):
2895 '''
2896 data : typing.Mapping[str, typing.Any]
2897 error : Error
2898 id_ : str
2899 info : str
2900 life : str
2901 since : str
2902 status : str
2903 '''
2904 self.data = data
2905 self.error = Error.from_json(error) if error else None
2906 self.id_ = id_
2907 self.info = info
2908 self.life = life
2909 self.since = since
2910 self.status = status
2911
2912
2913 class StatusResults(Type):
2914 _toSchema = {'results': 'Results'}
2915 _toPy = {'Results': 'results'}
2916 def __init__(self, results=None):
2917 '''
2918 results : typing.Sequence[~StatusResult]
2919 '''
2920 self.results = [StatusResult.from_json(o) for o in results or []]
2921
2922
2923 class ListSSHKeys(Type):
2924 _toSchema = {'mode': 'Mode', 'entities': 'Entities'}
2925 _toPy = {'Entities': 'entities', 'Mode': 'mode'}
2926 def __init__(self, entities=None, mode=None):
2927 '''
2928 entities : Entities
2929 mode : bool
2930 '''
2931 self.entities = Entities.from_json(entities) if entities else None
2932 self.mode = mode
2933
2934
2935 class ModifyUserSSHKeys(Type):
2936 _toSchema = {'keys': 'Keys', 'user': 'User'}
2937 _toPy = {'User': 'user', 'Keys': 'keys'}
2938 def __init__(self, keys=None, user=None):
2939 '''
2940 keys : typing.Sequence[str]
2941 user : str
2942 '''
2943 self.keys = keys
2944 self.user = user
2945
2946
2947 class ApplicationTag(Type):
2948 _toSchema = {'name': 'Name'}
2949 _toPy = {'Name': 'name'}
2950 def __init__(self, name=None):
2951 '''
2952 name : str
2953 '''
2954 self.name = name
2955
2956
2957 class ClaimLeadershipBulkParams(Type):
2958 _toSchema = {'params': 'Params'}
2959 _toPy = {'Params': 'params'}
2960 def __init__(self, params=None):
2961 '''
2962 params : typing.Sequence[~ClaimLeadershipParams]
2963 '''
2964 self.params = [ClaimLeadershipParams.from_json(o) for o in params or []]
2965
2966
2967 class ClaimLeadershipBulkResults(Type):
2968 _toSchema = {'results': 'Results'}
2969 _toPy = {'Results': 'results'}
2970 def __init__(self, results=None):
2971 '''
2972 results : typing.Sequence[~ErrorResult]
2973 '''
2974 self.results = [ErrorResult.from_json(o) for o in results or []]
2975
2976
2977 class ClaimLeadershipParams(Type):
2978 _toSchema = {'unittag': 'UnitTag', 'applicationtag': 'ApplicationTag', 'durationseconds': 'DurationSeconds'}
2979 _toPy = {'UnitTag': 'unittag', 'DurationSeconds': 'durationseconds', 'ApplicationTag': 'applicationtag'}
2980 def __init__(self, applicationtag=None, durationseconds=None, unittag=None):
2981 '''
2982 applicationtag : str
2983 durationseconds : float
2984 unittag : str
2985 '''
2986 self.applicationtag = applicationtag
2987 self.durationseconds = durationseconds
2988 self.unittag = unittag
2989
2990
2991 class ActionExecutionResult(Type):
2992 _toSchema = {'message': 'message', 'results': 'results', 'actiontag': 'actiontag', 'status': 'status'}
2993 _toPy = {'message': 'message', 'results': 'results', 'actiontag': 'actiontag', 'status': 'status'}
2994 def __init__(self, actiontag=None, message=None, results=None, status=None):
2995 '''
2996 actiontag : str
2997 message : str
2998 results : typing.Mapping[str, typing.Any]
2999 status : str
3000 '''
3001 self.actiontag = actiontag
3002 self.message = message
3003 self.results = results
3004 self.status = status
3005
3006
3007 class ActionExecutionResults(Type):
3008 _toSchema = {'results': 'results'}
3009 _toPy = {'results': 'results'}
3010 def __init__(self, results=None):
3011 '''
3012 results : typing.Sequence[~ActionExecutionResult]
3013 '''
3014 self.results = [ActionExecutionResult.from_json(o) for o in results or []]
3015
3016
3017 class JobsResult(Type):
3018 _toSchema = {'jobs': 'Jobs', 'error': 'Error'}
3019 _toPy = {'Error': 'error', 'Jobs': 'jobs'}
3020 def __init__(self, error=None, jobs=None):
3021 '''
3022 error : Error
3023 jobs : typing.Sequence[str]
3024 '''
3025 self.error = Error.from_json(error) if error else None
3026 self.jobs = jobs
3027
3028
3029 class JobsResults(Type):
3030 _toSchema = {'results': 'Results'}
3031 _toPy = {'Results': 'results'}
3032 def __init__(self, results=None):
3033 '''
3034 results : typing.Sequence[~JobsResult]
3035 '''
3036 self.results = [JobsResult.from_json(o) for o in results or []]
3037
3038
3039 class NetworkConfig(Type):
3040 _toSchema = {'mtu': 'MTU', 'disabled': 'Disabled', 'interfacename': 'InterfaceName', 'dnsservers': 'DNSServers', 'providerid': 'ProviderId', 'providersubnetid': 'ProviderSubnetId', 'deviceindex': 'DeviceIndex', 'vlantag': 'VLANTag', 'provideraddressid': 'ProviderAddressId', 'dnssearchdomains': 'DNSSearchDomains', 'noautostart': 'NoAutoStart', 'macaddress': 'MACAddress', 'address': 'Address', 'cidr': 'CIDR', 'interfacetype': 'InterfaceType', 'parentinterfacename': 'ParentInterfaceName', 'gatewayaddress': 'GatewayAddress', 'providervlanid': 'ProviderVLANId', 'configtype': 'ConfigType', 'providerspaceid': 'ProviderSpaceId'}
3041 _toPy = {'InterfaceType': 'interfacetype', 'ConfigType': 'configtype', 'ProviderVLANId': 'providervlanid', 'ProviderAddressId': 'provideraddressid', 'Disabled': 'disabled', 'ProviderSpaceId': 'providerspaceid', 'GatewayAddress': 'gatewayaddress', 'InterfaceName': 'interfacename', 'ProviderSubnetId': 'providersubnetid', 'MTU': 'mtu', 'VLANTag': 'vlantag', 'NoAutoStart': 'noautostart', 'DNSServers': 'dnsservers', 'DNSSearchDomains': 'dnssearchdomains', 'DeviceIndex': 'deviceindex', 'Address': 'address', 'ProviderId': 'providerid', 'MACAddress': 'macaddress', 'CIDR': 'cidr', 'ParentInterfaceName': 'parentinterfacename'}
3042 def __init__(self, address=None, cidr=None, configtype=None, dnssearchdomains=None, dnsservers=None, deviceindex=None, disabled=None, gatewayaddress=None, interfacename=None, interfacetype=None, macaddress=None, mtu=None, noautostart=None, parentinterfacename=None, provideraddressid=None, providerid=None, providerspaceid=None, providersubnetid=None, providervlanid=None, vlantag=None):
3043 '''
3044 address : str
3045 cidr : str
3046 configtype : str
3047 dnssearchdomains : typing.Sequence[str]
3048 dnsservers : typing.Sequence[str]
3049 deviceindex : int
3050 disabled : bool
3051 gatewayaddress : str
3052 interfacename : str
3053 interfacetype : str
3054 macaddress : str
3055 mtu : int
3056 noautostart : bool
3057 parentinterfacename : str
3058 provideraddressid : str
3059 providerid : str
3060 providerspaceid : str
3061 providersubnetid : str
3062 providervlanid : str
3063 vlantag : int
3064 '''
3065 self.address = address
3066 self.cidr = cidr
3067 self.configtype = configtype
3068 self.dnssearchdomains = dnssearchdomains
3069 self.dnsservers = dnsservers
3070 self.deviceindex = deviceindex
3071 self.disabled = disabled
3072 self.gatewayaddress = gatewayaddress
3073 self.interfacename = interfacename
3074 self.interfacetype = interfacetype
3075 self.macaddress = macaddress
3076 self.mtu = mtu
3077 self.noautostart = noautostart
3078 self.parentinterfacename = parentinterfacename
3079 self.provideraddressid = provideraddressid
3080 self.providerid = providerid
3081 self.providerspaceid = providerspaceid
3082 self.providersubnetid = providersubnetid
3083 self.providervlanid = providervlanid
3084 self.vlantag = vlantag
3085
3086
3087 class SetMachineNetworkConfig(Type):
3088 _toSchema = {'config': 'Config', 'tag': 'Tag'}
3089 _toPy = {'Tag': 'tag', 'Config': 'config'}
3090 def __init__(self, config=None, tag=None):
3091 '''
3092 config : typing.Sequence[~NetworkConfig]
3093 tag : str
3094 '''
3095 self.config = [NetworkConfig.from_json(o) for o in config or []]
3096 self.tag = tag
3097
3098
3099 class MeterStatusResult(Type):
3100 _toSchema = {'code': 'Code', 'error': 'Error', 'info': 'Info'}
3101 _toPy = {'Code': 'code', 'Error': 'error', 'Info': 'info'}
3102 def __init__(self, code=None, error=None, info=None):
3103 '''
3104 code : str
3105 error : Error
3106 info : str
3107 '''
3108 self.code = code
3109 self.error = Error.from_json(error) if error else None
3110 self.info = info
3111
3112
3113 class MeterStatusResults(Type):
3114 _toSchema = {'results': 'Results'}
3115 _toPy = {'Results': 'results'}
3116 def __init__(self, results=None):
3117 '''
3118 results : typing.Sequence[~MeterStatusResult]
3119 '''
3120 self.results = [MeterStatusResult.from_json(o) for o in results or []]
3121
3122
3123 class Metric(Type):
3124 _toSchema = {'key': 'Key', 'time': 'Time', 'value': 'Value'}
3125 _toPy = {'Value': 'value', 'Key': 'key', 'Time': 'time'}
3126 def __init__(self, key=None, time=None, value=None):
3127 '''
3128 key : str
3129 time : str
3130 value : str
3131 '''
3132 self.key = key
3133 self.time = time
3134 self.value = value
3135
3136
3137 class MetricBatch(Type):
3138 _toSchema = {'charmurl': 'CharmURL', 'uuid': 'UUID', 'created': 'Created', 'metrics': 'Metrics'}
3139 _toPy = {'CharmURL': 'charmurl', 'Metrics': 'metrics', 'Created': 'created', 'UUID': 'uuid'}
3140 def __init__(self, charmurl=None, created=None, metrics=None, uuid=None):
3141 '''
3142 charmurl : str
3143 created : str
3144 metrics : typing.Sequence[~Metric]
3145 uuid : str
3146 '''
3147 self.charmurl = charmurl
3148 self.created = created
3149 self.metrics = [Metric.from_json(o) for o in metrics or []]
3150 self.uuid = uuid
3151
3152
3153 class MetricBatchParam(Type):
3154 _toSchema = {'batch': 'Batch', 'tag': 'Tag'}
3155 _toPy = {'Tag': 'tag', 'Batch': 'batch'}
3156 def __init__(self, batch=None, tag=None):
3157 '''
3158 batch : MetricBatch
3159 tag : str
3160 '''
3161 self.batch = MetricBatch.from_json(batch) if batch else None
3162 self.tag = tag
3163
3164
3165 class MetricBatchParams(Type):
3166 _toSchema = {'batches': 'Batches'}
3167 _toPy = {'Batches': 'batches'}
3168 def __init__(self, batches=None):
3169 '''
3170 batches : typing.Sequence[~MetricBatchParam]
3171 '''
3172 self.batches = [MetricBatchParam.from_json(o) for o in batches or []]
3173
3174
3175 class EntityMetrics(Type):
3176 _toSchema = {'error': 'error', 'metrics': 'metrics'}
3177 _toPy = {'error': 'error', 'metrics': 'metrics'}
3178 def __init__(self, error=None, metrics=None):
3179 '''
3180 error : Error
3181 metrics : typing.Sequence[~MetricResult]
3182 '''
3183 self.error = Error.from_json(error) if error else None
3184 self.metrics = [MetricResult.from_json(o) for o in metrics or []]
3185
3186
3187 class MeterStatusParam(Type):
3188 _toSchema = {'code': 'code', 'tag': 'tag', 'info': 'info'}
3189 _toPy = {'code': 'code', 'tag': 'tag', 'info': 'info'}
3190 def __init__(self, code=None, info=None, tag=None):
3191 '''
3192 code : str
3193 info : str
3194 tag : str
3195 '''
3196 self.code = code
3197 self.info = info
3198 self.tag = tag
3199
3200
3201 class MeterStatusParams(Type):
3202 _toSchema = {'statues': 'statues'}
3203 _toPy = {'statues': 'statues'}
3204 def __init__(self, statues=None):
3205 '''
3206 statues : typing.Sequence[~MeterStatusParam]
3207 '''
3208 self.statues = [MeterStatusParam.from_json(o) for o in statues or []]
3209
3210
3211 class MetricResult(Type):
3212 _toSchema = {'key': 'key', 'time': 'time', 'value': 'value'}
3213 _toPy = {'key': 'key', 'time': 'time', 'value': 'value'}
3214 def __init__(self, key=None, time=None, value=None):
3215 '''
3216 key : str
3217 time : str
3218 value : str
3219 '''
3220 self.key = key
3221 self.time = time
3222 self.value = value
3223
3224
3225 class MetricResults(Type):
3226 _toSchema = {'results': 'results'}
3227 _toPy = {'results': 'results'}
3228 def __init__(self, results=None):
3229 '''
3230 results : typing.Sequence[~EntityMetrics]
3231 '''
3232 self.results = [EntityMetrics.from_json(o) for o in results or []]
3233
3234
3235 class PhaseResult(Type):
3236 _toSchema = {'error': 'Error', 'phase': 'phase'}
3237 _toPy = {'Error': 'error', 'phase': 'phase'}
3238 def __init__(self, error=None, phase=None):
3239 '''
3240 error : Error
3241 phase : str
3242 '''
3243 self.error = Error.from_json(error) if error else None
3244 self.phase = phase
3245
3246
3247 class PhaseResults(Type):
3248 _toSchema = {'results': 'Results'}
3249 _toPy = {'Results': 'results'}
3250 def __init__(self, results=None):
3251 '''
3252 results : typing.Sequence[~PhaseResult]
3253 '''
3254 self.results = [PhaseResult.from_json(o) for o in results or []]
3255
3256
3257 class FullMigrationStatus(Type):
3258 _toSchema = {'attempt': 'attempt', 'phase': 'phase', 'spec': 'spec'}
3259 _toPy = {'attempt': 'attempt', 'phase': 'phase', 'spec': 'spec'}
3260 def __init__(self, attempt=None, phase=None, spec=None):
3261 '''
3262 attempt : int
3263 phase : str
3264 spec : ModelMigrationSpec
3265 '''
3266 self.attempt = attempt
3267 self.phase = phase
3268 self.spec = ModelMigrationSpec.from_json(spec) if spec else None
3269
3270
3271 class SerializedModel(Type):
3272 _toSchema = {'bytes_': 'bytes'}
3273 _toPy = {'bytes': 'bytes_'}
3274 def __init__(self, bytes_=None):
3275 '''
3276 bytes_ : typing.Sequence[int]
3277 '''
3278 self.bytes_ = bytes_
3279
3280
3281 class SetMigrationPhaseArgs(Type):
3282 _toSchema = {'phase': 'phase'}
3283 _toPy = {'phase': 'phase'}
3284 def __init__(self, phase=None):
3285 '''
3286 phase : str
3287 '''
3288 self.phase = phase
3289
3290
3291 class MigrationStatus(Type):
3292 _toSchema = {'attempt': 'attempt', 'source_api_addrs': 'source-api-addrs', 'target_api_addrs': 'target-api-addrs', 'source_ca_cert': 'source-ca-cert', 'phase': 'phase', 'target_ca_cert': 'target-ca-cert'}
3293 _toPy = {'target-ca-cert': 'target_ca_cert', 'source-ca-cert': 'source_ca_cert', 'attempt': 'attempt', 'source-api-addrs': 'source_api_addrs', 'phase': 'phase', 'target-api-addrs': 'target_api_addrs'}
3294 def __init__(self, attempt=None, phase=None, source_api_addrs=None, source_ca_cert=None, target_api_addrs=None, target_ca_cert=None):
3295 '''
3296 attempt : int
3297 phase : str
3298 source_api_addrs : typing.Sequence[str]
3299 source_ca_cert : str
3300 target_api_addrs : typing.Sequence[str]
3301 target_ca_cert : str
3302 '''
3303 self.attempt = attempt
3304 self.phase = phase
3305 self.source_api_addrs = source_api_addrs
3306 self.source_ca_cert = source_ca_cert
3307 self.target_api_addrs = target_api_addrs
3308 self.target_ca_cert = target_ca_cert
3309
3310
3311 class ModelArgs(Type):
3312 _toSchema = {'model_tag': 'model-tag'}
3313 _toPy = {'model-tag': 'model_tag'}
3314 def __init__(self, model_tag=None):
3315 '''
3316 model_tag : str
3317 '''
3318 self.model_tag = model_tag
3319
3320
3321 class ModelCreateArgs(Type):
3322 _toSchema = {'account': 'Account', 'ownertag': 'OwnerTag', 'config': 'Config'}
3323 _toPy = {'Account': 'account', 'OwnerTag': 'ownertag', 'Config': 'config'}
3324 def __init__(self, account=None, config=None, ownertag=None):
3325 '''
3326 account : typing.Mapping[str, typing.Any]
3327 config : typing.Mapping[str, typing.Any]
3328 ownertag : str
3329 '''
3330 self.account = account
3331 self.config = config
3332 self.ownertag = ownertag
3333
3334
3335 class ModelInfoResult(Type):
3336 _toSchema = {'result': 'result', 'error': 'error'}
3337 _toPy = {'result': 'result', 'error': 'error'}
3338 def __init__(self, error=None, result=None):
3339 '''
3340 error : Error
3341 result : ModelInfo
3342 '''
3343 self.error = Error.from_json(error) if error else None
3344 self.result = ModelInfo.from_json(result) if result else None
3345
3346
3347 class ModelInfoResults(Type):
3348 _toSchema = {'results': 'results'}
3349 _toPy = {'results': 'results'}
3350 def __init__(self, results=None):
3351 '''
3352 results : typing.Sequence[~ModelInfoResult]
3353 '''
3354 self.results = [ModelInfoResult.from_json(o) for o in results or []]
3355
3356
3357 class ModelSkeletonConfigArgs(Type):
3358 _toSchema = {'region': 'Region', 'provider': 'Provider'}
3359 _toPy = {'Provider': 'provider', 'Region': 'region'}
3360 def __init__(self, provider=None, region=None):
3361 '''
3362 provider : str
3363 region : str
3364 '''
3365 self.provider = provider
3366 self.region = region
3367
3368
3369 class ModifyModelAccess(Type):
3370 _toSchema = {'action': 'action', 'model_tag': 'model-tag', 'user_tag': 'user-tag', 'access': 'access'}
3371 _toPy = {'user-tag': 'user_tag', 'action': 'action', 'model-tag': 'model_tag', 'access': 'access'}
3372 def __init__(self, access=None, action=None, model_tag=None, user_tag=None):
3373 '''
3374 access : str
3375 action : str
3376 model_tag : str
3377 user_tag : str
3378 '''
3379 self.access = access
3380 self.action = action
3381 self.model_tag = model_tag
3382 self.user_tag = user_tag
3383
3384
3385 class ModifyModelAccessRequest(Type):
3386 _toSchema = {'changes': 'changes'}
3387 _toPy = {'changes': 'changes'}
3388 def __init__(self, changes=None):
3389 '''
3390 changes : typing.Sequence[~ModifyModelAccess]
3391 '''
3392 self.changes = [ModifyModelAccess.from_json(o) for o in changes or []]
3393
3394
3395 class ConstraintsResult(Type):
3396 _toSchema = {'constraints': 'Constraints', 'error': 'Error'}
3397 _toPy = {'Constraints': 'constraints', 'Error': 'error'}
3398 def __init__(self, constraints=None, error=None):
3399 '''
3400 constraints : Value
3401 error : Error
3402 '''
3403 self.constraints = Value.from_json(constraints) if constraints else None
3404 self.error = Error.from_json(error) if error else None
3405
3406
3407 class ConstraintsResults(Type):
3408 _toSchema = {'results': 'Results'}
3409 _toPy = {'Results': 'results'}
3410 def __init__(self, results=None):
3411 '''
3412 results : typing.Sequence[~ConstraintsResult]
3413 '''
3414 self.results = [ConstraintsResult.from_json(o) for o in results or []]
3415
3416
3417 class ContainerConfig(Type):
3418 _toSchema = {'allowlxcloopmounts': 'AllowLXCLoopMounts', 'updatebehavior': 'UpdateBehavior', 'aptmirror': 'AptMirror', 'authorizedkeys': 'AuthorizedKeys', 'sslhostnameverification': 'SSLHostnameVerification', 'aptproxy': 'AptProxy', 'providertype': 'ProviderType', 'proxy': 'Proxy'}
3419 _toPy = {'UpdateBehavior': 'updatebehavior', 'SSLHostnameVerification': 'sslhostnameverification', 'AptMirror': 'aptmirror', 'Proxy': 'proxy', 'AptProxy': 'aptproxy', 'AuthorizedKeys': 'authorizedkeys', 'AllowLXCLoopMounts': 'allowlxcloopmounts', 'ProviderType': 'providertype'}
3420 def __init__(self, allowlxcloopmounts=None, aptmirror=None, aptproxy=None, authorizedkeys=None, providertype=None, proxy=None, sslhostnameverification=None, updatebehavior=None):
3421 '''
3422 allowlxcloopmounts : bool
3423 aptmirror : str
3424 aptproxy : Settings
3425 authorizedkeys : str
3426 providertype : str
3427 proxy : Settings
3428 sslhostnameverification : bool
3429 updatebehavior : UpdateBehavior
3430 '''
3431 self.allowlxcloopmounts = allowlxcloopmounts
3432 self.aptmirror = aptmirror
3433 self.aptproxy = Settings.from_json(aptproxy) if aptproxy else None
3434 self.authorizedkeys = authorizedkeys
3435 self.providertype = providertype
3436 self.proxy = Settings.from_json(proxy) if proxy else None
3437 self.sslhostnameverification = sslhostnameverification
3438 self.updatebehavior = UpdateBehavior.from_json(updatebehavior) if updatebehavior else None
3439
3440
3441 class ContainerManagerConfig(Type):
3442 _toSchema = {'managerconfig': 'ManagerConfig'}
3443 _toPy = {'ManagerConfig': 'managerconfig'}
3444 def __init__(self, managerconfig=None):
3445 '''
3446 managerconfig : typing.Mapping[str, str]
3447 '''
3448 self.managerconfig = managerconfig
3449
3450
3451 class ContainerManagerConfigParams(Type):
3452 _toSchema = {'type_': 'Type'}
3453 _toPy = {'Type': 'type_'}
3454 def __init__(self, type_=None):
3455 '''
3456 type_ : str
3457 '''
3458 self.type_ = type_
3459
3460
3461 class DistributionGroupResult(Type):
3462 _toSchema = {'result': 'Result', 'error': 'Error'}
3463 _toPy = {'Result': 'result', 'Error': 'error'}
3464 def __init__(self, error=None, result=None):
3465 '''
3466 error : Error
3467 result : typing.Sequence[str]
3468 '''
3469 self.error = Error.from_json(error) if error else None
3470 self.result = result
3471
3472
3473 class DistributionGroupResults(Type):
3474 _toSchema = {'results': 'Results'}
3475 _toPy = {'Results': 'results'}
3476 def __init__(self, results=None):
3477 '''
3478 results : typing.Sequence[~DistributionGroupResult]
3479 '''
3480 self.results = [DistributionGroupResult.from_json(o) for o in results or []]
3481
3482
3483 class InstanceInfo(Type):
3484 _toSchema = {'networkconfig': 'NetworkConfig', 'nonce': 'Nonce', 'characteristics': 'Characteristics', 'volumeattachments': 'VolumeAttachments', 'instanceid': 'InstanceId', 'tag': 'Tag', 'volumes': 'Volumes'}
3485 _toPy = {'Characteristics': 'characteristics', 'InstanceId': 'instanceid', 'Volumes': 'volumes', 'Nonce': 'nonce', 'VolumeAttachments': 'volumeattachments', 'Tag': 'tag', 'NetworkConfig': 'networkconfig'}
3486 def __init__(self, characteristics=None, instanceid=None, networkconfig=None, nonce=None, tag=None, volumeattachments=None, volumes=None):
3487 '''
3488 characteristics : HardwareCharacteristics
3489 instanceid : str
3490 networkconfig : typing.Sequence[~NetworkConfig]
3491 nonce : str
3492 tag : str
3493 volumeattachments : typing.Mapping[str, ~VolumeAttachmentInfo]
3494 volumes : typing.Sequence[~Volume]
3495 '''
3496 self.characteristics = HardwareCharacteristics.from_json(characteristics) if characteristics else None
3497 self.instanceid = instanceid
3498 self.networkconfig = [NetworkConfig.from_json(o) for o in networkconfig or []]
3499 self.nonce = nonce
3500 self.tag = tag
3501 self.volumeattachments = {k: VolumeAttachmentInfo.from_json(v) for k, v in (volumeattachments or dict()).items()}
3502 self.volumes = [Volume.from_json(o) for o in volumes or []]
3503
3504
3505 class InstancesInfo(Type):
3506 _toSchema = {'machines': 'Machines'}
3507 _toPy = {'Machines': 'machines'}
3508 def __init__(self, machines=None):
3509 '''
3510 machines : typing.Sequence[~InstanceInfo]
3511 '''
3512 self.machines = [InstanceInfo.from_json(o) for o in machines or []]
3513
3514
3515 class MachineContainers(Type):
3516 _toSchema = {'containertypes': 'ContainerTypes', 'machinetag': 'MachineTag'}
3517 _toPy = {'MachineTag': 'machinetag', 'ContainerTypes': 'containertypes'}
3518 def __init__(self, containertypes=None, machinetag=None):
3519 '''
3520 containertypes : typing.Sequence[str]
3521 machinetag : str
3522 '''
3523 self.containertypes = containertypes
3524 self.machinetag = machinetag
3525
3526
3527 class MachineContainersParams(Type):
3528 _toSchema = {'params': 'Params'}
3529 _toPy = {'Params': 'params'}
3530 def __init__(self, params=None):
3531 '''
3532 params : typing.Sequence[~MachineContainers]
3533 '''
3534 self.params = [MachineContainers.from_json(o) for o in params or []]
3535
3536
3537 class MachineNetworkConfigResult(Type):
3538 _toSchema = {'info': 'Info', 'error': 'Error'}
3539 _toPy = {'Error': 'error', 'Info': 'info'}
3540 def __init__(self, error=None, info=None):
3541 '''
3542 error : Error
3543 info : typing.Sequence[~NetworkConfig]
3544 '''
3545 self.error = Error.from_json(error) if error else None
3546 self.info = [NetworkConfig.from_json(o) for o in info or []]
3547
3548
3549 class MachineNetworkConfigResults(Type):
3550 _toSchema = {'results': 'Results'}
3551 _toPy = {'Results': 'results'}
3552 def __init__(self, results=None):
3553 '''
3554 results : typing.Sequence[~MachineNetworkConfigResult]
3555 '''
3556 self.results = [MachineNetworkConfigResult.from_json(o) for o in results or []]
3557
3558
3559 class ProvisioningInfo(Type):
3560 _toSchema = {'jobs': 'Jobs', 'series': 'Series', 'imagemetadata': 'ImageMetadata', 'placement': 'Placement', 'subnetstozones': 'SubnetsToZones', 'constraints': 'Constraints', 'tags': 'Tags', 'endpointbindings': 'EndpointBindings', 'volumes': 'Volumes'}
3561 _toPy = {'Constraints': 'constraints', 'ImageMetadata': 'imagemetadata', 'SubnetsToZones': 'subnetstozones', 'Series': 'series', 'Volumes': 'volumes', 'Tags': 'tags', 'EndpointBindings': 'endpointbindings', 'Placement': 'placement', 'Jobs': 'jobs'}
3562 def __init__(self, constraints=None, endpointbindings=None, imagemetadata=None, jobs=None, placement=None, series=None, subnetstozones=None, tags=None, volumes=None):
3563 '''
3564 constraints : Value
3565 endpointbindings : typing.Mapping[str, str]
3566 imagemetadata : typing.Sequence[~CloudImageMetadata]
3567 jobs : typing.Sequence[str]
3568 placement : str
3569 series : str
3570 subnetstozones : typing.Sequence[str]
3571 tags : typing.Mapping[str, str]
3572 volumes : typing.Sequence[~VolumeParams]
3573 '''
3574 self.constraints = Value.from_json(constraints) if constraints else None
3575 self.endpointbindings = endpointbindings
3576 self.imagemetadata = [CloudImageMetadata.from_json(o) for o in imagemetadata or []]
3577 self.jobs = jobs
3578 self.placement = placement
3579 self.series = series
3580 self.subnetstozones = subnetstozones
3581 self.tags = tags
3582 self.volumes = [VolumeParams.from_json(o) for o in volumes or []]
3583
3584
3585 class ProvisioningInfoResult(Type):
3586 _toSchema = {'result': 'Result', 'error': 'Error'}
3587 _toPy = {'Result': 'result', 'Error': 'error'}
3588 def __init__(self, error=None, result=None):
3589 '''
3590 error : Error
3591 result : ProvisioningInfo
3592 '''
3593 self.error = Error.from_json(error) if error else None
3594 self.result = ProvisioningInfo.from_json(result) if result else None
3595
3596
3597 class ProvisioningInfoResults(Type):
3598 _toSchema = {'results': 'Results'}
3599 _toPy = {'Results': 'results'}
3600 def __init__(self, results=None):
3601 '''
3602 results : typing.Sequence[~ProvisioningInfoResult]
3603 '''
3604 self.results = [ProvisioningInfoResult.from_json(o) for o in results or []]
3605
3606
3607 class Settings(Type):
3608 _toSchema = {'ftp': 'Ftp', 'noproxy': 'NoProxy', 'http': 'Http', 'https': 'Https'}
3609 _toPy = {'Http': 'http', 'Https': 'https', 'NoProxy': 'noproxy', 'Ftp': 'ftp'}
3610 def __init__(self, ftp=None, http=None, https=None, noproxy=None):
3611 '''
3612 ftp : str
3613 http : str
3614 https : str
3615 noproxy : str
3616 '''
3617 self.ftp = ftp
3618 self.http = http
3619 self.https = https
3620 self.noproxy = noproxy
3621
3622
3623 class ToolsResult(Type):
3624 _toSchema = {'toolslist': 'ToolsList', 'disablesslhostnameverification': 'DisableSSLHostnameVerification', 'error': 'Error'}
3625 _toPy = {'Error': 'error', 'DisableSSLHostnameVerification': 'disablesslhostnameverification', 'ToolsList': 'toolslist'}
3626 def __init__(self, disablesslhostnameverification=None, error=None, toolslist=None):
3627 '''
3628 disablesslhostnameverification : bool
3629 error : Error
3630 toolslist : typing.Sequence[~Tools]
3631 '''
3632 self.disablesslhostnameverification = disablesslhostnameverification
3633 self.error = Error.from_json(error) if error else None
3634 self.toolslist = [Tools.from_json(o) for o in toolslist or []]
3635
3636
3637 class ToolsResults(Type):
3638 _toSchema = {'results': 'Results'}
3639 _toPy = {'Results': 'results'}
3640 def __init__(self, results=None):
3641 '''
3642 results : typing.Sequence[~ToolsResult]
3643 '''
3644 self.results = [ToolsResult.from_json(o) for o in results or []]
3645
3646
3647 class UpdateBehavior(Type):
3648 _toSchema = {'enableosupgrade': 'EnableOSUpgrade', 'enableosrefreshupdate': 'EnableOSRefreshUpdate'}
3649 _toPy = {'EnableOSRefreshUpdate': 'enableosrefreshupdate', 'EnableOSUpgrade': 'enableosupgrade'}
3650 def __init__(self, enableosrefreshupdate=None, enableosupgrade=None):
3651 '''
3652 enableosrefreshupdate : bool
3653 enableosupgrade : bool
3654 '''
3655 self.enableosrefreshupdate = enableosrefreshupdate
3656 self.enableosupgrade = enableosupgrade
3657
3658
3659 class Volume(Type):
3660 _toSchema = {'volumetag': 'volumetag', 'info': 'info'}
3661 _toPy = {'volumetag': 'volumetag', 'info': 'info'}
3662 def __init__(self, info=None, volumetag=None):
3663 '''
3664 info : VolumeInfo
3665 volumetag : str
3666 '''
3667 self.info = VolumeInfo.from_json(info) if info else None
3668 self.volumetag = volumetag
3669
3670
3671 class VolumeAttachmentInfo(Type):
3672 _toSchema = {'read_only': 'read-only', 'devicelink': 'devicelink', 'busaddress': 'busaddress', 'devicename': 'devicename'}
3673 _toPy = {'devicelink': 'devicelink', 'busaddress': 'busaddress', 'devicename': 'devicename', 'read-only': 'read_only'}
3674 def __init__(self, busaddress=None, devicelink=None, devicename=None, read_only=None):
3675 '''
3676 busaddress : str
3677 devicelink : str
3678 devicename : str
3679 read_only : bool
3680 '''
3681 self.busaddress = busaddress
3682 self.devicelink = devicelink
3683 self.devicename = devicename
3684 self.read_only = read_only
3685
3686
3687 class VolumeAttachmentParams(Type):
3688 _toSchema = {'volumetag': 'volumetag', 'read_only': 'read-only', 'provider': 'provider', 'volumeid': 'volumeid', 'instanceid': 'instanceid', 'machinetag': 'machinetag'}
3689 _toPy = {'volumetag': 'volumetag', 'provider': 'provider', 'read-only': 'read_only', 'volumeid': 'volumeid', 'instanceid': 'instanceid', 'machinetag': 'machinetag'}
3690 def __init__(self, instanceid=None, machinetag=None, provider=None, read_only=None, volumeid=None, volumetag=None):
3691 '''
3692 instanceid : str
3693 machinetag : str
3694 provider : str
3695 read_only : bool
3696 volumeid : str
3697 volumetag : str
3698 '''
3699 self.instanceid = instanceid
3700 self.machinetag = machinetag
3701 self.provider = provider
3702 self.read_only = read_only
3703 self.volumeid = volumeid
3704 self.volumetag = volumetag
3705
3706
3707 class VolumeInfo(Type):
3708 _toSchema = {'hardwareid': 'hardwareid', 'persistent': 'persistent', 'size': 'size', 'volumeid': 'volumeid'}
3709 _toPy = {'hardwareid': 'hardwareid', 'persistent': 'persistent', 'size': 'size', 'volumeid': 'volumeid'}
3710 def __init__(self, hardwareid=None, persistent=None, size=None, volumeid=None):
3711 '''
3712 hardwareid : str
3713 persistent : bool
3714 size : int
3715 volumeid : str
3716 '''
3717 self.hardwareid = hardwareid
3718 self.persistent = persistent
3719 self.size = size
3720 self.volumeid = volumeid
3721
3722
3723 class VolumeParams(Type):
3724 _toSchema = {'attachment': 'attachment', 'attributes': 'attributes', 'size': 'size', 'volumetag': 'volumetag', 'tags': 'tags', 'provider': 'provider'}
3725 _toPy = {'attachment': 'attachment', 'attributes': 'attributes', 'size': 'size', 'volumetag': 'volumetag', 'tags': 'tags', 'provider': 'provider'}
3726 def __init__(self, attachment=None, attributes=None, provider=None, size=None, tags=None, volumetag=None):
3727 '''
3728 attachment : VolumeAttachmentParams
3729 attributes : typing.Mapping[str, typing.Any]
3730 provider : str
3731 size : int
3732 tags : typing.Mapping[str, str]
3733 volumetag : str
3734 '''
3735 self.attachment = VolumeAttachmentParams.from_json(attachment) if attachment else None
3736 self.attributes = attributes
3737 self.provider = provider
3738 self.size = size
3739 self.tags = tags
3740 self.volumetag = volumetag
3741
3742
3743 class WatchContainer(Type):
3744 _toSchema = {'machinetag': 'MachineTag', 'containertype': 'ContainerType'}
3745 _toPy = {'MachineTag': 'machinetag', 'ContainerType': 'containertype'}
3746 def __init__(self, containertype=None, machinetag=None):
3747 '''
3748 containertype : str
3749 machinetag : str
3750 '''
3751 self.containertype = containertype
3752 self.machinetag = machinetag
3753
3754
3755 class WatchContainers(Type):
3756 _toSchema = {'params': 'Params'}
3757 _toPy = {'Params': 'params'}
3758 def __init__(self, params=None):
3759 '''
3760 params : typing.Sequence[~WatchContainer]
3761 '''
3762 self.params = [WatchContainer.from_json(o) for o in params or []]
3763
3764
3765 class ProxyConfig(Type):
3766 _toSchema = {'ftp': 'FTP', 'noproxy': 'NoProxy', 'http': 'HTTP', 'https': 'HTTPS'}
3767 _toPy = {'NoProxy': 'noproxy', 'FTP': 'ftp', 'HTTPS': 'https', 'HTTP': 'http'}
3768 def __init__(self, ftp=None, http=None, https=None, noproxy=None):
3769 '''
3770 ftp : str
3771 http : str
3772 https : str
3773 noproxy : str
3774 '''
3775 self.ftp = ftp
3776 self.http = http
3777 self.https = https
3778 self.noproxy = noproxy
3779
3780
3781 class ProxyConfigResult(Type):
3782 _toSchema = {'proxysettings': 'ProxySettings', 'aptproxysettings': 'APTProxySettings', 'error': 'Error'}
3783 _toPy = {'ProxySettings': 'proxysettings', 'APTProxySettings': 'aptproxysettings', 'Error': 'error'}
3784 def __init__(self, aptproxysettings=None, error=None, proxysettings=None):
3785 '''
3786 aptproxysettings : ProxyConfig
3787 error : Error
3788 proxysettings : ProxyConfig
3789 '''
3790 self.aptproxysettings = ProxyConfig.from_json(aptproxysettings) if aptproxysettings else None
3791 self.error = Error.from_json(error) if error else None
3792 self.proxysettings = ProxyConfig.from_json(proxysettings) if proxysettings else None
3793
3794
3795 class ProxyConfigResults(Type):
3796 _toSchema = {'results': 'Results'}
3797 _toPy = {'Results': 'results'}
3798 def __init__(self, results=None):
3799 '''
3800 results : typing.Sequence[~ProxyConfigResult]
3801 '''
3802 self.results = [ProxyConfigResult.from_json(o) for o in results or []]
3803
3804
3805 class RebootActionResult(Type):
3806 _toSchema = {'result': 'result', 'error': 'error'}
3807 _toPy = {'result': 'result', 'error': 'error'}
3808 def __init__(self, error=None, result=None):
3809 '''
3810 error : Error
3811 result : str
3812 '''
3813 self.error = Error.from_json(error) if error else None
3814 self.result = result
3815
3816
3817 class RebootActionResults(Type):
3818 _toSchema = {'results': 'results'}
3819 _toPy = {'results': 'results'}
3820 def __init__(self, results=None):
3821 '''
3822 results : typing.Sequence[~RebootActionResult]
3823 '''
3824 self.results = [RebootActionResult.from_json(o) for o in results or []]
3825
3826
3827 class RelationUnitsChange(Type):
3828 _toSchema = {'departed': 'Departed', 'changed': 'Changed'}
3829 _toPy = {'Changed': 'changed', 'Departed': 'departed'}
3830 def __init__(self, changed=None, departed=None):
3831 '''
3832 changed : typing.Mapping[str, ~UnitSettings]
3833 departed : typing.Sequence[str]
3834 '''
3835 self.changed = {k: UnitSettings.from_json(v) for k, v in (changed or dict()).items()}
3836 self.departed = departed
3837
3838
3839 class RelationUnitsWatchResult(Type):
3840 _toSchema = {'changes': 'Changes', 'relationunitswatcherid': 'RelationUnitsWatcherId', 'error': 'Error'}
3841 _toPy = {'Changes': 'changes', 'RelationUnitsWatcherId': 'relationunitswatcherid', 'Error': 'error'}
3842 def __init__(self, changes=None, error=None, relationunitswatcherid=None):
3843 '''
3844 changes : RelationUnitsChange
3845 error : Error
3846 relationunitswatcherid : str
3847 '''
3848 self.changes = RelationUnitsChange.from_json(changes) if changes else None
3849 self.error = Error.from_json(error) if error else None
3850 self.relationunitswatcherid = relationunitswatcherid
3851
3852
3853 class UnitSettings(Type):
3854 _toSchema = {'version': 'Version'}
3855 _toPy = {'Version': 'version'}
3856 def __init__(self, version=None):
3857 '''
3858 version : int
3859 '''
3860 self.version = version
3861
3862
3863 class RetryStrategy(Type):
3864 _toSchema = {'jitterretrytime': 'JitterRetryTime', 'shouldretry': 'ShouldRetry', 'minretrytime': 'MinRetryTime', 'retrytimefactor': 'RetryTimeFactor', 'maxretrytime': 'MaxRetryTime'}
3865 _toPy = {'MinRetryTime': 'minretrytime', 'JitterRetryTime': 'jitterretrytime', 'RetryTimeFactor': 'retrytimefactor', 'MaxRetryTime': 'maxretrytime', 'ShouldRetry': 'shouldretry'}
3866 def __init__(self, jitterretrytime=None, maxretrytime=None, minretrytime=None, retrytimefactor=None, shouldretry=None):
3867 '''
3868 jitterretrytime : bool
3869 maxretrytime : int
3870 minretrytime : int
3871 retrytimefactor : int
3872 shouldretry : bool
3873 '''
3874 self.jitterretrytime = jitterretrytime
3875 self.maxretrytime = maxretrytime
3876 self.minretrytime = minretrytime
3877 self.retrytimefactor = retrytimefactor
3878 self.shouldretry = shouldretry
3879
3880
3881 class RetryStrategyResult(Type):
3882 _toSchema = {'result': 'Result', 'error': 'Error'}
3883 _toPy = {'Result': 'result', 'Error': 'error'}
3884 def __init__(self, error=None, result=None):
3885 '''
3886 error : Error
3887 result : RetryStrategy
3888 '''
3889 self.error = Error.from_json(error) if error else None
3890 self.result = RetryStrategy.from_json(result) if result else None
3891
3892
3893 class RetryStrategyResults(Type):
3894 _toSchema = {'results': 'Results'}
3895 _toPy = {'Results': 'results'}
3896 def __init__(self, results=None):
3897 '''
3898 results : typing.Sequence[~RetryStrategyResult]
3899 '''
3900 self.results = [RetryStrategyResult.from_json(o) for o in results or []]
3901
3902
3903 class SSHAddressResult(Type):
3904 _toSchema = {'address': 'address', 'error': 'error'}
3905 _toPy = {'address': 'address', 'error': 'error'}
3906 def __init__(self, address=None, error=None):
3907 '''
3908 address : str
3909 error : Error
3910 '''
3911 self.address = address
3912 self.error = Error.from_json(error) if error else None
3913
3914
3915 class SSHAddressResults(Type):
3916 _toSchema = {'results': 'results'}
3917 _toPy = {'results': 'results'}
3918 def __init__(self, results=None):
3919 '''
3920 results : typing.Sequence[~SSHAddressResult]
3921 '''
3922 self.results = [SSHAddressResult.from_json(o) for o in results or []]
3923
3924
3925 class SSHProxyResult(Type):
3926 _toSchema = {'use_proxy': 'use-proxy'}
3927 _toPy = {'use-proxy': 'use_proxy'}
3928 def __init__(self, use_proxy=None):
3929 '''
3930 use_proxy : bool
3931 '''
3932 self.use_proxy = use_proxy
3933
3934
3935 class SSHPublicKeysResult(Type):
3936 _toSchema = {'public_keys': 'public-keys', 'error': 'error'}
3937 _toPy = {'public-keys': 'public_keys', 'error': 'error'}
3938 def __init__(self, error=None, public_keys=None):
3939 '''
3940 error : Error
3941 public_keys : typing.Sequence[str]
3942 '''
3943 self.error = Error.from_json(error) if error else None
3944 self.public_keys = public_keys
3945
3946
3947 class SSHPublicKeysResults(Type):
3948 _toSchema = {'results': 'results'}
3949 _toPy = {'results': 'results'}
3950 def __init__(self, results=None):
3951 '''
3952 results : typing.Sequence[~SSHPublicKeysResult]
3953 '''
3954 self.results = [SSHPublicKeysResult.from_json(o) for o in results or []]
3955
3956
3957 class SingularClaim(Type):
3958 _toSchema = {'controllertag': 'ControllerTag', 'duration': 'Duration', 'modeltag': 'ModelTag'}
3959 _toPy = {'ModelTag': 'modeltag', 'ControllerTag': 'controllertag', 'Duration': 'duration'}
3960 def __init__(self, controllertag=None, duration=None, modeltag=None):
3961 '''
3962 controllertag : str
3963 duration : int
3964 modeltag : str
3965 '''
3966 self.controllertag = controllertag
3967 self.duration = duration
3968 self.modeltag = modeltag
3969
3970
3971 class SingularClaims(Type):
3972 _toSchema = {'claims': 'Claims'}
3973 _toPy = {'Claims': 'claims'}
3974 def __init__(self, claims=None):
3975 '''
3976 claims : typing.Sequence[~SingularClaim]
3977 '''
3978 self.claims = [SingularClaim.from_json(o) for o in claims or []]
3979
3980
3981 class ListSpacesResults(Type):
3982 _toSchema = {'results': 'Results'}
3983 _toPy = {'Results': 'results'}
3984 def __init__(self, results=None):
3985 '''
3986 results : typing.Sequence[~Space]
3987 '''
3988 self.results = [Space.from_json(o) for o in results or []]
3989
3990
3991 class Space(Type):
3992 _toSchema = {'subnets': 'Subnets', 'error': 'Error', 'name': 'Name'}
3993 _toPy = {'Subnets': 'subnets', 'Error': 'error', 'Name': 'name'}
3994 def __init__(self, error=None, name=None, subnets=None):
3995 '''
3996 error : Error
3997 name : str
3998 subnets : typing.Sequence[~Subnet]
3999 '''
4000 self.error = Error.from_json(error) if error else None
4001 self.name = name
4002 self.subnets = [Subnet.from_json(o) for o in subnets or []]
4003
4004
4005 class StatusHistoryPruneArgs(Type):
4006 _toSchema = {'maxhistorytime': 'MaxHistoryTime', 'maxhistorymb': 'MaxHistoryMB'}
4007 _toPy = {'MaxHistoryTime': 'maxhistorytime', 'MaxHistoryMB': 'maxhistorymb'}
4008 def __init__(self, maxhistorymb=None, maxhistorytime=None):
4009 '''
4010 maxhistorymb : int
4011 maxhistorytime : int
4012 '''
4013 self.maxhistorymb = maxhistorymb
4014 self.maxhistorytime = maxhistorytime
4015
4016
4017 class FilesystemAttachmentInfo(Type):
4018 _toSchema = {'mountpoint': 'mountpoint', 'read_only': 'read-only'}
4019 _toPy = {'mountpoint': 'mountpoint', 'read-only': 'read_only'}
4020 def __init__(self, mountpoint=None, read_only=None):
4021 '''
4022 mountpoint : str
4023 read_only : bool
4024 '''
4025 self.mountpoint = mountpoint
4026 self.read_only = read_only
4027
4028
4029 class FilesystemDetails(Type):
4030 _toSchema = {'machineattachments': 'machineattachments', 'info': 'info', 'volumetag': 'volumetag', 'filesystemtag': 'filesystemtag', 'storage': 'storage', 'status': 'status'}
4031 _toPy = {'machineattachments': 'machineattachments', 'info': 'info', 'volumetag': 'volumetag', 'filesystemtag': 'filesystemtag', 'storage': 'storage', 'status': 'status'}
4032 def __init__(self, filesystemtag=None, info=None, machineattachments=None, status=None, storage=None, volumetag=None):
4033 '''
4034 filesystemtag : str
4035 info : FilesystemInfo
4036 machineattachments : typing.Mapping[str, ~FilesystemAttachmentInfo]
4037 status : EntityStatus
4038 storage : StorageDetails
4039 volumetag : str
4040 '''
4041 self.filesystemtag = filesystemtag
4042 self.info = FilesystemInfo.from_json(info) if info else None
4043 self.machineattachments = {k: FilesystemAttachmentInfo.from_json(v) for k, v in (machineattachments or dict()).items()}
4044 self.status = EntityStatus.from_json(status) if status else None
4045 self.storage = StorageDetails.from_json(storage) if storage else None
4046 self.volumetag = volumetag
4047
4048
4049 class FilesystemDetailsListResult(Type):
4050 _toSchema = {'result': 'result', 'error': 'error'}
4051 _toPy = {'result': 'result', 'error': 'error'}
4052 def __init__(self, error=None, result=None):
4053 '''
4054 error : Error
4055 result : typing.Sequence[~FilesystemDetails]
4056 '''
4057 self.error = Error.from_json(error) if error else None
4058 self.result = [FilesystemDetails.from_json(o) for o in result or []]
4059
4060
4061 class FilesystemDetailsListResults(Type):
4062 _toSchema = {'results': 'results'}
4063 _toPy = {'results': 'results'}
4064 def __init__(self, results=None):
4065 '''
4066 results : typing.Sequence[~FilesystemDetailsListResult]
4067 '''
4068 self.results = [FilesystemDetailsListResult.from_json(o) for o in results or []]
4069
4070
4071 class FilesystemFilter(Type):
4072 _toSchema = {'machines': 'machines'}
4073 _toPy = {'machines': 'machines'}
4074 def __init__(self, machines=None):
4075 '''
4076 machines : typing.Sequence[str]
4077 '''
4078 self.machines = machines
4079
4080
4081 class FilesystemFilters(Type):
4082 _toSchema = {'filters': 'filters'}
4083 _toPy = {'filters': 'filters'}
4084 def __init__(self, filters=None):
4085 '''
4086 filters : typing.Sequence[~FilesystemFilter]
4087 '''
4088 self.filters = [FilesystemFilter.from_json(o) for o in filters or []]
4089
4090
4091 class FilesystemInfo(Type):
4092 _toSchema = {'filesystemid': 'filesystemid', 'size': 'size'}
4093 _toPy = {'filesystemid': 'filesystemid', 'size': 'size'}
4094 def __init__(self, filesystemid=None, size=None):
4095 '''
4096 filesystemid : str
4097 size : int
4098 '''
4099 self.filesystemid = filesystemid
4100 self.size = size
4101
4102
4103 class StorageAddParams(Type):
4104 _toSchema = {'storage': 'storage', 'storagename': 'StorageName', 'unit': 'unit'}
4105 _toPy = {'StorageName': 'storagename', 'storage': 'storage', 'unit': 'unit'}
4106 def __init__(self, storagename=None, storage=None, unit=None):
4107 '''
4108 storagename : str
4109 storage : StorageConstraints
4110 unit : str
4111 '''
4112 self.storagename = storagename
4113 self.storage = StorageConstraints.from_json(storage) if storage else None
4114 self.unit = unit
4115
4116
4117 class StorageAttachmentDetails(Type):
4118 _toSchema = {'unittag': 'unittag', 'storagetag': 'storagetag', 'location': 'location', 'machinetag': 'machinetag'}
4119 _toPy = {'unittag': 'unittag', 'storagetag': 'storagetag', 'location': 'location', 'machinetag': 'machinetag'}
4120 def __init__(self, location=None, machinetag=None, storagetag=None, unittag=None):
4121 '''
4122 location : str
4123 machinetag : str
4124 storagetag : str
4125 unittag : str
4126 '''
4127 self.location = location
4128 self.machinetag = machinetag
4129 self.storagetag = storagetag
4130 self.unittag = unittag
4131
4132
4133 class StorageConstraints(Type):
4134 _toSchema = {'pool': 'Pool', 'size': 'Size', 'count': 'Count'}
4135 _toPy = {'Count': 'count', 'Pool': 'pool', 'Size': 'size'}
4136 def __init__(self, count=None, pool=None, size=None):
4137 '''
4138 count : int
4139 pool : str
4140 size : int
4141 '''
4142 self.count = count
4143 self.pool = pool
4144 self.size = size
4145
4146
4147 class StorageDetails(Type):
4148 _toSchema = {'persistent': 'Persistent', 'storagetag': 'storagetag', 'kind': 'kind', 'ownertag': 'ownertag', 'attachments': 'attachments', 'status': 'status'}
4149 _toPy = {'storagetag': 'storagetag', 'kind': 'kind', 'Persistent': 'persistent', 'ownertag': 'ownertag', 'attachments': 'attachments', 'status': 'status'}
4150 def __init__(self, persistent=None, attachments=None, kind=None, ownertag=None, status=None, storagetag=None):
4151 '''
4152 persistent : bool
4153 attachments : typing.Mapping[str, ~StorageAttachmentDetails]
4154 kind : int
4155 ownertag : str
4156 status : EntityStatus
4157 storagetag : str
4158 '''
4159 self.persistent = persistent
4160 self.attachments = {k: StorageAttachmentDetails.from_json(v) for k, v in (attachments or dict()).items()}
4161 self.kind = kind
4162 self.ownertag = ownertag
4163 self.status = EntityStatus.from_json(status) if status else None
4164 self.storagetag = storagetag
4165
4166
4167 class StorageDetailsListResult(Type):
4168 _toSchema = {'result': 'result', 'error': 'error'}
4169 _toPy = {'result': 'result', 'error': 'error'}
4170 def __init__(self, error=None, result=None):
4171 '''
4172 error : Error
4173 result : typing.Sequence[~StorageDetails]
4174 '''
4175 self.error = Error.from_json(error) if error else None
4176 self.result = [StorageDetails.from_json(o) for o in result or []]
4177
4178
4179 class StorageDetailsListResults(Type):
4180 _toSchema = {'results': 'results'}
4181 _toPy = {'results': 'results'}
4182 def __init__(self, results=None):
4183 '''
4184 results : typing.Sequence[~StorageDetailsListResult]
4185 '''
4186 self.results = [StorageDetailsListResult.from_json(o) for o in results or []]
4187
4188
4189 class StorageDetailsResult(Type):
4190 _toSchema = {'result': 'result', 'error': 'error'}
4191 _toPy = {'result': 'result', 'error': 'error'}
4192 def __init__(self, error=None, result=None):
4193 '''
4194 error : Error
4195 result : StorageDetails
4196 '''
4197 self.error = Error.from_json(error) if error else None
4198 self.result = StorageDetails.from_json(result) if result else None
4199
4200
4201 class StorageDetailsResults(Type):
4202 _toSchema = {'results': 'results'}
4203 _toPy = {'results': 'results'}
4204 def __init__(self, results=None):
4205 '''
4206 results : typing.Sequence[~StorageDetailsResult]
4207 '''
4208 self.results = [StorageDetailsResult.from_json(o) for o in results or []]
4209
4210
4211 class StorageFilter(Type):
4212 _toSchema = {}
4213 _toPy = {}
4214 def __init__(self):
4215 '''
4216
4217 '''
4218 pass
4219
4220
4221 class StorageFilters(Type):
4222 _toSchema = {'filters': 'filters'}
4223 _toPy = {'filters': 'filters'}
4224 def __init__(self, filters=None):
4225 '''
4226 filters : typing.Sequence[~StorageFilter]
4227 '''
4228 self.filters = [StorageFilter.from_json(o) for o in filters or []]
4229
4230
4231 class StoragePool(Type):
4232 _toSchema = {'provider': 'provider', 'attrs': 'attrs', 'name': 'name'}
4233 _toPy = {'provider': 'provider', 'attrs': 'attrs', 'name': 'name'}
4234 def __init__(self, attrs=None, name=None, provider=None):
4235 '''
4236 attrs : typing.Mapping[str, typing.Any]
4237 name : str
4238 provider : str
4239 '''
4240 self.attrs = attrs
4241 self.name = name
4242 self.provider = provider
4243
4244
4245 class StoragePoolFilter(Type):
4246 _toSchema = {'providers': 'providers', 'names': 'names'}
4247 _toPy = {'providers': 'providers', 'names': 'names'}
4248 def __init__(self, names=None, providers=None):
4249 '''
4250 names : typing.Sequence[str]
4251 providers : typing.Sequence[str]
4252 '''
4253 self.names = names
4254 self.providers = providers
4255
4256
4257 class StoragePoolFilters(Type):
4258 _toSchema = {'filters': 'filters'}
4259 _toPy = {'filters': 'filters'}
4260 def __init__(self, filters=None):
4261 '''
4262 filters : typing.Sequence[~StoragePoolFilter]
4263 '''
4264 self.filters = [StoragePoolFilter.from_json(o) for o in filters or []]
4265
4266
4267 class StoragePoolsResult(Type):
4268 _toSchema = {'error': 'error', 'storagepools': 'storagepools'}
4269 _toPy = {'error': 'error', 'storagepools': 'storagepools'}
4270 def __init__(self, error=None, storagepools=None):
4271 '''
4272 error : Error
4273 storagepools : typing.Sequence[~StoragePool]
4274 '''
4275 self.error = Error.from_json(error) if error else None
4276 self.storagepools = [StoragePool.from_json(o) for o in storagepools or []]
4277
4278
4279 class StoragePoolsResults(Type):
4280 _toSchema = {'results': 'results'}
4281 _toPy = {'results': 'results'}
4282 def __init__(self, results=None):
4283 '''
4284 results : typing.Sequence[~StoragePoolsResult]
4285 '''
4286 self.results = [StoragePoolsResult.from_json(o) for o in results or []]
4287
4288
4289 class StoragesAddParams(Type):
4290 _toSchema = {'storages': 'storages'}
4291 _toPy = {'storages': 'storages'}
4292 def __init__(self, storages=None):
4293 '''
4294 storages : typing.Sequence[~StorageAddParams]
4295 '''
4296 self.storages = [StorageAddParams.from_json(o) for o in storages or []]
4297
4298
4299 class VolumeDetails(Type):
4300 _toSchema = {'machineattachments': 'machineattachments', 'volumetag': 'volumetag', 'info': 'info', 'storage': 'storage', 'status': 'status'}
4301 _toPy = {'machineattachments': 'machineattachments', 'volumetag': 'volumetag', 'info': 'info', 'storage': 'storage', 'status': 'status'}
4302 def __init__(self, info=None, machineattachments=None, status=None, storage=None, volumetag=None):
4303 '''
4304 info : VolumeInfo
4305 machineattachments : typing.Mapping[str, ~VolumeAttachmentInfo]
4306 status : EntityStatus
4307 storage : StorageDetails
4308 volumetag : str
4309 '''
4310 self.info = VolumeInfo.from_json(info) if info else None
4311 self.machineattachments = {k: VolumeAttachmentInfo.from_json(v) for k, v in (machineattachments or dict()).items()}
4312 self.status = EntityStatus.from_json(status) if status else None
4313 self.storage = StorageDetails.from_json(storage) if storage else None
4314 self.volumetag = volumetag
4315
4316
4317 class VolumeDetailsListResult(Type):
4318 _toSchema = {'result': 'result', 'error': 'error'}
4319 _toPy = {'result': 'result', 'error': 'error'}
4320 def __init__(self, error=None, result=None):
4321 '''
4322 error : Error
4323 result : typing.Sequence[~VolumeDetails]
4324 '''
4325 self.error = Error.from_json(error) if error else None
4326 self.result = [VolumeDetails.from_json(o) for o in result or []]
4327
4328
4329 class VolumeDetailsListResults(Type):
4330 _toSchema = {'results': 'results'}
4331 _toPy = {'results': 'results'}
4332 def __init__(self, results=None):
4333 '''
4334 results : typing.Sequence[~VolumeDetailsListResult]
4335 '''
4336 self.results = [VolumeDetailsListResult.from_json(o) for o in results or []]
4337
4338
4339 class VolumeFilter(Type):
4340 _toSchema = {'machines': 'machines'}
4341 _toPy = {'machines': 'machines'}
4342 def __init__(self, machines=None):
4343 '''
4344 machines : typing.Sequence[str]
4345 '''
4346 self.machines = machines
4347
4348
4349 class VolumeFilters(Type):
4350 _toSchema = {'filters': 'filters'}
4351 _toPy = {'filters': 'filters'}
4352 def __init__(self, filters=None):
4353 '''
4354 filters : typing.Sequence[~VolumeFilter]
4355 '''
4356 self.filters = [VolumeFilter.from_json(o) for o in filters or []]
4357
4358
4359 class BlockDeviceResult(Type):
4360 _toSchema = {'result': 'result', 'error': 'error'}
4361 _toPy = {'result': 'result', 'error': 'error'}
4362 def __init__(self, error=None, result=None):
4363 '''
4364 error : Error
4365 result : BlockDevice
4366 '''
4367 self.error = Error.from_json(error) if error else None
4368 self.result = BlockDevice.from_json(result) if result else None
4369
4370
4371 class BlockDeviceResults(Type):
4372 _toSchema = {'results': 'results'}
4373 _toPy = {'results': 'results'}
4374 def __init__(self, results=None):
4375 '''
4376 results : typing.Sequence[~BlockDeviceResult]
4377 '''
4378 self.results = [BlockDeviceResult.from_json(o) for o in results or []]
4379
4380
4381 class Filesystem(Type):
4382 _toSchema = {'filesystemtag': 'filesystemtag', 'volumetag': 'volumetag', 'info': 'info'}
4383 _toPy = {'filesystemtag': 'filesystemtag', 'volumetag': 'volumetag', 'info': 'info'}
4384 def __init__(self, filesystemtag=None, info=None, volumetag=None):
4385 '''
4386 filesystemtag : str
4387 info : FilesystemInfo
4388 volumetag : str
4389 '''
4390 self.filesystemtag = filesystemtag
4391 self.info = FilesystemInfo.from_json(info) if info else None
4392 self.volumetag = volumetag
4393
4394
4395 class FilesystemAttachment(Type):
4396 _toSchema = {'filesystemtag': 'filesystemtag', 'info': 'info', 'machinetag': 'machinetag'}
4397 _toPy = {'filesystemtag': 'filesystemtag', 'info': 'info', 'machinetag': 'machinetag'}
4398 def __init__(self, filesystemtag=None, info=None, machinetag=None):
4399 '''
4400 filesystemtag : str
4401 info : FilesystemAttachmentInfo
4402 machinetag : str
4403 '''
4404 self.filesystemtag = filesystemtag
4405 self.info = FilesystemAttachmentInfo.from_json(info) if info else None
4406 self.machinetag = machinetag
4407
4408
4409 class FilesystemAttachmentParams(Type):
4410 _toSchema = {'filesystemtag': 'filesystemtag', 'mountpoint': 'mountpoint', 'read_only': 'read-only', 'provider': 'provider', 'filesystemid': 'filesystemid', 'instanceid': 'instanceid', 'machinetag': 'machinetag'}
4411 _toPy = {'filesystemtag': 'filesystemtag', 'mountpoint': 'mountpoint', 'provider': 'provider', 'read-only': 'read_only', 'filesystemid': 'filesystemid', 'instanceid': 'instanceid', 'machinetag': 'machinetag'}
4412 def __init__(self, filesystemid=None, filesystemtag=None, instanceid=None, machinetag=None, mountpoint=None, provider=None, read_only=None):
4413 '''
4414 filesystemid : str
4415 filesystemtag : str
4416 instanceid : str
4417 machinetag : str
4418 mountpoint : str
4419 provider : str
4420 read_only : bool
4421 '''
4422 self.filesystemid = filesystemid
4423 self.filesystemtag = filesystemtag
4424 self.instanceid = instanceid
4425 self.machinetag = machinetag
4426 self.mountpoint = mountpoint
4427 self.provider = provider
4428 self.read_only = read_only
4429
4430
4431 class FilesystemAttachmentParamsResult(Type):
4432 _toSchema = {'result': 'result', 'error': 'error'}
4433 _toPy = {'result': 'result', 'error': 'error'}
4434 def __init__(self, error=None, result=None):
4435 '''
4436 error : Error
4437 result : FilesystemAttachmentParams
4438 '''
4439 self.error = Error.from_json(error) if error else None
4440 self.result = FilesystemAttachmentParams.from_json(result) if result else None
4441
4442
4443 class FilesystemAttachmentParamsResults(Type):
4444 _toSchema = {'results': 'results'}
4445 _toPy = {'results': 'results'}
4446 def __init__(self, results=None):
4447 '''
4448 results : typing.Sequence[~FilesystemAttachmentParamsResult]
4449 '''
4450 self.results = [FilesystemAttachmentParamsResult.from_json(o) for o in results or []]
4451
4452
4453 class FilesystemAttachmentResult(Type):
4454 _toSchema = {'result': 'result', 'error': 'error'}
4455 _toPy = {'result': 'result', 'error': 'error'}
4456 def __init__(self, error=None, result=None):
4457 '''
4458 error : Error
4459 result : FilesystemAttachment
4460 '''
4461 self.error = Error.from_json(error) if error else None
4462 self.result = FilesystemAttachment.from_json(result) if result else None
4463
4464
4465 class FilesystemAttachmentResults(Type):
4466 _toSchema = {'results': 'results'}
4467 _toPy = {'results': 'results'}
4468 def __init__(self, results=None):
4469 '''
4470 results : typing.Sequence[~FilesystemAttachmentResult]
4471 '''
4472 self.results = [FilesystemAttachmentResult.from_json(o) for o in results or []]
4473
4474
4475 class FilesystemAttachments(Type):
4476 _toSchema = {'filesystemattachments': 'filesystemattachments'}
4477 _toPy = {'filesystemattachments': 'filesystemattachments'}
4478 def __init__(self, filesystemattachments=None):
4479 '''
4480 filesystemattachments : typing.Sequence[~FilesystemAttachment]
4481 '''
4482 self.filesystemattachments = [FilesystemAttachment.from_json(o) for o in filesystemattachments or []]
4483
4484
4485 class FilesystemParams(Type):
4486 _toSchema = {'attachment': 'attachment', 'attributes': 'attributes', 'size': 'size', 'volumetag': 'volumetag', 'filesystemtag': 'filesystemtag', 'tags': 'tags', 'provider': 'provider'}
4487 _toPy = {'attachment': 'attachment', 'attributes': 'attributes', 'size': 'size', 'volumetag': 'volumetag', 'filesystemtag': 'filesystemtag', 'tags': 'tags', 'provider': 'provider'}
4488 def __init__(self, attachment=None, attributes=None, filesystemtag=None, provider=None, size=None, tags=None, volumetag=None):
4489 '''
4490 attachment : FilesystemAttachmentParams
4491 attributes : typing.Mapping[str, typing.Any]
4492 filesystemtag : str
4493 provider : str
4494 size : int
4495 tags : typing.Mapping[str, str]
4496 volumetag : str
4497 '''
4498 self.attachment = FilesystemAttachmentParams.from_json(attachment) if attachment else None
4499 self.attributes = attributes
4500 self.filesystemtag = filesystemtag
4501 self.provider = provider
4502 self.size = size
4503 self.tags = tags
4504 self.volumetag = volumetag
4505
4506
4507 class FilesystemParamsResult(Type):
4508 _toSchema = {'result': 'result', 'error': 'error'}
4509 _toPy = {'result': 'result', 'error': 'error'}
4510 def __init__(self, error=None, result=None):
4511 '''
4512 error : Error
4513 result : FilesystemParams
4514 '''
4515 self.error = Error.from_json(error) if error else None
4516 self.result = FilesystemParams.from_json(result) if result else None
4517
4518
4519 class FilesystemParamsResults(Type):
4520 _toSchema = {'results': 'results'}
4521 _toPy = {'results': 'results'}
4522 def __init__(self, results=None):
4523 '''
4524 results : typing.Sequence[~FilesystemParamsResult]
4525 '''
4526 self.results = [FilesystemParamsResult.from_json(o) for o in results or []]
4527
4528
4529 class FilesystemResult(Type):
4530 _toSchema = {'result': 'result', 'error': 'error'}
4531 _toPy = {'result': 'result', 'error': 'error'}
4532 def __init__(self, error=None, result=None):
4533 '''
4534 error : Error
4535 result : Filesystem
4536 '''
4537 self.error = Error.from_json(error) if error else None
4538 self.result = Filesystem.from_json(result) if result else None
4539
4540
4541 class FilesystemResults(Type):
4542 _toSchema = {'results': 'results'}
4543 _toPy = {'results': 'results'}
4544 def __init__(self, results=None):
4545 '''
4546 results : typing.Sequence[~FilesystemResult]
4547 '''
4548 self.results = [FilesystemResult.from_json(o) for o in results or []]
4549
4550
4551 class Filesystems(Type):
4552 _toSchema = {'filesystems': 'filesystems'}
4553 _toPy = {'filesystems': 'filesystems'}
4554 def __init__(self, filesystems=None):
4555 '''
4556 filesystems : typing.Sequence[~Filesystem]
4557 '''
4558 self.filesystems = [Filesystem.from_json(o) for o in filesystems or []]
4559
4560
4561 class MachineStorageIds(Type):
4562 _toSchema = {'ids': 'ids'}
4563 _toPy = {'ids': 'ids'}
4564 def __init__(self, ids=None):
4565 '''
4566 ids : typing.Sequence[~MachineStorageId]
4567 '''
4568 self.ids = [MachineStorageId.from_json(o) for o in ids or []]
4569
4570
4571 class MachineStorageIdsWatchResults(Type):
4572 _toSchema = {'results': 'Results'}
4573 _toPy = {'Results': 'results'}
4574 def __init__(self, results=None):
4575 '''
4576 results : typing.Sequence[~MachineStorageIdsWatchResult]
4577 '''
4578 self.results = [MachineStorageIdsWatchResult.from_json(o) for o in results or []]
4579
4580
4581 class VolumeAttachment(Type):
4582 _toSchema = {'volumetag': 'volumetag', 'info': 'info', 'machinetag': 'machinetag'}
4583 _toPy = {'volumetag': 'volumetag', 'info': 'info', 'machinetag': 'machinetag'}
4584 def __init__(self, info=None, machinetag=None, volumetag=None):
4585 '''
4586 info : VolumeAttachmentInfo
4587 machinetag : str
4588 volumetag : str
4589 '''
4590 self.info = VolumeAttachmentInfo.from_json(info) if info else None
4591 self.machinetag = machinetag
4592 self.volumetag = volumetag
4593
4594
4595 class VolumeAttachmentParamsResult(Type):
4596 _toSchema = {'result': 'result', 'error': 'error'}
4597 _toPy = {'result': 'result', 'error': 'error'}
4598 def __init__(self, error=None, result=None):
4599 '''
4600 error : Error
4601 result : VolumeAttachmentParams
4602 '''
4603 self.error = Error.from_json(error) if error else None
4604 self.result = VolumeAttachmentParams.from_json(result) if result else None
4605
4606
4607 class VolumeAttachmentParamsResults(Type):
4608 _toSchema = {'results': 'results'}
4609 _toPy = {'results': 'results'}
4610 def __init__(self, results=None):
4611 '''
4612 results : typing.Sequence[~VolumeAttachmentParamsResult]
4613 '''
4614 self.results = [VolumeAttachmentParamsResult.from_json(o) for o in results or []]
4615
4616
4617 class VolumeAttachmentResult(Type):
4618 _toSchema = {'result': 'result', 'error': 'error'}
4619 _toPy = {'result': 'result', 'error': 'error'}
4620 def __init__(self, error=None, result=None):
4621 '''
4622 error : Error
4623 result : VolumeAttachment
4624 '''
4625 self.error = Error.from_json(error) if error else None
4626 self.result = VolumeAttachment.from_json(result) if result else None
4627
4628
4629 class VolumeAttachmentResults(Type):
4630 _toSchema = {'results': 'results'}
4631 _toPy = {'results': 'results'}
4632 def __init__(self, results=None):
4633 '''
4634 results : typing.Sequence[~VolumeAttachmentResult]
4635 '''
4636 self.results = [VolumeAttachmentResult.from_json(o) for o in results or []]
4637
4638
4639 class VolumeAttachments(Type):
4640 _toSchema = {'volumeattachments': 'volumeattachments'}
4641 _toPy = {'volumeattachments': 'volumeattachments'}
4642 def __init__(self, volumeattachments=None):
4643 '''
4644 volumeattachments : typing.Sequence[~VolumeAttachment]
4645 '''
4646 self.volumeattachments = [VolumeAttachment.from_json(o) for o in volumeattachments or []]
4647
4648
4649 class VolumeParamsResult(Type):
4650 _toSchema = {'result': 'result', 'error': 'error'}
4651 _toPy = {'result': 'result', 'error': 'error'}
4652 def __init__(self, error=None, result=None):
4653 '''
4654 error : Error
4655 result : VolumeParams
4656 '''
4657 self.error = Error.from_json(error) if error else None
4658 self.result = VolumeParams.from_json(result) if result else None
4659
4660
4661 class VolumeParamsResults(Type):
4662 _toSchema = {'results': 'results'}
4663 _toPy = {'results': 'results'}
4664 def __init__(self, results=None):
4665 '''
4666 results : typing.Sequence[~VolumeParamsResult]
4667 '''
4668 self.results = [VolumeParamsResult.from_json(o) for o in results or []]
4669
4670
4671 class VolumeResult(Type):
4672 _toSchema = {'result': 'result', 'error': 'error'}
4673 _toPy = {'result': 'result', 'error': 'error'}
4674 def __init__(self, error=None, result=None):
4675 '''
4676 error : Error
4677 result : Volume
4678 '''
4679 self.error = Error.from_json(error) if error else None
4680 self.result = Volume.from_json(result) if result else None
4681
4682
4683 class VolumeResults(Type):
4684 _toSchema = {'results': 'results'}
4685 _toPy = {'results': 'results'}
4686 def __init__(self, results=None):
4687 '''
4688 results : typing.Sequence[~VolumeResult]
4689 '''
4690 self.results = [VolumeResult.from_json(o) for o in results or []]
4691
4692
4693 class Volumes(Type):
4694 _toSchema = {'volumes': 'volumes'}
4695 _toPy = {'volumes': 'volumes'}
4696 def __init__(self, volumes=None):
4697 '''
4698 volumes : typing.Sequence[~Volume]
4699 '''
4700 self.volumes = [Volume.from_json(o) for o in volumes or []]
4701
4702
4703 class SpaceResult(Type):
4704 _toSchema = {'error': 'Error', 'tag': 'Tag'}
4705 _toPy = {'Tag': 'tag', 'Error': 'error'}
4706 def __init__(self, error=None, tag=None):
4707 '''
4708 error : Error
4709 tag : str
4710 '''
4711 self.error = Error.from_json(error) if error else None
4712 self.tag = tag
4713
4714
4715 class SpaceResults(Type):
4716 _toSchema = {'results': 'Results'}
4717 _toPy = {'Results': 'results'}
4718 def __init__(self, results=None):
4719 '''
4720 results : typing.Sequence[~SpaceResult]
4721 '''
4722 self.results = [SpaceResult.from_json(o) for o in results or []]
4723
4724
4725 class ZoneResult(Type):
4726 _toSchema = {'error': 'Error', 'available': 'Available', 'name': 'Name'}
4727 _toPy = {'Error': 'error', 'Available': 'available', 'Name': 'name'}
4728 def __init__(self, available=None, error=None, name=None):
4729 '''
4730 available : bool
4731 error : Error
4732 name : str
4733 '''
4734 self.available = available
4735 self.error = Error.from_json(error) if error else None
4736 self.name = name
4737
4738
4739 class ZoneResults(Type):
4740 _toSchema = {'results': 'Results'}
4741 _toPy = {'Results': 'results'}
4742 def __init__(self, results=None):
4743 '''
4744 results : typing.Sequence[~ZoneResult]
4745 '''
4746 self.results = [ZoneResult.from_json(o) for o in results or []]
4747
4748
4749 class UndertakerModelInfo(Type):
4750 _toSchema = {'globalname': 'GlobalName', 'uuid': 'UUID', 'life': 'Life', 'issystem': 'IsSystem', 'name': 'Name'}
4751 _toPy = {'GlobalName': 'globalname', 'IsSystem': 'issystem', 'Life': 'life', 'Name': 'name', 'UUID': 'uuid'}
4752 def __init__(self, globalname=None, issystem=None, life=None, name=None, uuid=None):
4753 '''
4754 globalname : str
4755 issystem : bool
4756 life : str
4757 name : str
4758 uuid : str
4759 '''
4760 self.globalname = globalname
4761 self.issystem = issystem
4762 self.life = life
4763 self.name = name
4764 self.uuid = uuid
4765
4766
4767 class UndertakerModelInfoResult(Type):
4768 _toSchema = {'result': 'Result', 'error': 'Error'}
4769 _toPy = {'Result': 'result', 'Error': 'error'}
4770 def __init__(self, error=None, result=None):
4771 '''
4772 error : Error
4773 result : UndertakerModelInfo
4774 '''
4775 self.error = Error.from_json(error) if error else None
4776 self.result = UndertakerModelInfo.from_json(result) if result else None
4777
4778
4779 class ApplicationStatusResult(Type):
4780 _toSchema = {'units': 'Units', 'application': 'Application', 'error': 'Error'}
4781 _toPy = {'Error': 'error', 'Application': 'application', 'Units': 'units'}
4782 def __init__(self, application=None, error=None, units=None):
4783 '''
4784 application : StatusResult
4785 error : Error
4786 units : typing.Mapping[str, ~StatusResult]
4787 '''
4788 self.application = StatusResult.from_json(application) if application else None
4789 self.error = Error.from_json(error) if error else None
4790 self.units = {k: StatusResult.from_json(v) for k, v in (units or dict()).items()}
4791
4792
4793 class ApplicationStatusResults(Type):
4794 _toSchema = {'results': 'Results'}
4795 _toPy = {'Results': 'results'}
4796 def __init__(self, results=None):
4797 '''
4798 results : typing.Sequence[~ApplicationStatusResult]
4799 '''
4800 self.results = [ApplicationStatusResult.from_json(o) for o in results or []]
4801
4802
4803 class CharmURL(Type):
4804 _toSchema = {'url': 'URL'}
4805 _toPy = {'URL': 'url'}
4806 def __init__(self, url=None):
4807 '''
4808 url : str
4809 '''
4810 self.url = url
4811
4812
4813 class CharmURLs(Type):
4814 _toSchema = {'urls': 'URLs'}
4815 _toPy = {'URLs': 'urls'}
4816 def __init__(self, urls=None):
4817 '''
4818 urls : typing.Sequence[~CharmURL]
4819 '''
4820 self.urls = [CharmURL.from_json(o) for o in urls or []]
4821
4822
4823 class ConfigSettingsResult(Type):
4824 _toSchema = {'settings': 'Settings', 'error': 'Error'}
4825 _toPy = {'Settings': 'settings', 'Error': 'error'}
4826 def __init__(self, error=None, settings=None):
4827 '''
4828 error : Error
4829 settings : typing.Mapping[str, typing.Any]
4830 '''
4831 self.error = Error.from_json(error) if error else None
4832 self.settings = settings
4833
4834
4835 class ConfigSettingsResults(Type):
4836 _toSchema = {'results': 'Results'}
4837 _toPy = {'Results': 'results'}
4838 def __init__(self, results=None):
4839 '''
4840 results : typing.Sequence[~ConfigSettingsResult]
4841 '''
4842 self.results = [ConfigSettingsResult.from_json(o) for o in results or []]
4843
4844
4845 class Endpoint(Type):
4846 _toSchema = {'relation': 'Relation', 'applicationname': 'ApplicationName'}
4847 _toPy = {'Relation': 'relation', 'ApplicationName': 'applicationname'}
4848 def __init__(self, applicationname=None, relation=None):
4849 '''
4850 applicationname : str
4851 relation : Relation
4852 '''
4853 self.applicationname = applicationname
4854 self.relation = Relation.from_json(relation) if relation else None
4855
4856
4857 class EntitiesCharmURL(Type):
4858 _toSchema = {'entities': 'Entities'}
4859 _toPy = {'Entities': 'entities'}
4860 def __init__(self, entities=None):
4861 '''
4862 entities : typing.Sequence[~EntityCharmURL]
4863 '''
4864 self.entities = [EntityCharmURL.from_json(o) for o in entities or []]
4865
4866
4867 class EntitiesPortRanges(Type):
4868 _toSchema = {'entities': 'Entities'}
4869 _toPy = {'Entities': 'entities'}
4870 def __init__(self, entities=None):
4871 '''
4872 entities : typing.Sequence[~EntityPortRange]
4873 '''
4874 self.entities = [EntityPortRange.from_json(o) for o in entities or []]
4875
4876
4877 class EntityCharmURL(Type):
4878 _toSchema = {'charmurl': 'CharmURL', 'tag': 'Tag'}
4879 _toPy = {'CharmURL': 'charmurl', 'Tag': 'tag'}
4880 def __init__(self, charmurl=None, tag=None):
4881 '''
4882 charmurl : str
4883 tag : str
4884 '''
4885 self.charmurl = charmurl
4886 self.tag = tag
4887
4888
4889 class EntityPortRange(Type):
4890 _toSchema = {'toport': 'ToPort', 'fromport': 'FromPort', 'protocol': 'Protocol', 'tag': 'Tag'}
4891 _toPy = {'FromPort': 'fromport', 'Tag': 'tag', 'Protocol': 'protocol', 'ToPort': 'toport'}
4892 def __init__(self, fromport=None, protocol=None, tag=None, toport=None):
4893 '''
4894 fromport : int
4895 protocol : str
4896 tag : str
4897 toport : int
4898 '''
4899 self.fromport = fromport
4900 self.protocol = protocol
4901 self.tag = tag
4902 self.toport = toport
4903
4904
4905 class GetLeadershipSettingsBulkResults(Type):
4906 _toSchema = {'results': 'Results'}
4907 _toPy = {'Results': 'results'}
4908 def __init__(self, results=None):
4909 '''
4910 results : typing.Sequence[~GetLeadershipSettingsResult]
4911 '''
4912 self.results = [GetLeadershipSettingsResult.from_json(o) for o in results or []]
4913
4914
4915 class GetLeadershipSettingsResult(Type):
4916 _toSchema = {'settings': 'Settings', 'error': 'Error'}
4917 _toPy = {'Settings': 'settings', 'Error': 'error'}
4918 def __init__(self, error=None, settings=None):
4919 '''
4920 error : Error
4921 settings : typing.Mapping[str, str]
4922 '''
4923 self.error = Error.from_json(error) if error else None
4924 self.settings = settings
4925
4926
4927 class IntResult(Type):
4928 _toSchema = {'result': 'Result', 'error': 'Error'}
4929 _toPy = {'Result': 'result', 'Error': 'error'}
4930 def __init__(self, error=None, result=None):
4931 '''
4932 error : Error
4933 result : int
4934 '''
4935 self.error = Error.from_json(error) if error else None
4936 self.result = result
4937
4938
4939 class IntResults(Type):
4940 _toSchema = {'results': 'Results'}
4941 _toPy = {'Results': 'results'}
4942 def __init__(self, results=None):
4943 '''
4944 results : typing.Sequence[~IntResult]
4945 '''
4946 self.results = [IntResult.from_json(o) for o in results or []]
4947
4948
4949 class MergeLeadershipSettingsBulkParams(Type):
4950 _toSchema = {'params': 'Params'}
4951 _toPy = {'Params': 'params'}
4952 def __init__(self, params=None):
4953 '''
4954 params : typing.Sequence[~MergeLeadershipSettingsParam]
4955 '''
4956 self.params = [MergeLeadershipSettingsParam.from_json(o) for o in params or []]
4957
4958
4959 class MergeLeadershipSettingsParam(Type):
4960 _toSchema = {'applicationtag': 'ApplicationTag', 'settings': 'Settings'}
4961 _toPy = {'Settings': 'settings', 'ApplicationTag': 'applicationtag'}
4962 def __init__(self, applicationtag=None, settings=None):
4963 '''
4964 applicationtag : str
4965 settings : typing.Mapping[str, str]
4966 '''
4967 self.applicationtag = applicationtag
4968 self.settings = settings
4969
4970
4971 class ModelResult(Type):
4972 _toSchema = {'uuid': 'UUID', 'error': 'Error', 'name': 'Name'}
4973 _toPy = {'Error': 'error', 'Name': 'name', 'UUID': 'uuid'}
4974 def __init__(self, error=None, name=None, uuid=None):
4975 '''
4976 error : Error
4977 name : str
4978 uuid : str
4979 '''
4980 self.error = Error.from_json(error) if error else None
4981 self.name = name
4982 self.uuid = uuid
4983
4984
4985 class RelationIds(Type):
4986 _toSchema = {'relationids': 'RelationIds'}
4987 _toPy = {'RelationIds': 'relationids'}
4988 def __init__(self, relationids=None):
4989 '''
4990 relationids : typing.Sequence[int]
4991 '''
4992 self.relationids = relationids
4993
4994
4995 class RelationResult(Type):
4996 _toSchema = {'key': 'Key', 'life': 'Life', 'id_': 'Id', 'endpoint': 'Endpoint', 'error': 'Error'}
4997 _toPy = {'Endpoint': 'endpoint', 'Id': 'id_', 'Error': 'error', 'Key': 'key', 'Life': 'life'}
4998 def __init__(self, endpoint=None, error=None, id_=None, key=None, life=None):
4999 '''
5000 endpoint : Endpoint
5001 error : Error
5002 id_ : int
5003 key : str
5004 life : str
5005 '''
5006 self.endpoint = Endpoint.from_json(endpoint) if endpoint else None
5007 self.error = Error.from_json(error) if error else None
5008 self.id_ = id_
5009 self.key = key
5010 self.life = life
5011
5012
5013 class RelationResults(Type):
5014 _toSchema = {'results': 'Results'}
5015 _toPy = {'Results': 'results'}
5016 def __init__(self, results=None):
5017 '''
5018 results : typing.Sequence[~RelationResult]
5019 '''
5020 self.results = [RelationResult.from_json(o) for o in results or []]
5021
5022
5023 class RelationUnit(Type):
5024 _toSchema = {'relation': 'Relation', 'unit': 'Unit'}
5025 _toPy = {'Relation': 'relation', 'Unit': 'unit'}
5026 def __init__(self, relation=None, unit=None):
5027 '''
5028 relation : str
5029 unit : str
5030 '''
5031 self.relation = relation
5032 self.unit = unit
5033
5034
5035 class RelationUnitPair(Type):
5036 _toSchema = {'localunit': 'LocalUnit', 'relation': 'Relation', 'remoteunit': 'RemoteUnit'}
5037 _toPy = {'RemoteUnit': 'remoteunit', 'Relation': 'relation', 'LocalUnit': 'localunit'}
5038 def __init__(self, localunit=None, relation=None, remoteunit=None):
5039 '''
5040 localunit : str
5041 relation : str
5042 remoteunit : str
5043 '''
5044 self.localunit = localunit
5045 self.relation = relation
5046 self.remoteunit = remoteunit
5047
5048
5049 class RelationUnitPairs(Type):
5050 _toSchema = {'relationunitpairs': 'RelationUnitPairs'}
5051 _toPy = {'RelationUnitPairs': 'relationunitpairs'}
5052 def __init__(self, relationunitpairs=None):
5053 '''
5054 relationunitpairs : typing.Sequence[~RelationUnitPair]
5055 '''
5056 self.relationunitpairs = [RelationUnitPair.from_json(o) for o in relationunitpairs or []]
5057
5058
5059 class RelationUnitSettings(Type):
5060 _toSchema = {'settings': 'Settings', 'relation': 'Relation', 'unit': 'Unit'}
5061 _toPy = {'Settings': 'settings', 'Relation': 'relation', 'Unit': 'unit'}
5062 def __init__(self, relation=None, settings=None, unit=None):
5063 '''
5064 relation : str
5065 settings : typing.Mapping[str, str]
5066 unit : str
5067 '''
5068 self.relation = relation
5069 self.settings = settings
5070 self.unit = unit
5071
5072
5073 class RelationUnits(Type):
5074 _toSchema = {'relationunits': 'RelationUnits'}
5075 _toPy = {'RelationUnits': 'relationunits'}
5076 def __init__(self, relationunits=None):
5077 '''
5078 relationunits : typing.Sequence[~RelationUnit]
5079 '''
5080 self.relationunits = [RelationUnit.from_json(o) for o in relationunits or []]
5081
5082
5083 class RelationUnitsSettings(Type):
5084 _toSchema = {'relationunits': 'RelationUnits'}
5085 _toPy = {'RelationUnits': 'relationunits'}
5086 def __init__(self, relationunits=None):
5087 '''
5088 relationunits : typing.Sequence[~RelationUnitSettings]
5089 '''
5090 self.relationunits = [RelationUnitSettings.from_json(o) for o in relationunits or []]
5091
5092
5093 class RelationUnitsWatchResults(Type):
5094 _toSchema = {'results': 'Results'}
5095 _toPy = {'Results': 'results'}
5096 def __init__(self, results=None):
5097 '''
5098 results : typing.Sequence[~RelationUnitsWatchResult]
5099 '''
5100 self.results = [RelationUnitsWatchResult.from_json(o) for o in results or []]
5101
5102
5103 class ResolvedModeResult(Type):
5104 _toSchema = {'mode': 'Mode', 'error': 'Error'}
5105 _toPy = {'Error': 'error', 'Mode': 'mode'}
5106 def __init__(self, error=None, mode=None):
5107 '''
5108 error : Error
5109 mode : str
5110 '''
5111 self.error = Error.from_json(error) if error else None
5112 self.mode = mode
5113
5114
5115 class ResolvedModeResults(Type):
5116 _toSchema = {'results': 'Results'}
5117 _toPy = {'Results': 'results'}
5118 def __init__(self, results=None):
5119 '''
5120 results : typing.Sequence[~ResolvedModeResult]
5121 '''
5122 self.results = [ResolvedModeResult.from_json(o) for o in results or []]
5123
5124
5125 class SettingsResult(Type):
5126 _toSchema = {'settings': 'Settings', 'error': 'Error'}
5127 _toPy = {'Settings': 'settings', 'Error': 'error'}
5128 def __init__(self, error=None, settings=None):
5129 '''
5130 error : Error
5131 settings : typing.Mapping[str, str]
5132 '''
5133 self.error = Error.from_json(error) if error else None
5134 self.settings = settings
5135
5136
5137 class SettingsResults(Type):
5138 _toSchema = {'results': 'Results'}
5139 _toPy = {'Results': 'results'}
5140 def __init__(self, results=None):
5141 '''
5142 results : typing.Sequence[~SettingsResult]
5143 '''
5144 self.results = [SettingsResult.from_json(o) for o in results or []]
5145
5146
5147 class StorageAttachment(Type):
5148 _toSchema = {'storagetag': 'StorageTag', 'location': 'Location', 'life': 'Life', 'unittag': 'UnitTag', 'ownertag': 'OwnerTag', 'kind': 'Kind'}
5149 _toPy = {'OwnerTag': 'ownertag', 'StorageTag': 'storagetag', 'UnitTag': 'unittag', 'Life': 'life', 'Location': 'location', 'Kind': 'kind'}
5150 def __init__(self, kind=None, life=None, location=None, ownertag=None, storagetag=None, unittag=None):
5151 '''
5152 kind : int
5153 life : str
5154 location : str
5155 ownertag : str
5156 storagetag : str
5157 unittag : str
5158 '''
5159 self.kind = kind
5160 self.life = life
5161 self.location = location
5162 self.ownertag = ownertag
5163 self.storagetag = storagetag
5164 self.unittag = unittag
5165
5166
5167 class StorageAttachmentId(Type):
5168 _toSchema = {'unittag': 'unittag', 'storagetag': 'storagetag'}
5169 _toPy = {'unittag': 'unittag', 'storagetag': 'storagetag'}
5170 def __init__(self, storagetag=None, unittag=None):
5171 '''
5172 storagetag : str
5173 unittag : str
5174 '''
5175 self.storagetag = storagetag
5176 self.unittag = unittag
5177
5178
5179 class StorageAttachmentIds(Type):
5180 _toSchema = {'ids': 'ids'}
5181 _toPy = {'ids': 'ids'}
5182 def __init__(self, ids=None):
5183 '''
5184 ids : typing.Sequence[~StorageAttachmentId]
5185 '''
5186 self.ids = [StorageAttachmentId.from_json(o) for o in ids or []]
5187
5188
5189 class StorageAttachmentIdsResult(Type):
5190 _toSchema = {'result': 'result', 'error': 'error'}
5191 _toPy = {'result': 'result', 'error': 'error'}
5192 def __init__(self, error=None, result=None):
5193 '''
5194 error : Error
5195 result : StorageAttachmentIds
5196 '''
5197 self.error = Error.from_json(error) if error else None
5198 self.result = StorageAttachmentIds.from_json(result) if result else None
5199
5200
5201 class StorageAttachmentIdsResults(Type):
5202 _toSchema = {'results': 'results'}
5203 _toPy = {'results': 'results'}
5204 def __init__(self, results=None):
5205 '''
5206 results : typing.Sequence[~StorageAttachmentIdsResult]
5207 '''
5208 self.results = [StorageAttachmentIdsResult.from_json(o) for o in results or []]
5209
5210
5211 class StorageAttachmentResult(Type):
5212 _toSchema = {'result': 'result', 'error': 'error'}
5213 _toPy = {'result': 'result', 'error': 'error'}
5214 def __init__(self, error=None, result=None):
5215 '''
5216 error : Error
5217 result : StorageAttachment
5218 '''
5219 self.error = Error.from_json(error) if error else None
5220 self.result = StorageAttachment.from_json(result) if result else None
5221
5222
5223 class StorageAttachmentResults(Type):
5224 _toSchema = {'results': 'results'}
5225 _toPy = {'results': 'results'}
5226 def __init__(self, results=None):
5227 '''
5228 results : typing.Sequence[~StorageAttachmentResult]
5229 '''
5230 self.results = [StorageAttachmentResult.from_json(o) for o in results or []]
5231
5232
5233 class StringBoolResult(Type):
5234 _toSchema = {'result': 'Result', 'ok': 'Ok', 'error': 'Error'}
5235 _toPy = {'Result': 'result', 'Error': 'error', 'Ok': 'ok'}
5236 def __init__(self, error=None, ok=None, result=None):
5237 '''
5238 error : Error
5239 ok : bool
5240 result : str
5241 '''
5242 self.error = Error.from_json(error) if error else None
5243 self.ok = ok
5244 self.result = result
5245
5246
5247 class StringBoolResults(Type):
5248 _toSchema = {'results': 'Results'}
5249 _toPy = {'Results': 'results'}
5250 def __init__(self, results=None):
5251 '''
5252 results : typing.Sequence[~StringBoolResult]
5253 '''
5254 self.results = [StringBoolResult.from_json(o) for o in results or []]
5255
5256
5257 class UnitNetworkConfig(Type):
5258 _toSchema = {'unittag': 'UnitTag', 'bindingname': 'BindingName'}
5259 _toPy = {'BindingName': 'bindingname', 'UnitTag': 'unittag'}
5260 def __init__(self, bindingname=None, unittag=None):
5261 '''
5262 bindingname : str
5263 unittag : str
5264 '''
5265 self.bindingname = bindingname
5266 self.unittag = unittag
5267
5268
5269 class UnitNetworkConfigResult(Type):
5270 _toSchema = {'info': 'Info', 'error': 'Error'}
5271 _toPy = {'Error': 'error', 'Info': 'info'}
5272 def __init__(self, error=None, info=None):
5273 '''
5274 error : Error
5275 info : typing.Sequence[~NetworkConfig]
5276 '''
5277 self.error = Error.from_json(error) if error else None
5278 self.info = [NetworkConfig.from_json(o) for o in info or []]
5279
5280
5281 class UnitNetworkConfigResults(Type):
5282 _toSchema = {'results': 'Results'}
5283 _toPy = {'Results': 'results'}
5284 def __init__(self, results=None):
5285 '''
5286 results : typing.Sequence[~UnitNetworkConfigResult]
5287 '''
5288 self.results = [UnitNetworkConfigResult.from_json(o) for o in results or []]
5289
5290
5291 class UnitsNetworkConfig(Type):
5292 _toSchema = {'args': 'Args'}
5293 _toPy = {'Args': 'args'}
5294 def __init__(self, args=None):
5295 '''
5296 args : typing.Sequence[~UnitNetworkConfig]
5297 '''
5298 self.args = [UnitNetworkConfig.from_json(o) for o in args or []]
5299
5300
5301 class EntitiesVersion(Type):
5302 _toSchema = {'agenttools': 'AgentTools'}
5303 _toPy = {'AgentTools': 'agenttools'}
5304 def __init__(self, agenttools=None):
5305 '''
5306 agenttools : typing.Sequence[~EntityVersion]
5307 '''
5308 self.agenttools = [EntityVersion.from_json(o) for o in agenttools or []]
5309
5310
5311 class EntityVersion(Type):
5312 _toSchema = {'tools': 'Tools', 'tag': 'Tag'}
5313 _toPy = {'Tag': 'tag', 'Tools': 'tools'}
5314 def __init__(self, tag=None, tools=None):
5315 '''
5316 tag : str
5317 tools : Version
5318 '''
5319 self.tag = tag
5320 self.tools = Version.from_json(tools) if tools else None
5321
5322
5323 class VersionResult(Type):
5324 _toSchema = {'error': 'Error', 'version': 'Version'}
5325 _toPy = {'Error': 'error', 'Version': 'version'}
5326 def __init__(self, error=None, version=None):
5327 '''
5328 error : Error
5329 version : Number
5330 '''
5331 self.error = Error.from_json(error) if error else None
5332 self.version = Number.from_json(version) if version else None
5333
5334
5335 class VersionResults(Type):
5336 _toSchema = {'results': 'Results'}
5337 _toPy = {'Results': 'results'}
5338 def __init__(self, results=None):
5339 '''
5340 results : typing.Sequence[~VersionResult]
5341 '''
5342 self.results = [VersionResult.from_json(o) for o in results or []]
5343
5344
5345 class AddUser(Type):
5346 _toSchema = {'model_access_permission': 'model-access-permission', 'shared_model_tags': 'shared-model-tags', 'password': 'password', 'username': 'username', 'display_name': 'display-name'}
5347 _toPy = {'model-access-permission': 'model_access_permission', 'password': 'password', 'username': 'username', 'shared-model-tags': 'shared_model_tags', 'display-name': 'display_name'}
5348 def __init__(self, display_name=None, model_access_permission=None, password=None, shared_model_tags=None, username=None):
5349 '''
5350 display_name : str
5351 model_access_permission : str
5352 password : str
5353 shared_model_tags : typing.Sequence[str]
5354 username : str
5355 '''
5356 self.display_name = display_name
5357 self.model_access_permission = model_access_permission
5358 self.password = password
5359 self.shared_model_tags = shared_model_tags
5360 self.username = username
5361
5362
5363 class AddUserResult(Type):
5364 _toSchema = {'tag': 'tag', 'error': 'error', 'secret_key': 'secret-key'}
5365 _toPy = {'error': 'error', 'tag': 'tag', 'secret-key': 'secret_key'}
5366 def __init__(self, error=None, secret_key=None, tag=None):
5367 '''
5368 error : Error
5369 secret_key : typing.Sequence[int]
5370 tag : str
5371 '''
5372 self.error = Error.from_json(error) if error else None
5373 self.secret_key = secret_key
5374 self.tag = tag
5375
5376
5377 class AddUserResults(Type):
5378 _toSchema = {'results': 'results'}
5379 _toPy = {'results': 'results'}
5380 def __init__(self, results=None):
5381 '''
5382 results : typing.Sequence[~AddUserResult]
5383 '''
5384 self.results = [AddUserResult.from_json(o) for o in results or []]
5385
5386
5387 class AddUsers(Type):
5388 _toSchema = {'users': 'users'}
5389 _toPy = {'users': 'users'}
5390 def __init__(self, users=None):
5391 '''
5392 users : typing.Sequence[~AddUser]
5393 '''
5394 self.users = [AddUser.from_json(o) for o in users or []]
5395
5396
5397 class MacaroonResult(Type):
5398 _toSchema = {'result': 'result', 'error': 'error'}
5399 _toPy = {'result': 'result', 'error': 'error'}
5400 def __init__(self, error=None, result=None):
5401 '''
5402 error : Error
5403 result : Macaroon
5404 '''
5405 self.error = Error.from_json(error) if error else None
5406 self.result = Macaroon.from_json(result) if result else None
5407
5408
5409 class MacaroonResults(Type):
5410 _toSchema = {'results': 'results'}
5411 _toPy = {'results': 'results'}
5412 def __init__(self, results=None):
5413 '''
5414 results : typing.Sequence[~MacaroonResult]
5415 '''
5416 self.results = [MacaroonResult.from_json(o) for o in results or []]
5417
5418
5419 class UserInfo(Type):
5420 _toSchema = {'date_created': 'date-created', 'last_connection': 'last-connection', 'disabled': 'disabled', 'display_name': 'display-name', 'created_by': 'created-by', 'username': 'username'}
5421 _toPy = {'last-connection': 'last_connection', 'date-created': 'date_created', 'disabled': 'disabled', 'created-by': 'created_by', 'username': 'username', 'display-name': 'display_name'}
5422 def __init__(self, created_by=None, date_created=None, disabled=None, display_name=None, last_connection=None, username=None):
5423 '''
5424 created_by : str
5425 date_created : str
5426 disabled : bool
5427 display_name : str
5428 last_connection : str
5429 username : str
5430 '''
5431 self.created_by = created_by
5432 self.date_created = date_created
5433 self.disabled = disabled
5434 self.display_name = display_name
5435 self.last_connection = last_connection
5436 self.username = username
5437
5438
5439 class UserInfoRequest(Type):
5440 _toSchema = {'include_disabled': 'include-disabled', 'entities': 'entities'}
5441 _toPy = {'include-disabled': 'include_disabled', 'entities': 'entities'}
5442 def __init__(self, entities=None, include_disabled=None):
5443 '''
5444 entities : typing.Sequence[~Entity]
5445 include_disabled : bool
5446 '''
5447 self.entities = [Entity.from_json(o) for o in entities or []]
5448 self.include_disabled = include_disabled
5449
5450
5451 class UserInfoResult(Type):
5452 _toSchema = {'result': 'result', 'error': 'error'}
5453 _toPy = {'result': 'result', 'error': 'error'}
5454 def __init__(self, error=None, result=None):
5455 '''
5456 error : Error
5457 result : UserInfo
5458 '''
5459 self.error = Error.from_json(error) if error else None
5460 self.result = UserInfo.from_json(result) if result else None
5461
5462
5463 class UserInfoResults(Type):
5464 _toSchema = {'results': 'results'}
5465 _toPy = {'results': 'results'}
5466 def __init__(self, results=None):
5467 '''
5468 results : typing.Sequence[~UserInfoResult]
5469 '''
5470 self.results = [UserInfoResult.from_json(o) for o in results or []]
5471
5472
5473 class ActionFacade(Type):
5474 name = 'Action'
5475 version = 2
5476 schema = {'definitions': {'Action': {'additionalProperties': False,
5477 'properties': {'name': {'type': 'string'},
5478 'parameters': {'patternProperties': {'.*': {'additionalProperties': True,
5479 'type': 'object'}},
5480 'type': 'object'},
5481 'receiver': {'type': 'string'},
5482 'tag': {'type': 'string'}},
5483 'required': ['tag', 'receiver', 'name'],
5484 'type': 'object'},
5485 'ActionResult': {'additionalProperties': False,
5486 'properties': {'action': {'$ref': '#/definitions/Action'},
5487 'completed': {'format': 'date-time',
5488 'type': 'string'},
5489 'enqueued': {'format': 'date-time',
5490 'type': 'string'},
5491 'error': {'$ref': '#/definitions/Error'},
5492 'message': {'type': 'string'},
5493 'output': {'patternProperties': {'.*': {'additionalProperties': True,
5494 'type': 'object'}},
5495 'type': 'object'},
5496 'started': {'format': 'date-time',
5497 'type': 'string'},
5498 'status': {'type': 'string'}},
5499 'type': 'object'},
5500 'ActionResults': {'additionalProperties': False,
5501 'properties': {'results': {'items': {'$ref': '#/definitions/ActionResult'},
5502 'type': 'array'}},
5503 'type': 'object'},
5504 'ActionSpec': {'additionalProperties': False,
5505 'properties': {'Description': {'type': 'string'},
5506 'Params': {'patternProperties': {'.*': {'additionalProperties': True,
5507 'type': 'object'}},
5508 'type': 'object'}},
5509 'required': ['Description', 'Params'],
5510 'type': 'object'},
5511 'Actions': {'additionalProperties': False,
5512 'properties': {'ActionSpecs': {'patternProperties': {'.*': {'$ref': '#/definitions/ActionSpec'}},
5513 'type': 'object'}},
5514 'required': ['ActionSpecs'],
5515 'type': 'object'},
5516 'ActionsByName': {'additionalProperties': False,
5517 'properties': {'actions': {'items': {'$ref': '#/definitions/ActionResult'},
5518 'type': 'array'},
5519 'error': {'$ref': '#/definitions/Error'},
5520 'name': {'type': 'string'}},
5521 'type': 'object'},
5522 'ActionsByNames': {'additionalProperties': False,
5523 'properties': {'actions': {'items': {'$ref': '#/definitions/ActionsByName'},
5524 'type': 'array'}},
5525 'type': 'object'},
5526 'ActionsByReceiver': {'additionalProperties': False,
5527 'properties': {'actions': {'items': {'$ref': '#/definitions/ActionResult'},
5528 'type': 'array'},
5529 'error': {'$ref': '#/definitions/Error'},
5530 'receiver': {'type': 'string'}},
5531 'type': 'object'},
5532 'ActionsByReceivers': {'additionalProperties': False,
5533 'properties': {'actions': {'items': {'$ref': '#/definitions/ActionsByReceiver'},
5534 'type': 'array'}},
5535 'type': 'object'},
5536 'ApplicationCharmActionsResult': {'additionalProperties': False,
5537 'properties': {'ApplicationTag': {'type': 'string'},
5538 'actions': {'$ref': '#/definitions/Actions'},
5539 'error': {'$ref': '#/definitions/Error'}},
5540 'type': 'object'},
5541 'ApplicationsCharmActionsResults': {'additionalProperties': False,
5542 'properties': {'results': {'items': {'$ref': '#/definitions/ApplicationCharmActionsResult'},
5543 'type': 'array'}},
5544 'type': 'object'},
5545 'Entities': {'additionalProperties': False,
5546 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
5547 'type': 'array'}},
5548 'required': ['Entities'],
5549 'type': 'object'},
5550 'Entity': {'additionalProperties': False,
5551 'properties': {'Tag': {'type': 'string'}},
5552 'required': ['Tag'],
5553 'type': 'object'},
5554 'Error': {'additionalProperties': False,
5555 'properties': {'Code': {'type': 'string'},
5556 'Info': {'$ref': '#/definitions/ErrorInfo'},
5557 'Message': {'type': 'string'}},
5558 'required': ['Message', 'Code'],
5559 'type': 'object'},
5560 'ErrorInfo': {'additionalProperties': False,
5561 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
5562 'MacaroonPath': {'type': 'string'}},
5563 'type': 'object'},
5564 'FindActionsByNames': {'additionalProperties': False,
5565 'properties': {'names': {'items': {'type': 'string'},
5566 'type': 'array'}},
5567 'type': 'object'},
5568 'FindTags': {'additionalProperties': False,
5569 'properties': {'prefixes': {'items': {'type': 'string'},
5570 'type': 'array'}},
5571 'required': ['prefixes'],
5572 'type': 'object'},
5573 'FindTagsResults': {'additionalProperties': False,
5574 'properties': {'matches': {'patternProperties': {'.*': {'items': {'$ref': '#/definitions/Entity'},
5575 'type': 'array'}},
5576 'type': 'object'}},
5577 'required': ['matches'],
5578 'type': 'object'},
5579 'Macaroon': {'additionalProperties': False,
5580 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
5581 'type': 'array'},
5582 'data': {'items': {'type': 'integer'},
5583 'type': 'array'},
5584 'id': {'$ref': '#/definitions/packet'},
5585 'location': {'$ref': '#/definitions/packet'},
5586 'sig': {'items': {'type': 'integer'},
5587 'type': 'array'}},
5588 'required': ['data',
5589 'location',
5590 'id',
5591 'caveats',
5592 'sig'],
5593 'type': 'object'},
5594 'RunParams': {'additionalProperties': False,
5595 'properties': {'Applications': {'items': {'type': 'string'},
5596 'type': 'array'},
5597 'Commands': {'type': 'string'},
5598 'Machines': {'items': {'type': 'string'},
5599 'type': 'array'},
5600 'Timeout': {'type': 'integer'},
5601 'Units': {'items': {'type': 'string'},
5602 'type': 'array'}},
5603 'required': ['Commands',
5604 'Timeout',
5605 'Machines',
5606 'Applications',
5607 'Units'],
5608 'type': 'object'},
5609 'caveat': {'additionalProperties': False,
5610 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
5611 'location': {'$ref': '#/definitions/packet'},
5612 'verificationId': {'$ref': '#/definitions/packet'}},
5613 'required': ['location',
5614 'caveatId',
5615 'verificationId'],
5616 'type': 'object'},
5617 'packet': {'additionalProperties': False,
5618 'properties': {'headerLen': {'type': 'integer'},
5619 'start': {'type': 'integer'},
5620 'totalLen': {'type': 'integer'}},
5621 'required': ['start', 'totalLen', 'headerLen'],
5622 'type': 'object'}},
5623 'properties': {'Actions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5624 'Result': {'$ref': '#/definitions/ActionResults'}},
5625 'type': 'object'},
5626 'ApplicationsCharmsActions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5627 'Result': {'$ref': '#/definitions/ApplicationsCharmActionsResults'}},
5628 'type': 'object'},
5629 'Cancel': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5630 'Result': {'$ref': '#/definitions/ActionResults'}},
5631 'type': 'object'},
5632 'Enqueue': {'properties': {'Params': {'$ref': '#/definitions/Actions'},
5633 'Result': {'$ref': '#/definitions/ActionResults'}},
5634 'type': 'object'},
5635 'FindActionTagsByPrefix': {'properties': {'Params': {'$ref': '#/definitions/FindTags'},
5636 'Result': {'$ref': '#/definitions/FindTagsResults'}},
5637 'type': 'object'},
5638 'FindActionsByNames': {'properties': {'Params': {'$ref': '#/definitions/FindActionsByNames'},
5639 'Result': {'$ref': '#/definitions/ActionsByNames'}},
5640 'type': 'object'},
5641 'ListAll': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5642 'Result': {'$ref': '#/definitions/ActionsByReceivers'}},
5643 'type': 'object'},
5644 'ListCompleted': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5645 'Result': {'$ref': '#/definitions/ActionsByReceivers'}},
5646 'type': 'object'},
5647 'ListPending': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5648 'Result': {'$ref': '#/definitions/ActionsByReceivers'}},
5649 'type': 'object'},
5650 'ListRunning': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
5651 'Result': {'$ref': '#/definitions/ActionsByReceivers'}},
5652 'type': 'object'},
5653 'Run': {'properties': {'Params': {'$ref': '#/definitions/RunParams'},
5654 'Result': {'$ref': '#/definitions/ActionResults'}},
5655 'type': 'object'},
5656 'RunOnAllMachines': {'properties': {'Params': {'$ref': '#/definitions/RunParams'},
5657 'Result': {'$ref': '#/definitions/ActionResults'}},
5658 'type': 'object'}},
5659 'type': 'object'}
5660
5661
5662 @ReturnMapping(ActionResults)
5663 async def Actions(self, entities):
5664 '''
5665 entities : typing.Sequence[~Entity]
5666 Returns -> typing.Sequence[~ActionResult]
5667 '''
5668 # map input types to rpc msg
5669 params = dict()
5670 msg = dict(Type='Action', Request='Actions', Version=2, Params=params)
5671 params['Entities'] = entities
5672 reply = await self.rpc(msg)
5673 return reply
5674
5675
5676
5677 @ReturnMapping(ApplicationsCharmActionsResults)
5678 async def ApplicationsCharmsActions(self, entities):
5679 '''
5680 entities : typing.Sequence[~Entity]
5681 Returns -> typing.Sequence[~ApplicationCharmActionsResult]
5682 '''
5683 # map input types to rpc msg
5684 params = dict()
5685 msg = dict(Type='Action', Request='ApplicationsCharmsActions', Version=2, Params=params)
5686 params['Entities'] = entities
5687 reply = await self.rpc(msg)
5688 return reply
5689
5690
5691
5692 @ReturnMapping(ActionResults)
5693 async def Cancel(self, entities):
5694 '''
5695 entities : typing.Sequence[~Entity]
5696 Returns -> typing.Sequence[~ActionResult]
5697 '''
5698 # map input types to rpc msg
5699 params = dict()
5700 msg = dict(Type='Action', Request='Cancel', Version=2, Params=params)
5701 params['Entities'] = entities
5702 reply = await self.rpc(msg)
5703 return reply
5704
5705
5706
5707 @ReturnMapping(ActionResults)
5708 async def Enqueue(self, actionspecs):
5709 '''
5710 actionspecs : typing.Mapping[str, ~ActionSpec]
5711 Returns -> typing.Sequence[~ActionResult]
5712 '''
5713 # map input types to rpc msg
5714 params = dict()
5715 msg = dict(Type='Action', Request='Enqueue', Version=2, Params=params)
5716 params['ActionSpecs'] = actionspecs
5717 reply = await self.rpc(msg)
5718 return reply
5719
5720
5721
5722 @ReturnMapping(FindTagsResults)
5723 async def FindActionTagsByPrefix(self, prefixes):
5724 '''
5725 prefixes : typing.Sequence[str]
5726 Returns -> typing.Sequence[~Entity]
5727 '''
5728 # map input types to rpc msg
5729 params = dict()
5730 msg = dict(Type='Action', Request='FindActionTagsByPrefix', Version=2, Params=params)
5731 params['prefixes'] = prefixes
5732 reply = await self.rpc(msg)
5733 return reply
5734
5735
5736
5737 @ReturnMapping(ActionsByNames)
5738 async def FindActionsByNames(self, names):
5739 '''
5740 names : typing.Sequence[str]
5741 Returns -> typing.Sequence[~ActionsByName]
5742 '''
5743 # map input types to rpc msg
5744 params = dict()
5745 msg = dict(Type='Action', Request='FindActionsByNames', Version=2, Params=params)
5746 params['names'] = names
5747 reply = await self.rpc(msg)
5748 return reply
5749
5750
5751
5752 @ReturnMapping(ActionsByReceivers)
5753 async def ListAll(self, entities):
5754 '''
5755 entities : typing.Sequence[~Entity]
5756 Returns -> typing.Sequence[~ActionsByReceiver]
5757 '''
5758 # map input types to rpc msg
5759 params = dict()
5760 msg = dict(Type='Action', Request='ListAll', Version=2, Params=params)
5761 params['Entities'] = entities
5762 reply = await self.rpc(msg)
5763 return reply
5764
5765
5766
5767 @ReturnMapping(ActionsByReceivers)
5768 async def ListCompleted(self, entities):
5769 '''
5770 entities : typing.Sequence[~Entity]
5771 Returns -> typing.Sequence[~ActionsByReceiver]
5772 '''
5773 # map input types to rpc msg
5774 params = dict()
5775 msg = dict(Type='Action', Request='ListCompleted', Version=2, Params=params)
5776 params['Entities'] = entities
5777 reply = await self.rpc(msg)
5778 return reply
5779
5780
5781
5782 @ReturnMapping(ActionsByReceivers)
5783 async def ListPending(self, entities):
5784 '''
5785 entities : typing.Sequence[~Entity]
5786 Returns -> typing.Sequence[~ActionsByReceiver]
5787 '''
5788 # map input types to rpc msg
5789 params = dict()
5790 msg = dict(Type='Action', Request='ListPending', Version=2, Params=params)
5791 params['Entities'] = entities
5792 reply = await self.rpc(msg)
5793 return reply
5794
5795
5796
5797 @ReturnMapping(ActionsByReceivers)
5798 async def ListRunning(self, entities):
5799 '''
5800 entities : typing.Sequence[~Entity]
5801 Returns -> typing.Sequence[~ActionsByReceiver]
5802 '''
5803 # map input types to rpc msg
5804 params = dict()
5805 msg = dict(Type='Action', Request='ListRunning', Version=2, Params=params)
5806 params['Entities'] = entities
5807 reply = await self.rpc(msg)
5808 return reply
5809
5810
5811
5812 @ReturnMapping(ActionResults)
5813 async def Run(self, applications, commands, machines, timeout, units):
5814 '''
5815 applications : typing.Sequence[str]
5816 commands : str
5817 machines : typing.Sequence[str]
5818 timeout : int
5819 units : typing.Sequence[str]
5820 Returns -> typing.Sequence[~ActionResult]
5821 '''
5822 # map input types to rpc msg
5823 params = dict()
5824 msg = dict(Type='Action', Request='Run', Version=2, Params=params)
5825 params['Applications'] = applications
5826 params['Commands'] = commands
5827 params['Machines'] = machines
5828 params['Timeout'] = timeout
5829 params['Units'] = units
5830 reply = await self.rpc(msg)
5831 return reply
5832
5833
5834
5835 @ReturnMapping(ActionResults)
5836 async def RunOnAllMachines(self, applications, commands, machines, timeout, units):
5837 '''
5838 applications : typing.Sequence[str]
5839 commands : str
5840 machines : typing.Sequence[str]
5841 timeout : int
5842 units : typing.Sequence[str]
5843 Returns -> typing.Sequence[~ActionResult]
5844 '''
5845 # map input types to rpc msg
5846 params = dict()
5847 msg = dict(Type='Action', Request='RunOnAllMachines', Version=2, Params=params)
5848 params['Applications'] = applications
5849 params['Commands'] = commands
5850 params['Machines'] = machines
5851 params['Timeout'] = timeout
5852 params['Units'] = units
5853 reply = await self.rpc(msg)
5854 return reply
5855
5856
5857 class AddresserFacade(Type):
5858 name = 'Addresser'
5859 version = 2
5860 schema = {'definitions': {'BoolResult': {'additionalProperties': False,
5861 'properties': {'Error': {'$ref': '#/definitions/Error'},
5862 'Result': {'type': 'boolean'}},
5863 'required': ['Error', 'Result'],
5864 'type': 'object'},
5865 'EntitiesWatchResult': {'additionalProperties': False,
5866 'properties': {'Changes': {'items': {'type': 'string'},
5867 'type': 'array'},
5868 'EntityWatcherId': {'type': 'string'},
5869 'Error': {'$ref': '#/definitions/Error'}},
5870 'required': ['EntityWatcherId',
5871 'Changes',
5872 'Error'],
5873 'type': 'object'},
5874 'Error': {'additionalProperties': False,
5875 'properties': {'Code': {'type': 'string'},
5876 'Info': {'$ref': '#/definitions/ErrorInfo'},
5877 'Message': {'type': 'string'}},
5878 'required': ['Message', 'Code'],
5879 'type': 'object'},
5880 'ErrorInfo': {'additionalProperties': False,
5881 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
5882 'MacaroonPath': {'type': 'string'}},
5883 'type': 'object'},
5884 'ErrorResult': {'additionalProperties': False,
5885 'properties': {'Error': {'$ref': '#/definitions/Error'}},
5886 'required': ['Error'],
5887 'type': 'object'},
5888 'Macaroon': {'additionalProperties': False,
5889 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
5890 'type': 'array'},
5891 'data': {'items': {'type': 'integer'},
5892 'type': 'array'},
5893 'id': {'$ref': '#/definitions/packet'},
5894 'location': {'$ref': '#/definitions/packet'},
5895 'sig': {'items': {'type': 'integer'},
5896 'type': 'array'}},
5897 'required': ['data',
5898 'location',
5899 'id',
5900 'caveats',
5901 'sig'],
5902 'type': 'object'},
5903 'caveat': {'additionalProperties': False,
5904 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
5905 'location': {'$ref': '#/definitions/packet'},
5906 'verificationId': {'$ref': '#/definitions/packet'}},
5907 'required': ['location',
5908 'caveatId',
5909 'verificationId'],
5910 'type': 'object'},
5911 'packet': {'additionalProperties': False,
5912 'properties': {'headerLen': {'type': 'integer'},
5913 'start': {'type': 'integer'},
5914 'totalLen': {'type': 'integer'}},
5915 'required': ['start', 'totalLen', 'headerLen'],
5916 'type': 'object'}},
5917 'properties': {'CanDeallocateAddresses': {'properties': {'Result': {'$ref': '#/definitions/BoolResult'}},
5918 'type': 'object'},
5919 'CleanupIPAddresses': {'properties': {'Result': {'$ref': '#/definitions/ErrorResult'}},
5920 'type': 'object'},
5921 'WatchIPAddresses': {'properties': {'Result': {'$ref': '#/definitions/EntitiesWatchResult'}},
5922 'type': 'object'}},
5923 'type': 'object'}
5924
5925
5926 @ReturnMapping(BoolResult)
5927 async def CanDeallocateAddresses(self):
5928 '''
5929
5930 Returns -> typing.Union[_ForwardRef('Error'), bool]
5931 '''
5932 # map input types to rpc msg
5933 params = dict()
5934 msg = dict(Type='Addresser', Request='CanDeallocateAddresses', Version=2, Params=params)
5935
5936 reply = await self.rpc(msg)
5937 return reply
5938
5939
5940
5941 @ReturnMapping(ErrorResult)
5942 async def CleanupIPAddresses(self):
5943 '''
5944
5945 Returns -> Error
5946 '''
5947 # map input types to rpc msg
5948 params = dict()
5949 msg = dict(Type='Addresser', Request='CleanupIPAddresses', Version=2, Params=params)
5950
5951 reply = await self.rpc(msg)
5952 return reply
5953
5954
5955
5956 @ReturnMapping(EntitiesWatchResult)
5957 async def WatchIPAddresses(self):
5958 '''
5959
5960 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
5961 '''
5962 # map input types to rpc msg
5963 params = dict()
5964 msg = dict(Type='Addresser', Request='WatchIPAddresses', Version=2, Params=params)
5965
5966 reply = await self.rpc(msg)
5967 return reply
5968
5969
5970 class AgentFacade(Type):
5971 name = 'Agent'
5972 version = 2
5973 schema = {'definitions': {'AgentGetEntitiesResult': {'additionalProperties': False,
5974 'properties': {'ContainerType': {'type': 'string'},
5975 'Error': {'$ref': '#/definitions/Error'},
5976 'Jobs': {'items': {'type': 'string'},
5977 'type': 'array'},
5978 'Life': {'type': 'string'}},
5979 'required': ['Life',
5980 'Jobs',
5981 'ContainerType',
5982 'Error'],
5983 'type': 'object'},
5984 'AgentGetEntitiesResults': {'additionalProperties': False,
5985 'properties': {'Entities': {'items': {'$ref': '#/definitions/AgentGetEntitiesResult'},
5986 'type': 'array'}},
5987 'required': ['Entities'],
5988 'type': 'object'},
5989 'Entities': {'additionalProperties': False,
5990 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
5991 'type': 'array'}},
5992 'required': ['Entities'],
5993 'type': 'object'},
5994 'Entity': {'additionalProperties': False,
5995 'properties': {'Tag': {'type': 'string'}},
5996 'required': ['Tag'],
5997 'type': 'object'},
5998 'EntityPassword': {'additionalProperties': False,
5999 'properties': {'Password': {'type': 'string'},
6000 'Tag': {'type': 'string'}},
6001 'required': ['Tag', 'Password'],
6002 'type': 'object'},
6003 'EntityPasswords': {'additionalProperties': False,
6004 'properties': {'Changes': {'items': {'$ref': '#/definitions/EntityPassword'},
6005 'type': 'array'}},
6006 'required': ['Changes'],
6007 'type': 'object'},
6008 'Error': {'additionalProperties': False,
6009 'properties': {'Code': {'type': 'string'},
6010 'Info': {'$ref': '#/definitions/ErrorInfo'},
6011 'Message': {'type': 'string'}},
6012 'required': ['Message', 'Code'],
6013 'type': 'object'},
6014 'ErrorInfo': {'additionalProperties': False,
6015 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
6016 'MacaroonPath': {'type': 'string'}},
6017 'type': 'object'},
6018 'ErrorResult': {'additionalProperties': False,
6019 'properties': {'Error': {'$ref': '#/definitions/Error'}},
6020 'required': ['Error'],
6021 'type': 'object'},
6022 'ErrorResults': {'additionalProperties': False,
6023 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
6024 'type': 'array'}},
6025 'required': ['Results'],
6026 'type': 'object'},
6027 'IsMasterResult': {'additionalProperties': False,
6028 'properties': {'Master': {'type': 'boolean'}},
6029 'required': ['Master'],
6030 'type': 'object'},
6031 'Macaroon': {'additionalProperties': False,
6032 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
6033 'type': 'array'},
6034 'data': {'items': {'type': 'integer'},
6035 'type': 'array'},
6036 'id': {'$ref': '#/definitions/packet'},
6037 'location': {'$ref': '#/definitions/packet'},
6038 'sig': {'items': {'type': 'integer'},
6039 'type': 'array'}},
6040 'required': ['data',
6041 'location',
6042 'id',
6043 'caveats',
6044 'sig'],
6045 'type': 'object'},
6046 'ModelConfigResult': {'additionalProperties': False,
6047 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
6048 'type': 'object'}},
6049 'type': 'object'}},
6050 'required': ['Config'],
6051 'type': 'object'},
6052 'NotifyWatchResult': {'additionalProperties': False,
6053 'properties': {'Error': {'$ref': '#/definitions/Error'},
6054 'NotifyWatcherId': {'type': 'string'}},
6055 'required': ['NotifyWatcherId', 'Error'],
6056 'type': 'object'},
6057 'StateServingInfo': {'additionalProperties': False,
6058 'properties': {'APIPort': {'type': 'integer'},
6059 'CAPrivateKey': {'type': 'string'},
6060 'Cert': {'type': 'string'},
6061 'PrivateKey': {'type': 'string'},
6062 'SharedSecret': {'type': 'string'},
6063 'StatePort': {'type': 'integer'},
6064 'SystemIdentity': {'type': 'string'}},
6065 'required': ['APIPort',
6066 'StatePort',
6067 'Cert',
6068 'PrivateKey',
6069 'CAPrivateKey',
6070 'SharedSecret',
6071 'SystemIdentity'],
6072 'type': 'object'},
6073 'caveat': {'additionalProperties': False,
6074 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
6075 'location': {'$ref': '#/definitions/packet'},
6076 'verificationId': {'$ref': '#/definitions/packet'}},
6077 'required': ['location',
6078 'caveatId',
6079 'verificationId'],
6080 'type': 'object'},
6081 'packet': {'additionalProperties': False,
6082 'properties': {'headerLen': {'type': 'integer'},
6083 'start': {'type': 'integer'},
6084 'totalLen': {'type': 'integer'}},
6085 'required': ['start', 'totalLen', 'headerLen'],
6086 'type': 'object'}},
6087 'properties': {'ClearReboot': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
6088 'Result': {'$ref': '#/definitions/ErrorResults'}},
6089 'type': 'object'},
6090 'GetEntities': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
6091 'Result': {'$ref': '#/definitions/AgentGetEntitiesResults'}},
6092 'type': 'object'},
6093 'IsMaster': {'properties': {'Result': {'$ref': '#/definitions/IsMasterResult'}},
6094 'type': 'object'},
6095 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
6096 'type': 'object'},
6097 'SetPasswords': {'properties': {'Params': {'$ref': '#/definitions/EntityPasswords'},
6098 'Result': {'$ref': '#/definitions/ErrorResults'}},
6099 'type': 'object'},
6100 'StateServingInfo': {'properties': {'Result': {'$ref': '#/definitions/StateServingInfo'}},
6101 'type': 'object'},
6102 'WatchForModelConfigChanges': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
6103 'type': 'object'}},
6104 'type': 'object'}
6105
6106
6107 @ReturnMapping(ErrorResults)
6108 async def ClearReboot(self, entities):
6109 '''
6110 entities : typing.Sequence[~Entity]
6111 Returns -> typing.Sequence[~ErrorResult]
6112 '''
6113 # map input types to rpc msg
6114 params = dict()
6115 msg = dict(Type='Agent', Request='ClearReboot', Version=2, Params=params)
6116 params['Entities'] = entities
6117 reply = await self.rpc(msg)
6118 return reply
6119
6120
6121
6122 @ReturnMapping(AgentGetEntitiesResults)
6123 async def GetEntities(self, entities):
6124 '''
6125 entities : typing.Sequence[~Entity]
6126 Returns -> typing.Sequence[~AgentGetEntitiesResult]
6127 '''
6128 # map input types to rpc msg
6129 params = dict()
6130 msg = dict(Type='Agent', Request='GetEntities', Version=2, Params=params)
6131 params['Entities'] = entities
6132 reply = await self.rpc(msg)
6133 return reply
6134
6135
6136
6137 @ReturnMapping(IsMasterResult)
6138 async def IsMaster(self):
6139 '''
6140
6141 Returns -> bool
6142 '''
6143 # map input types to rpc msg
6144 params = dict()
6145 msg = dict(Type='Agent', Request='IsMaster', Version=2, Params=params)
6146
6147 reply = await self.rpc(msg)
6148 return reply
6149
6150
6151
6152 @ReturnMapping(ModelConfigResult)
6153 async def ModelConfig(self):
6154 '''
6155
6156 Returns -> typing.Mapping[str, typing.Any]
6157 '''
6158 # map input types to rpc msg
6159 params = dict()
6160 msg = dict(Type='Agent', Request='ModelConfig', Version=2, Params=params)
6161
6162 reply = await self.rpc(msg)
6163 return reply
6164
6165
6166
6167 @ReturnMapping(ErrorResults)
6168 async def SetPasswords(self, changes):
6169 '''
6170 changes : typing.Sequence[~EntityPassword]
6171 Returns -> typing.Sequence[~ErrorResult]
6172 '''
6173 # map input types to rpc msg
6174 params = dict()
6175 msg = dict(Type='Agent', Request='SetPasswords', Version=2, Params=params)
6176 params['Changes'] = changes
6177 reply = await self.rpc(msg)
6178 return reply
6179
6180
6181
6182 @ReturnMapping(StateServingInfo)
6183 async def StateServingInfo(self):
6184 '''
6185
6186 Returns -> typing.Union[int, str]
6187 '''
6188 # map input types to rpc msg
6189 params = dict()
6190 msg = dict(Type='Agent', Request='StateServingInfo', Version=2, Params=params)
6191
6192 reply = await self.rpc(msg)
6193 return reply
6194
6195
6196
6197 @ReturnMapping(NotifyWatchResult)
6198 async def WatchForModelConfigChanges(self):
6199 '''
6200
6201 Returns -> typing.Union[_ForwardRef('Error'), str]
6202 '''
6203 # map input types to rpc msg
6204 params = dict()
6205 msg = dict(Type='Agent', Request='WatchForModelConfigChanges', Version=2, Params=params)
6206
6207 reply = await self.rpc(msg)
6208 return reply
6209
6210
6211 class AgentToolsFacade(Type):
6212 name = 'AgentTools'
6213 version = 1
6214 schema = {'properties': {'UpdateToolsAvailable': {'type': 'object'}}, 'type': 'object'}
6215
6216
6217 @ReturnMapping(None)
6218 async def UpdateToolsAvailable(self):
6219 '''
6220
6221 Returns -> None
6222 '''
6223 # map input types to rpc msg
6224 params = dict()
6225 msg = dict(Type='AgentTools', Request='UpdateToolsAvailable', Version=1, Params=params)
6226
6227 reply = await self.rpc(msg)
6228 return reply
6229
6230
6231 class AllModelWatcherFacade(Type):
6232 name = 'AllModelWatcher'
6233 version = 2
6234 schema = {'definitions': {'AllWatcherNextResults': {'additionalProperties': False,
6235 'properties': {'Deltas': {'items': {'$ref': '#/definitions/Delta'},
6236 'type': 'array'}},
6237 'required': ['Deltas'],
6238 'type': 'object'},
6239 'Delta': {'additionalProperties': False,
6240 'properties': {'Entity': {'additionalProperties': True,
6241 'type': 'object'},
6242 'Removed': {'type': 'boolean'}},
6243 'required': ['Removed', 'Entity'],
6244 'type': 'object'}},
6245 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/AllWatcherNextResults'}},
6246 'type': 'object'},
6247 'Stop': {'type': 'object'}},
6248 'type': 'object'}
6249
6250
6251 @ReturnMapping(AllWatcherNextResults)
6252 async def Next(self):
6253 '''
6254
6255 Returns -> typing.Sequence[~Delta]
6256 '''
6257 # map input types to rpc msg
6258 params = dict()
6259 msg = dict(Type='AllModelWatcher', Request='Next', Version=2, Params=params)
6260
6261 reply = await self.rpc(msg)
6262 return reply
6263
6264
6265
6266 @ReturnMapping(None)
6267 async def Stop(self):
6268 '''
6269
6270 Returns -> None
6271 '''
6272 # map input types to rpc msg
6273 params = dict()
6274 msg = dict(Type='AllModelWatcher', Request='Stop', Version=2, Params=params)
6275
6276 reply = await self.rpc(msg)
6277 return reply
6278
6279
6280 class AllWatcherFacade(Type):
6281 name = 'AllWatcher'
6282 version = 1
6283 schema = {'definitions': {'AllWatcherNextResults': {'additionalProperties': False,
6284 'properties': {'Deltas': {'items': {'$ref': '#/definitions/Delta'},
6285 'type': 'array'}},
6286 'required': ['Deltas'],
6287 'type': 'object'},
6288 'Delta': {'additionalProperties': False,
6289 'properties': {'Entity': {'additionalProperties': True,
6290 'type': 'object'},
6291 'Removed': {'type': 'boolean'}},
6292 'required': ['Removed', 'Entity'],
6293 'type': 'object'}},
6294 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/AllWatcherNextResults'}},
6295 'type': 'object'},
6296 'Stop': {'type': 'object'}},
6297 'type': 'object'}
6298
6299
6300 @ReturnMapping(AllWatcherNextResults)
6301 async def Next(self):
6302 '''
6303
6304 Returns -> typing.Sequence[~Delta]
6305 '''
6306 # map input types to rpc msg
6307 params = dict()
6308 msg = dict(Type='AllWatcher', Request='Next', Version=1, Params=params)
6309
6310 reply = await self.rpc(msg)
6311 return reply
6312
6313
6314
6315 @ReturnMapping(None)
6316 async def Stop(self):
6317 '''
6318
6319 Returns -> None
6320 '''
6321 # map input types to rpc msg
6322 params = dict()
6323 msg = dict(Type='AllWatcher', Request='Stop', Version=1, Params=params)
6324
6325 reply = await self.rpc(msg)
6326 return reply
6327
6328
6329 class AnnotationsFacade(Type):
6330 name = 'Annotations'
6331 version = 2
6332 schema = {'definitions': {'AnnotationsGetResult': {'additionalProperties': False,
6333 'properties': {'Annotations': {'patternProperties': {'.*': {'type': 'string'}},
6334 'type': 'object'},
6335 'EntityTag': {'type': 'string'},
6336 'Error': {'$ref': '#/definitions/ErrorResult'}},
6337 'required': ['EntityTag',
6338 'Annotations',
6339 'Error'],
6340 'type': 'object'},
6341 'AnnotationsGetResults': {'additionalProperties': False,
6342 'properties': {'Results': {'items': {'$ref': '#/definitions/AnnotationsGetResult'},
6343 'type': 'array'}},
6344 'required': ['Results'],
6345 'type': 'object'},
6346 'AnnotationsSet': {'additionalProperties': False,
6347 'properties': {'Annotations': {'items': {'$ref': '#/definitions/EntityAnnotations'},
6348 'type': 'array'}},
6349 'required': ['Annotations'],
6350 'type': 'object'},
6351 'Entities': {'additionalProperties': False,
6352 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
6353 'type': 'array'}},
6354 'required': ['Entities'],
6355 'type': 'object'},
6356 'Entity': {'additionalProperties': False,
6357 'properties': {'Tag': {'type': 'string'}},
6358 'required': ['Tag'],
6359 'type': 'object'},
6360 'EntityAnnotations': {'additionalProperties': False,
6361 'properties': {'Annotations': {'patternProperties': {'.*': {'type': 'string'}},
6362 'type': 'object'},
6363 'EntityTag': {'type': 'string'}},
6364 'required': ['EntityTag', 'Annotations'],
6365 'type': 'object'},
6366 'Error': {'additionalProperties': False,
6367 'properties': {'Code': {'type': 'string'},
6368 'Info': {'$ref': '#/definitions/ErrorInfo'},
6369 'Message': {'type': 'string'}},
6370 'required': ['Message', 'Code'],
6371 'type': 'object'},
6372 'ErrorInfo': {'additionalProperties': False,
6373 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
6374 'MacaroonPath': {'type': 'string'}},
6375 'type': 'object'},
6376 'ErrorResult': {'additionalProperties': False,
6377 'properties': {'Error': {'$ref': '#/definitions/Error'}},
6378 'required': ['Error'],
6379 'type': 'object'},
6380 'ErrorResults': {'additionalProperties': False,
6381 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
6382 'type': 'array'}},
6383 'required': ['Results'],
6384 'type': 'object'},
6385 'Macaroon': {'additionalProperties': False,
6386 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
6387 'type': 'array'},
6388 'data': {'items': {'type': 'integer'},
6389 'type': 'array'},
6390 'id': {'$ref': '#/definitions/packet'},
6391 'location': {'$ref': '#/definitions/packet'},
6392 'sig': {'items': {'type': 'integer'},
6393 'type': 'array'}},
6394 'required': ['data',
6395 'location',
6396 'id',
6397 'caveats',
6398 'sig'],
6399 'type': 'object'},
6400 'caveat': {'additionalProperties': False,
6401 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
6402 'location': {'$ref': '#/definitions/packet'},
6403 'verificationId': {'$ref': '#/definitions/packet'}},
6404 'required': ['location',
6405 'caveatId',
6406 'verificationId'],
6407 'type': 'object'},
6408 'packet': {'additionalProperties': False,
6409 'properties': {'headerLen': {'type': 'integer'},
6410 'start': {'type': 'integer'},
6411 'totalLen': {'type': 'integer'}},
6412 'required': ['start', 'totalLen', 'headerLen'],
6413 'type': 'object'}},
6414 'properties': {'Get': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
6415 'Result': {'$ref': '#/definitions/AnnotationsGetResults'}},
6416 'type': 'object'},
6417 'Set': {'properties': {'Params': {'$ref': '#/definitions/AnnotationsSet'},
6418 'Result': {'$ref': '#/definitions/ErrorResults'}},
6419 'type': 'object'}},
6420 'type': 'object'}
6421
6422
6423 @ReturnMapping(AnnotationsGetResults)
6424 async def Get(self, entities):
6425 '''
6426 entities : typing.Sequence[~Entity]
6427 Returns -> typing.Sequence[~AnnotationsGetResult]
6428 '''
6429 # map input types to rpc msg
6430 params = dict()
6431 msg = dict(Type='Annotations', Request='Get', Version=2, Params=params)
6432 params['Entities'] = entities
6433 reply = await self.rpc(msg)
6434 return reply
6435
6436
6437
6438 @ReturnMapping(ErrorResults)
6439 async def Set(self, annotations):
6440 '''
6441 annotations : typing.Sequence[~EntityAnnotations]
6442 Returns -> typing.Sequence[~ErrorResult]
6443 '''
6444 # map input types to rpc msg
6445 params = dict()
6446 msg = dict(Type='Annotations', Request='Set', Version=2, Params=params)
6447 params['Annotations'] = annotations
6448 reply = await self.rpc(msg)
6449 return reply
6450
6451
6452 class ApplicationFacade(Type):
6453 name = 'Application'
6454 version = 1
6455 schema = {'definitions': {'AddApplicationUnits': {'additionalProperties': False,
6456 'properties': {'ApplicationName': {'type': 'string'},
6457 'NumUnits': {'type': 'integer'},
6458 'Placement': {'items': {'$ref': '#/definitions/Placement'},
6459 'type': 'array'}},
6460 'required': ['ApplicationName',
6461 'NumUnits',
6462 'Placement'],
6463 'type': 'object'},
6464 'AddApplicationUnitsResults': {'additionalProperties': False,
6465 'properties': {'Units': {'items': {'type': 'string'},
6466 'type': 'array'}},
6467 'required': ['Units'],
6468 'type': 'object'},
6469 'AddRelation': {'additionalProperties': False,
6470 'properties': {'Endpoints': {'items': {'type': 'string'},
6471 'type': 'array'}},
6472 'required': ['Endpoints'],
6473 'type': 'object'},
6474 'AddRelationResults': {'additionalProperties': False,
6475 'properties': {'Endpoints': {'patternProperties': {'.*': {'$ref': '#/definitions/Relation'}},
6476 'type': 'object'}},
6477 'required': ['Endpoints'],
6478 'type': 'object'},
6479 'ApplicationCharmRelations': {'additionalProperties': False,
6480 'properties': {'ApplicationName': {'type': 'string'}},
6481 'required': ['ApplicationName'],
6482 'type': 'object'},
6483 'ApplicationCharmRelationsResults': {'additionalProperties': False,
6484 'properties': {'CharmRelations': {'items': {'type': 'string'},
6485 'type': 'array'}},
6486 'required': ['CharmRelations'],
6487 'type': 'object'},
6488 'ApplicationDeploy': {'additionalProperties': False,
6489 'properties': {'ApplicationName': {'type': 'string'},
6490 'Channel': {'type': 'string'},
6491 'CharmUrl': {'type': 'string'},
6492 'Config': {'patternProperties': {'.*': {'type': 'string'}},
6493 'type': 'object'},
6494 'ConfigYAML': {'type': 'string'},
6495 'Constraints': {'$ref': '#/definitions/Value'},
6496 'EndpointBindings': {'patternProperties': {'.*': {'type': 'string'}},
6497 'type': 'object'},
6498 'NumUnits': {'type': 'integer'},
6499 'Placement': {'items': {'$ref': '#/definitions/Placement'},
6500 'type': 'array'},
6501 'Resources': {'patternProperties': {'.*': {'type': 'string'}},
6502 'type': 'object'},
6503 'Series': {'type': 'string'},
6504 'Storage': {'patternProperties': {'.*': {'$ref': '#/definitions/Constraints'}},
6505 'type': 'object'}},
6506 'required': ['ApplicationName',
6507 'Series',
6508 'CharmUrl',
6509 'Channel',
6510 'NumUnits',
6511 'Config',
6512 'ConfigYAML',
6513 'Constraints',
6514 'Placement',
6515 'Storage',
6516 'EndpointBindings',
6517 'Resources'],
6518 'type': 'object'},
6519 'ApplicationDestroy': {'additionalProperties': False,
6520 'properties': {'ApplicationName': {'type': 'string'}},
6521 'required': ['ApplicationName'],
6522 'type': 'object'},
6523 'ApplicationExpose': {'additionalProperties': False,
6524 'properties': {'ApplicationName': {'type': 'string'}},
6525 'required': ['ApplicationName'],
6526 'type': 'object'},
6527 'ApplicationGet': {'additionalProperties': False,
6528 'properties': {'ApplicationName': {'type': 'string'}},
6529 'required': ['ApplicationName'],
6530 'type': 'object'},
6531 'ApplicationGetResults': {'additionalProperties': False,
6532 'properties': {'Application': {'type': 'string'},
6533 'Charm': {'type': 'string'},
6534 'Config': {'patternProperties': {'.*': {'additionalProperties': True,
6535 'type': 'object'}},
6536 'type': 'object'},
6537 'Constraints': {'$ref': '#/definitions/Value'}},
6538 'required': ['Application',
6539 'Charm',
6540 'Config',
6541 'Constraints'],
6542 'type': 'object'},
6543 'ApplicationMetricCredential': {'additionalProperties': False,
6544 'properties': {'ApplicationName': {'type': 'string'},
6545 'MetricCredentials': {'items': {'type': 'integer'},
6546 'type': 'array'}},
6547 'required': ['ApplicationName',
6548 'MetricCredentials'],
6549 'type': 'object'},
6550 'ApplicationMetricCredentials': {'additionalProperties': False,
6551 'properties': {'Creds': {'items': {'$ref': '#/definitions/ApplicationMetricCredential'},
6552 'type': 'array'}},
6553 'required': ['Creds'],
6554 'type': 'object'},
6555 'ApplicationSet': {'additionalProperties': False,
6556 'properties': {'ApplicationName': {'type': 'string'},
6557 'Options': {'patternProperties': {'.*': {'type': 'string'}},
6558 'type': 'object'}},
6559 'required': ['ApplicationName', 'Options'],
6560 'type': 'object'},
6561 'ApplicationSetCharm': {'additionalProperties': False,
6562 'properties': {'applicationname': {'type': 'string'},
6563 'charmurl': {'type': 'string'},
6564 'cs-channel': {'type': 'string'},
6565 'forceseries': {'type': 'boolean'},
6566 'forceunits': {'type': 'boolean'},
6567 'resourceids': {'patternProperties': {'.*': {'type': 'string'}},
6568 'type': 'object'}},
6569 'required': ['applicationname',
6570 'charmurl',
6571 'cs-channel',
6572 'forceunits',
6573 'forceseries',
6574 'resourceids'],
6575 'type': 'object'},
6576 'ApplicationUnexpose': {'additionalProperties': False,
6577 'properties': {'ApplicationName': {'type': 'string'}},
6578 'required': ['ApplicationName'],
6579 'type': 'object'},
6580 'ApplicationUnset': {'additionalProperties': False,
6581 'properties': {'ApplicationName': {'type': 'string'},
6582 'Options': {'items': {'type': 'string'},
6583 'type': 'array'}},
6584 'required': ['ApplicationName',
6585 'Options'],
6586 'type': 'object'},
6587 'ApplicationUpdate': {'additionalProperties': False,
6588 'properties': {'ApplicationName': {'type': 'string'},
6589 'CharmUrl': {'type': 'string'},
6590 'Constraints': {'$ref': '#/definitions/Value'},
6591 'ForceCharmUrl': {'type': 'boolean'},
6592 'ForceSeries': {'type': 'boolean'},
6593 'MinUnits': {'type': 'integer'},
6594 'SettingsStrings': {'patternProperties': {'.*': {'type': 'string'}},
6595 'type': 'object'},
6596 'SettingsYAML': {'type': 'string'}},
6597 'required': ['ApplicationName',
6598 'CharmUrl',
6599 'ForceCharmUrl',
6600 'ForceSeries',
6601 'MinUnits',
6602 'SettingsStrings',
6603 'SettingsYAML',
6604 'Constraints'],
6605 'type': 'object'},
6606 'ApplicationsDeploy': {'additionalProperties': False,
6607 'properties': {'Applications': {'items': {'$ref': '#/definitions/ApplicationDeploy'},
6608 'type': 'array'}},
6609 'required': ['Applications'],
6610 'type': 'object'},
6611 'Constraints': {'additionalProperties': False,
6612 'properties': {'Count': {'type': 'integer'},
6613 'Pool': {'type': 'string'},
6614 'Size': {'type': 'integer'}},
6615 'required': ['Pool', 'Size', 'Count'],
6616 'type': 'object'},
6617 'DestroyApplicationUnits': {'additionalProperties': False,
6618 'properties': {'UnitNames': {'items': {'type': 'string'},
6619 'type': 'array'}},
6620 'required': ['UnitNames'],
6621 'type': 'object'},
6622 'DestroyRelation': {'additionalProperties': False,
6623 'properties': {'Endpoints': {'items': {'type': 'string'},
6624 'type': 'array'}},
6625 'required': ['Endpoints'],
6626 'type': 'object'},
6627 'Error': {'additionalProperties': False,
6628 'properties': {'Code': {'type': 'string'},
6629 'Info': {'$ref': '#/definitions/ErrorInfo'},
6630 'Message': {'type': 'string'}},
6631 'required': ['Message', 'Code'],
6632 'type': 'object'},
6633 'ErrorInfo': {'additionalProperties': False,
6634 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
6635 'MacaroonPath': {'type': 'string'}},
6636 'type': 'object'},
6637 'ErrorResult': {'additionalProperties': False,
6638 'properties': {'Error': {'$ref': '#/definitions/Error'}},
6639 'required': ['Error'],
6640 'type': 'object'},
6641 'ErrorResults': {'additionalProperties': False,
6642 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
6643 'type': 'array'}},
6644 'required': ['Results'],
6645 'type': 'object'},
6646 'GetApplicationConstraints': {'additionalProperties': False,
6647 'properties': {'ApplicationName': {'type': 'string'}},
6648 'required': ['ApplicationName'],
6649 'type': 'object'},
6650 'GetConstraintsResults': {'additionalProperties': False,
6651 'properties': {'Constraints': {'$ref': '#/definitions/Value'}},
6652 'required': ['Constraints'],
6653 'type': 'object'},
6654 'Macaroon': {'additionalProperties': False,
6655 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
6656 'type': 'array'},
6657 'data': {'items': {'type': 'integer'},
6658 'type': 'array'},
6659 'id': {'$ref': '#/definitions/packet'},
6660 'location': {'$ref': '#/definitions/packet'},
6661 'sig': {'items': {'type': 'integer'},
6662 'type': 'array'}},
6663 'required': ['data',
6664 'location',
6665 'id',
6666 'caveats',
6667 'sig'],
6668 'type': 'object'},
6669 'Placement': {'additionalProperties': False,
6670 'properties': {'Directive': {'type': 'string'},
6671 'Scope': {'type': 'string'}},
6672 'required': ['Scope', 'Directive'],
6673 'type': 'object'},
6674 'Relation': {'additionalProperties': False,
6675 'properties': {'Interface': {'type': 'string'},
6676 'Limit': {'type': 'integer'},
6677 'Name': {'type': 'string'},
6678 'Optional': {'type': 'boolean'},
6679 'Role': {'type': 'string'},
6680 'Scope': {'type': 'string'}},
6681 'required': ['Name',
6682 'Role',
6683 'Interface',
6684 'Optional',
6685 'Limit',
6686 'Scope'],
6687 'type': 'object'},
6688 'SetConstraints': {'additionalProperties': False,
6689 'properties': {'ApplicationName': {'type': 'string'},
6690 'Constraints': {'$ref': '#/definitions/Value'}},
6691 'required': ['ApplicationName',
6692 'Constraints'],
6693 'type': 'object'},
6694 'StringResult': {'additionalProperties': False,
6695 'properties': {'Error': {'$ref': '#/definitions/Error'},
6696 'Result': {'type': 'string'}},
6697 'required': ['Error', 'Result'],
6698 'type': 'object'},
6699 'Value': {'additionalProperties': False,
6700 'properties': {'arch': {'type': 'string'},
6701 'container': {'type': 'string'},
6702 'cpu-cores': {'type': 'integer'},
6703 'cpu-power': {'type': 'integer'},
6704 'instance-type': {'type': 'string'},
6705 'mem': {'type': 'integer'},
6706 'root-disk': {'type': 'integer'},
6707 'spaces': {'items': {'type': 'string'},
6708 'type': 'array'},
6709 'tags': {'items': {'type': 'string'},
6710 'type': 'array'},
6711 'virt-type': {'type': 'string'}},
6712 'type': 'object'},
6713 'caveat': {'additionalProperties': False,
6714 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
6715 'location': {'$ref': '#/definitions/packet'},
6716 'verificationId': {'$ref': '#/definitions/packet'}},
6717 'required': ['location',
6718 'caveatId',
6719 'verificationId'],
6720 'type': 'object'},
6721 'packet': {'additionalProperties': False,
6722 'properties': {'headerLen': {'type': 'integer'},
6723 'start': {'type': 'integer'},
6724 'totalLen': {'type': 'integer'}},
6725 'required': ['start', 'totalLen', 'headerLen'],
6726 'type': 'object'}},
6727 'properties': {'AddRelation': {'properties': {'Params': {'$ref': '#/definitions/AddRelation'},
6728 'Result': {'$ref': '#/definitions/AddRelationResults'}},
6729 'type': 'object'},
6730 'AddUnits': {'properties': {'Params': {'$ref': '#/definitions/AddApplicationUnits'},
6731 'Result': {'$ref': '#/definitions/AddApplicationUnitsResults'}},
6732 'type': 'object'},
6733 'CharmRelations': {'properties': {'Params': {'$ref': '#/definitions/ApplicationCharmRelations'},
6734 'Result': {'$ref': '#/definitions/ApplicationCharmRelationsResults'}},
6735 'type': 'object'},
6736 'Deploy': {'properties': {'Params': {'$ref': '#/definitions/ApplicationsDeploy'},
6737 'Result': {'$ref': '#/definitions/ErrorResults'}},
6738 'type': 'object'},
6739 'Destroy': {'properties': {'Params': {'$ref': '#/definitions/ApplicationDestroy'}},
6740 'type': 'object'},
6741 'DestroyRelation': {'properties': {'Params': {'$ref': '#/definitions/DestroyRelation'}},
6742 'type': 'object'},
6743 'DestroyUnits': {'properties': {'Params': {'$ref': '#/definitions/DestroyApplicationUnits'}},
6744 'type': 'object'},
6745 'Expose': {'properties': {'Params': {'$ref': '#/definitions/ApplicationExpose'}},
6746 'type': 'object'},
6747 'Get': {'properties': {'Params': {'$ref': '#/definitions/ApplicationGet'},
6748 'Result': {'$ref': '#/definitions/ApplicationGetResults'}},
6749 'type': 'object'},
6750 'GetCharmURL': {'properties': {'Params': {'$ref': '#/definitions/ApplicationGet'},
6751 'Result': {'$ref': '#/definitions/StringResult'}},
6752 'type': 'object'},
6753 'GetConstraints': {'properties': {'Params': {'$ref': '#/definitions/GetApplicationConstraints'},
6754 'Result': {'$ref': '#/definitions/GetConstraintsResults'}},
6755 'type': 'object'},
6756 'Set': {'properties': {'Params': {'$ref': '#/definitions/ApplicationSet'}},
6757 'type': 'object'},
6758 'SetCharm': {'properties': {'Params': {'$ref': '#/definitions/ApplicationSetCharm'}},
6759 'type': 'object'},
6760 'SetConstraints': {'properties': {'Params': {'$ref': '#/definitions/SetConstraints'}},
6761 'type': 'object'},
6762 'SetMetricCredentials': {'properties': {'Params': {'$ref': '#/definitions/ApplicationMetricCredentials'},
6763 'Result': {'$ref': '#/definitions/ErrorResults'}},
6764 'type': 'object'},
6765 'Unexpose': {'properties': {'Params': {'$ref': '#/definitions/ApplicationUnexpose'}},
6766 'type': 'object'},
6767 'Unset': {'properties': {'Params': {'$ref': '#/definitions/ApplicationUnset'}},
6768 'type': 'object'},
6769 'Update': {'properties': {'Params': {'$ref': '#/definitions/ApplicationUpdate'}},
6770 'type': 'object'}},
6771 'type': 'object'}
6772
6773
6774 @ReturnMapping(AddRelationResults)
6775 async def AddRelation(self, endpoints):
6776 '''
6777 endpoints : typing.Sequence[str]
6778 Returns -> typing.Mapping[str, ~Relation]
6779 '''
6780 # map input types to rpc msg
6781 params = dict()
6782 msg = dict(Type='Application', Request='AddRelation', Version=1, Params=params)
6783 params['Endpoints'] = endpoints
6784 reply = await self.rpc(msg)
6785 return reply
6786
6787
6788
6789 @ReturnMapping(AddApplicationUnitsResults)
6790 async def AddUnits(self, applicationname, numunits, placement):
6791 '''
6792 applicationname : str
6793 numunits : int
6794 placement : typing.Sequence[~Placement]
6795 Returns -> typing.Sequence[str]
6796 '''
6797 # map input types to rpc msg
6798 params = dict()
6799 msg = dict(Type='Application', Request='AddUnits', Version=1, Params=params)
6800 params['ApplicationName'] = applicationname
6801 params['NumUnits'] = numunits
6802 params['Placement'] = placement
6803 reply = await self.rpc(msg)
6804 return reply
6805
6806
6807
6808 @ReturnMapping(ApplicationCharmRelationsResults)
6809 async def CharmRelations(self, applicationname):
6810 '''
6811 applicationname : str
6812 Returns -> typing.Sequence[str]
6813 '''
6814 # map input types to rpc msg
6815 params = dict()
6816 msg = dict(Type='Application', Request='CharmRelations', Version=1, Params=params)
6817 params['ApplicationName'] = applicationname
6818 reply = await self.rpc(msg)
6819 return reply
6820
6821
6822
6823 @ReturnMapping(ErrorResults)
6824 async def Deploy(self, applications):
6825 '''
6826 applications : typing.Sequence[~ApplicationDeploy]
6827 Returns -> typing.Sequence[~ErrorResult]
6828 '''
6829 # map input types to rpc msg
6830 params = dict()
6831 msg = dict(Type='Application', Request='Deploy', Version=1, Params=params)
6832 params['Applications'] = applications
6833 reply = await self.rpc(msg)
6834 return reply
6835
6836
6837
6838 @ReturnMapping(None)
6839 async def Destroy(self, applicationname):
6840 '''
6841 applicationname : str
6842 Returns -> None
6843 '''
6844 # map input types to rpc msg
6845 params = dict()
6846 msg = dict(Type='Application', Request='Destroy', Version=1, Params=params)
6847 params['ApplicationName'] = applicationname
6848 reply = await self.rpc(msg)
6849 return reply
6850
6851
6852
6853 @ReturnMapping(None)
6854 async def DestroyRelation(self, endpoints):
6855 '''
6856 endpoints : typing.Sequence[str]
6857 Returns -> None
6858 '''
6859 # map input types to rpc msg
6860 params = dict()
6861 msg = dict(Type='Application', Request='DestroyRelation', Version=1, Params=params)
6862 params['Endpoints'] = endpoints
6863 reply = await self.rpc(msg)
6864 return reply
6865
6866
6867
6868 @ReturnMapping(None)
6869 async def DestroyUnits(self, unitnames):
6870 '''
6871 unitnames : typing.Sequence[str]
6872 Returns -> None
6873 '''
6874 # map input types to rpc msg
6875 params = dict()
6876 msg = dict(Type='Application', Request='DestroyUnits', Version=1, Params=params)
6877 params['UnitNames'] = unitnames
6878 reply = await self.rpc(msg)
6879 return reply
6880
6881
6882
6883 @ReturnMapping(None)
6884 async def Expose(self, applicationname):
6885 '''
6886 applicationname : str
6887 Returns -> None
6888 '''
6889 # map input types to rpc msg
6890 params = dict()
6891 msg = dict(Type='Application', Request='Expose', Version=1, Params=params)
6892 params['ApplicationName'] = applicationname
6893 reply = await self.rpc(msg)
6894 return reply
6895
6896
6897
6898 @ReturnMapping(ApplicationGetResults)
6899 async def Get(self, applicationname):
6900 '''
6901 applicationname : str
6902 Returns -> typing.Union[str, typing.Mapping[str, typing.Any], _ForwardRef('Value')]
6903 '''
6904 # map input types to rpc msg
6905 params = dict()
6906 msg = dict(Type='Application', Request='Get', Version=1, Params=params)
6907 params['ApplicationName'] = applicationname
6908 reply = await self.rpc(msg)
6909 return reply
6910
6911
6912
6913 @ReturnMapping(StringResult)
6914 async def GetCharmURL(self, applicationname):
6915 '''
6916 applicationname : str
6917 Returns -> typing.Union[_ForwardRef('Error'), str]
6918 '''
6919 # map input types to rpc msg
6920 params = dict()
6921 msg = dict(Type='Application', Request='GetCharmURL', Version=1, Params=params)
6922 params['ApplicationName'] = applicationname
6923 reply = await self.rpc(msg)
6924 return reply
6925
6926
6927
6928 @ReturnMapping(GetConstraintsResults)
6929 async def GetConstraints(self, applicationname):
6930 '''
6931 applicationname : str
6932 Returns -> Value
6933 '''
6934 # map input types to rpc msg
6935 params = dict()
6936 msg = dict(Type='Application', Request='GetConstraints', Version=1, Params=params)
6937 params['ApplicationName'] = applicationname
6938 reply = await self.rpc(msg)
6939 return reply
6940
6941
6942
6943 @ReturnMapping(None)
6944 async def Set(self, applicationname, options):
6945 '''
6946 applicationname : str
6947 options : typing.Mapping[str, str]
6948 Returns -> None
6949 '''
6950 # map input types to rpc msg
6951 params = dict()
6952 msg = dict(Type='Application', Request='Set', Version=1, Params=params)
6953 params['ApplicationName'] = applicationname
6954 params['Options'] = options
6955 reply = await self.rpc(msg)
6956 return reply
6957
6958
6959
6960 @ReturnMapping(None)
6961 async def SetCharm(self, applicationname, charmurl, cs_channel, forceseries, forceunits, resourceids):
6962 '''
6963 applicationname : str
6964 charmurl : str
6965 cs_channel : str
6966 forceseries : bool
6967 forceunits : bool
6968 resourceids : typing.Mapping[str, str]
6969 Returns -> None
6970 '''
6971 # map input types to rpc msg
6972 params = dict()
6973 msg = dict(Type='Application', Request='SetCharm', Version=1, Params=params)
6974 params['applicationname'] = applicationname
6975 params['charmurl'] = charmurl
6976 params['cs-channel'] = cs_channel
6977 params['forceseries'] = forceseries
6978 params['forceunits'] = forceunits
6979 params['resourceids'] = resourceids
6980 reply = await self.rpc(msg)
6981 return reply
6982
6983
6984
6985 @ReturnMapping(None)
6986 async def SetConstraints(self, applicationname, constraints):
6987 '''
6988 applicationname : str
6989 constraints : Value
6990 Returns -> None
6991 '''
6992 # map input types to rpc msg
6993 params = dict()
6994 msg = dict(Type='Application', Request='SetConstraints', Version=1, Params=params)
6995 params['ApplicationName'] = applicationname
6996 params['Constraints'] = constraints
6997 reply = await self.rpc(msg)
6998 return reply
6999
7000
7001
7002 @ReturnMapping(ErrorResults)
7003 async def SetMetricCredentials(self, creds):
7004 '''
7005 creds : typing.Sequence[~ApplicationMetricCredential]
7006 Returns -> typing.Sequence[~ErrorResult]
7007 '''
7008 # map input types to rpc msg
7009 params = dict()
7010 msg = dict(Type='Application', Request='SetMetricCredentials', Version=1, Params=params)
7011 params['Creds'] = creds
7012 reply = await self.rpc(msg)
7013 return reply
7014
7015
7016
7017 @ReturnMapping(None)
7018 async def Unexpose(self, applicationname):
7019 '''
7020 applicationname : str
7021 Returns -> None
7022 '''
7023 # map input types to rpc msg
7024 params = dict()
7025 msg = dict(Type='Application', Request='Unexpose', Version=1, Params=params)
7026 params['ApplicationName'] = applicationname
7027 reply = await self.rpc(msg)
7028 return reply
7029
7030
7031
7032 @ReturnMapping(None)
7033 async def Unset(self, applicationname, options):
7034 '''
7035 applicationname : str
7036 options : typing.Sequence[str]
7037 Returns -> None
7038 '''
7039 # map input types to rpc msg
7040 params = dict()
7041 msg = dict(Type='Application', Request='Unset', Version=1, Params=params)
7042 params['ApplicationName'] = applicationname
7043 params['Options'] = options
7044 reply = await self.rpc(msg)
7045 return reply
7046
7047
7048
7049 @ReturnMapping(None)
7050 async def Update(self, applicationname, charmurl, constraints, forcecharmurl, forceseries, minunits, settingsstrings, settingsyaml):
7051 '''
7052 applicationname : str
7053 charmurl : str
7054 constraints : Value
7055 forcecharmurl : bool
7056 forceseries : bool
7057 minunits : int
7058 settingsstrings : typing.Mapping[str, str]
7059 settingsyaml : str
7060 Returns -> None
7061 '''
7062 # map input types to rpc msg
7063 params = dict()
7064 msg = dict(Type='Application', Request='Update', Version=1, Params=params)
7065 params['ApplicationName'] = applicationname
7066 params['CharmUrl'] = charmurl
7067 params['Constraints'] = constraints
7068 params['ForceCharmUrl'] = forcecharmurl
7069 params['ForceSeries'] = forceseries
7070 params['MinUnits'] = minunits
7071 params['SettingsStrings'] = settingsstrings
7072 params['SettingsYAML'] = settingsyaml
7073 reply = await self.rpc(msg)
7074 return reply
7075
7076
7077 class ApplicationScalerFacade(Type):
7078 name = 'ApplicationScaler'
7079 version = 1
7080 schema = {'definitions': {'Entities': {'additionalProperties': False,
7081 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
7082 'type': 'array'}},
7083 'required': ['Entities'],
7084 'type': 'object'},
7085 'Entity': {'additionalProperties': False,
7086 'properties': {'Tag': {'type': 'string'}},
7087 'required': ['Tag'],
7088 'type': 'object'},
7089 'Error': {'additionalProperties': False,
7090 'properties': {'Code': {'type': 'string'},
7091 'Info': {'$ref': '#/definitions/ErrorInfo'},
7092 'Message': {'type': 'string'}},
7093 'required': ['Message', 'Code'],
7094 'type': 'object'},
7095 'ErrorInfo': {'additionalProperties': False,
7096 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
7097 'MacaroonPath': {'type': 'string'}},
7098 'type': 'object'},
7099 'ErrorResult': {'additionalProperties': False,
7100 'properties': {'Error': {'$ref': '#/definitions/Error'}},
7101 'required': ['Error'],
7102 'type': 'object'},
7103 'ErrorResults': {'additionalProperties': False,
7104 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
7105 'type': 'array'}},
7106 'required': ['Results'],
7107 'type': 'object'},
7108 'Macaroon': {'additionalProperties': False,
7109 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
7110 'type': 'array'},
7111 'data': {'items': {'type': 'integer'},
7112 'type': 'array'},
7113 'id': {'$ref': '#/definitions/packet'},
7114 'location': {'$ref': '#/definitions/packet'},
7115 'sig': {'items': {'type': 'integer'},
7116 'type': 'array'}},
7117 'required': ['data',
7118 'location',
7119 'id',
7120 'caveats',
7121 'sig'],
7122 'type': 'object'},
7123 'StringsWatchResult': {'additionalProperties': False,
7124 'properties': {'Changes': {'items': {'type': 'string'},
7125 'type': 'array'},
7126 'Error': {'$ref': '#/definitions/Error'},
7127 'StringsWatcherId': {'type': 'string'}},
7128 'required': ['StringsWatcherId',
7129 'Changes',
7130 'Error'],
7131 'type': 'object'},
7132 'caveat': {'additionalProperties': False,
7133 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
7134 'location': {'$ref': '#/definitions/packet'},
7135 'verificationId': {'$ref': '#/definitions/packet'}},
7136 'required': ['location',
7137 'caveatId',
7138 'verificationId'],
7139 'type': 'object'},
7140 'packet': {'additionalProperties': False,
7141 'properties': {'headerLen': {'type': 'integer'},
7142 'start': {'type': 'integer'},
7143 'totalLen': {'type': 'integer'}},
7144 'required': ['start', 'totalLen', 'headerLen'],
7145 'type': 'object'}},
7146 'properties': {'Rescale': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
7147 'Result': {'$ref': '#/definitions/ErrorResults'}},
7148 'type': 'object'},
7149 'Watch': {'properties': {'Result': {'$ref': '#/definitions/StringsWatchResult'}},
7150 'type': 'object'}},
7151 'type': 'object'}
7152
7153
7154 @ReturnMapping(ErrorResults)
7155 async def Rescale(self, entities):
7156 '''
7157 entities : typing.Sequence[~Entity]
7158 Returns -> typing.Sequence[~ErrorResult]
7159 '''
7160 # map input types to rpc msg
7161 params = dict()
7162 msg = dict(Type='ApplicationScaler', Request='Rescale', Version=1, Params=params)
7163 params['Entities'] = entities
7164 reply = await self.rpc(msg)
7165 return reply
7166
7167
7168
7169 @ReturnMapping(StringsWatchResult)
7170 async def Watch(self):
7171 '''
7172
7173 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
7174 '''
7175 # map input types to rpc msg
7176 params = dict()
7177 msg = dict(Type='ApplicationScaler', Request='Watch', Version=1, Params=params)
7178
7179 reply = await self.rpc(msg)
7180 return reply
7181
7182
7183 class BackupsFacade(Type):
7184 name = 'Backups'
7185 version = 1
7186 schema = {'definitions': {'BackupsCreateArgs': {'additionalProperties': False,
7187 'properties': {'Notes': {'type': 'string'}},
7188 'required': ['Notes'],
7189 'type': 'object'},
7190 'BackupsInfoArgs': {'additionalProperties': False,
7191 'properties': {'ID': {'type': 'string'}},
7192 'required': ['ID'],
7193 'type': 'object'},
7194 'BackupsListArgs': {'additionalProperties': False,
7195 'type': 'object'},
7196 'BackupsListResult': {'additionalProperties': False,
7197 'properties': {'List': {'items': {'$ref': '#/definitions/BackupsMetadataResult'},
7198 'type': 'array'}},
7199 'required': ['List'],
7200 'type': 'object'},
7201 'BackupsMetadataResult': {'additionalProperties': False,
7202 'properties': {'CACert': {'type': 'string'},
7203 'CAPrivateKey': {'type': 'string'},
7204 'Checksum': {'type': 'string'},
7205 'ChecksumFormat': {'type': 'string'},
7206 'Finished': {'format': 'date-time',
7207 'type': 'string'},
7208 'Hostname': {'type': 'string'},
7209 'ID': {'type': 'string'},
7210 'Machine': {'type': 'string'},
7211 'Model': {'type': 'string'},
7212 'Notes': {'type': 'string'},
7213 'Series': {'type': 'string'},
7214 'Size': {'type': 'integer'},
7215 'Started': {'format': 'date-time',
7216 'type': 'string'},
7217 'Stored': {'format': 'date-time',
7218 'type': 'string'},
7219 'Version': {'$ref': '#/definitions/Number'}},
7220 'required': ['ID',
7221 'Checksum',
7222 'ChecksumFormat',
7223 'Size',
7224 'Stored',
7225 'Started',
7226 'Finished',
7227 'Notes',
7228 'Model',
7229 'Machine',
7230 'Hostname',
7231 'Version',
7232 'Series',
7233 'CACert',
7234 'CAPrivateKey'],
7235 'type': 'object'},
7236 'BackupsRemoveArgs': {'additionalProperties': False,
7237 'properties': {'ID': {'type': 'string'}},
7238 'required': ['ID'],
7239 'type': 'object'},
7240 'Number': {'additionalProperties': False,
7241 'properties': {'Build': {'type': 'integer'},
7242 'Major': {'type': 'integer'},
7243 'Minor': {'type': 'integer'},
7244 'Patch': {'type': 'integer'},
7245 'Tag': {'type': 'string'}},
7246 'required': ['Major',
7247 'Minor',
7248 'Tag',
7249 'Patch',
7250 'Build'],
7251 'type': 'object'},
7252 'RestoreArgs': {'additionalProperties': False,
7253 'properties': {'BackupId': {'type': 'string'}},
7254 'required': ['BackupId'],
7255 'type': 'object'}},
7256 'properties': {'Create': {'properties': {'Params': {'$ref': '#/definitions/BackupsCreateArgs'},
7257 'Result': {'$ref': '#/definitions/BackupsMetadataResult'}},
7258 'type': 'object'},
7259 'FinishRestore': {'type': 'object'},
7260 'Info': {'properties': {'Params': {'$ref': '#/definitions/BackupsInfoArgs'},
7261 'Result': {'$ref': '#/definitions/BackupsMetadataResult'}},
7262 'type': 'object'},
7263 'List': {'properties': {'Params': {'$ref': '#/definitions/BackupsListArgs'},
7264 'Result': {'$ref': '#/definitions/BackupsListResult'}},
7265 'type': 'object'},
7266 'PrepareRestore': {'type': 'object'},
7267 'Remove': {'properties': {'Params': {'$ref': '#/definitions/BackupsRemoveArgs'}},
7268 'type': 'object'},
7269 'Restore': {'properties': {'Params': {'$ref': '#/definitions/RestoreArgs'}},
7270 'type': 'object'}},
7271 'type': 'object'}
7272
7273
7274 @ReturnMapping(BackupsMetadataResult)
7275 async def Create(self, notes):
7276 '''
7277 notes : str
7278 Returns -> typing.Union[str, int, _ForwardRef('Number')]
7279 '''
7280 # map input types to rpc msg
7281 params = dict()
7282 msg = dict(Type='Backups', Request='Create', Version=1, Params=params)
7283 params['Notes'] = notes
7284 reply = await self.rpc(msg)
7285 return reply
7286
7287
7288
7289 @ReturnMapping(None)
7290 async def FinishRestore(self):
7291 '''
7292
7293 Returns -> None
7294 '''
7295 # map input types to rpc msg
7296 params = dict()
7297 msg = dict(Type='Backups', Request='FinishRestore', Version=1, Params=params)
7298
7299 reply = await self.rpc(msg)
7300 return reply
7301
7302
7303
7304 @ReturnMapping(BackupsMetadataResult)
7305 async def Info(self, id_):
7306 '''
7307 id_ : str
7308 Returns -> typing.Union[str, int, _ForwardRef('Number')]
7309 '''
7310 # map input types to rpc msg
7311 params = dict()
7312 msg = dict(Type='Backups', Request='Info', Version=1, Params=params)
7313 params['ID'] = id_
7314 reply = await self.rpc(msg)
7315 return reply
7316
7317
7318
7319 @ReturnMapping(BackupsListResult)
7320 async def List(self):
7321 '''
7322
7323 Returns -> typing.Sequence[~BackupsMetadataResult]
7324 '''
7325 # map input types to rpc msg
7326 params = dict()
7327 msg = dict(Type='Backups', Request='List', Version=1, Params=params)
7328
7329 reply = await self.rpc(msg)
7330 return reply
7331
7332
7333
7334 @ReturnMapping(None)
7335 async def PrepareRestore(self):
7336 '''
7337
7338 Returns -> None
7339 '''
7340 # map input types to rpc msg
7341 params = dict()
7342 msg = dict(Type='Backups', Request='PrepareRestore', Version=1, Params=params)
7343
7344 reply = await self.rpc(msg)
7345 return reply
7346
7347
7348
7349 @ReturnMapping(None)
7350 async def Remove(self, id_):
7351 '''
7352 id_ : str
7353 Returns -> None
7354 '''
7355 # map input types to rpc msg
7356 params = dict()
7357 msg = dict(Type='Backups', Request='Remove', Version=1, Params=params)
7358 params['ID'] = id_
7359 reply = await self.rpc(msg)
7360 return reply
7361
7362
7363
7364 @ReturnMapping(None)
7365 async def Restore(self, backupid):
7366 '''
7367 backupid : str
7368 Returns -> None
7369 '''
7370 # map input types to rpc msg
7371 params = dict()
7372 msg = dict(Type='Backups', Request='Restore', Version=1, Params=params)
7373 params['BackupId'] = backupid
7374 reply = await self.rpc(msg)
7375 return reply
7376
7377
7378 class BlockFacade(Type):
7379 name = 'Block'
7380 version = 2
7381 schema = {'definitions': {'Block': {'additionalProperties': False,
7382 'properties': {'id': {'type': 'string'},
7383 'message': {'type': 'string'},
7384 'tag': {'type': 'string'},
7385 'type': {'type': 'string'}},
7386 'required': ['id', 'tag', 'type'],
7387 'type': 'object'},
7388 'BlockResult': {'additionalProperties': False,
7389 'properties': {'error': {'$ref': '#/definitions/Error'},
7390 'result': {'$ref': '#/definitions/Block'}},
7391 'required': ['result'],
7392 'type': 'object'},
7393 'BlockResults': {'additionalProperties': False,
7394 'properties': {'results': {'items': {'$ref': '#/definitions/BlockResult'},
7395 'type': 'array'}},
7396 'type': 'object'},
7397 'BlockSwitchParams': {'additionalProperties': False,
7398 'properties': {'message': {'type': 'string'},
7399 'type': {'type': 'string'}},
7400 'required': ['type'],
7401 'type': 'object'},
7402 'Error': {'additionalProperties': False,
7403 'properties': {'Code': {'type': 'string'},
7404 'Info': {'$ref': '#/definitions/ErrorInfo'},
7405 'Message': {'type': 'string'}},
7406 'required': ['Message', 'Code'],
7407 'type': 'object'},
7408 'ErrorInfo': {'additionalProperties': False,
7409 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
7410 'MacaroonPath': {'type': 'string'}},
7411 'type': 'object'},
7412 'ErrorResult': {'additionalProperties': False,
7413 'properties': {'Error': {'$ref': '#/definitions/Error'}},
7414 'required': ['Error'],
7415 'type': 'object'},
7416 'Macaroon': {'additionalProperties': False,
7417 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
7418 'type': 'array'},
7419 'data': {'items': {'type': 'integer'},
7420 'type': 'array'},
7421 'id': {'$ref': '#/definitions/packet'},
7422 'location': {'$ref': '#/definitions/packet'},
7423 'sig': {'items': {'type': 'integer'},
7424 'type': 'array'}},
7425 'required': ['data',
7426 'location',
7427 'id',
7428 'caveats',
7429 'sig'],
7430 'type': 'object'},
7431 'caveat': {'additionalProperties': False,
7432 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
7433 'location': {'$ref': '#/definitions/packet'},
7434 'verificationId': {'$ref': '#/definitions/packet'}},
7435 'required': ['location',
7436 'caveatId',
7437 'verificationId'],
7438 'type': 'object'},
7439 'packet': {'additionalProperties': False,
7440 'properties': {'headerLen': {'type': 'integer'},
7441 'start': {'type': 'integer'},
7442 'totalLen': {'type': 'integer'}},
7443 'required': ['start', 'totalLen', 'headerLen'],
7444 'type': 'object'}},
7445 'properties': {'List': {'properties': {'Result': {'$ref': '#/definitions/BlockResults'}},
7446 'type': 'object'},
7447 'SwitchBlockOff': {'properties': {'Params': {'$ref': '#/definitions/BlockSwitchParams'},
7448 'Result': {'$ref': '#/definitions/ErrorResult'}},
7449 'type': 'object'},
7450 'SwitchBlockOn': {'properties': {'Params': {'$ref': '#/definitions/BlockSwitchParams'},
7451 'Result': {'$ref': '#/definitions/ErrorResult'}},
7452 'type': 'object'}},
7453 'type': 'object'}
7454
7455
7456 @ReturnMapping(BlockResults)
7457 async def List(self):
7458 '''
7459
7460 Returns -> typing.Sequence[~BlockResult]
7461 '''
7462 # map input types to rpc msg
7463 params = dict()
7464 msg = dict(Type='Block', Request='List', Version=2, Params=params)
7465
7466 reply = await self.rpc(msg)
7467 return reply
7468
7469
7470
7471 @ReturnMapping(ErrorResult)
7472 async def SwitchBlockOff(self, message, type_):
7473 '''
7474 message : str
7475 type_ : str
7476 Returns -> Error
7477 '''
7478 # map input types to rpc msg
7479 params = dict()
7480 msg = dict(Type='Block', Request='SwitchBlockOff', Version=2, Params=params)
7481 params['message'] = message
7482 params['type'] = type_
7483 reply = await self.rpc(msg)
7484 return reply
7485
7486
7487
7488 @ReturnMapping(ErrorResult)
7489 async def SwitchBlockOn(self, message, type_):
7490 '''
7491 message : str
7492 type_ : str
7493 Returns -> Error
7494 '''
7495 # map input types to rpc msg
7496 params = dict()
7497 msg = dict(Type='Block', Request='SwitchBlockOn', Version=2, Params=params)
7498 params['message'] = message
7499 params['type'] = type_
7500 reply = await self.rpc(msg)
7501 return reply
7502
7503
7504 class CharmRevisionUpdaterFacade(Type):
7505 name = 'CharmRevisionUpdater'
7506 version = 2
7507 schema = {'definitions': {'Error': {'additionalProperties': False,
7508 'properties': {'Code': {'type': 'string'},
7509 'Info': {'$ref': '#/definitions/ErrorInfo'},
7510 'Message': {'type': 'string'}},
7511 'required': ['Message', 'Code'],
7512 'type': 'object'},
7513 'ErrorInfo': {'additionalProperties': False,
7514 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
7515 'MacaroonPath': {'type': 'string'}},
7516 'type': 'object'},
7517 'ErrorResult': {'additionalProperties': False,
7518 'properties': {'Error': {'$ref': '#/definitions/Error'}},
7519 'required': ['Error'],
7520 'type': 'object'},
7521 'Macaroon': {'additionalProperties': False,
7522 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
7523 'type': 'array'},
7524 'data': {'items': {'type': 'integer'},
7525 'type': 'array'},
7526 'id': {'$ref': '#/definitions/packet'},
7527 'location': {'$ref': '#/definitions/packet'},
7528 'sig': {'items': {'type': 'integer'},
7529 'type': 'array'}},
7530 'required': ['data',
7531 'location',
7532 'id',
7533 'caveats',
7534 'sig'],
7535 'type': 'object'},
7536 'caveat': {'additionalProperties': False,
7537 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
7538 'location': {'$ref': '#/definitions/packet'},
7539 'verificationId': {'$ref': '#/definitions/packet'}},
7540 'required': ['location',
7541 'caveatId',
7542 'verificationId'],
7543 'type': 'object'},
7544 'packet': {'additionalProperties': False,
7545 'properties': {'headerLen': {'type': 'integer'},
7546 'start': {'type': 'integer'},
7547 'totalLen': {'type': 'integer'}},
7548 'required': ['start', 'totalLen', 'headerLen'],
7549 'type': 'object'}},
7550 'properties': {'UpdateLatestRevisions': {'properties': {'Result': {'$ref': '#/definitions/ErrorResult'}},
7551 'type': 'object'}},
7552 'type': 'object'}
7553
7554
7555 @ReturnMapping(ErrorResult)
7556 async def UpdateLatestRevisions(self):
7557 '''
7558
7559 Returns -> Error
7560 '''
7561 # map input types to rpc msg
7562 params = dict()
7563 msg = dict(Type='CharmRevisionUpdater', Request='UpdateLatestRevisions', Version=2, Params=params)
7564
7565 reply = await self.rpc(msg)
7566 return reply
7567
7568
7569 class CharmsFacade(Type):
7570 name = 'Charms'
7571 version = 2
7572 schema = {'definitions': {'CharmInfo': {'additionalProperties': False,
7573 'properties': {'CharmURL': {'type': 'string'}},
7574 'required': ['CharmURL'],
7575 'type': 'object'},
7576 'CharmsList': {'additionalProperties': False,
7577 'properties': {'Names': {'items': {'type': 'string'},
7578 'type': 'array'}},
7579 'required': ['Names'],
7580 'type': 'object'},
7581 'CharmsListResult': {'additionalProperties': False,
7582 'properties': {'CharmURLs': {'items': {'type': 'string'},
7583 'type': 'array'}},
7584 'required': ['CharmURLs'],
7585 'type': 'object'},
7586 'IsMeteredResult': {'additionalProperties': False,
7587 'properties': {'Metered': {'type': 'boolean'}},
7588 'required': ['Metered'],
7589 'type': 'object'}},
7590 'properties': {'CharmInfo': {'properties': {'Params': {'$ref': '#/definitions/CharmInfo'},
7591 'Result': {'$ref': '#/definitions/CharmInfo'}},
7592 'type': 'object'},
7593 'IsMetered': {'properties': {'Params': {'$ref': '#/definitions/CharmInfo'},
7594 'Result': {'$ref': '#/definitions/IsMeteredResult'}},
7595 'type': 'object'},
7596 'List': {'properties': {'Params': {'$ref': '#/definitions/CharmsList'},
7597 'Result': {'$ref': '#/definitions/CharmsListResult'}},
7598 'type': 'object'}},
7599 'type': 'object'}
7600
7601
7602 @ReturnMapping(CharmInfo)
7603 async def CharmInfo(self, charmurl):
7604 '''
7605 charmurl : str
7606 Returns -> str
7607 '''
7608 # map input types to rpc msg
7609 params = dict()
7610 msg = dict(Type='Charms', Request='CharmInfo', Version=2, Params=params)
7611 params['CharmURL'] = charmurl
7612 reply = await self.rpc(msg)
7613 return reply
7614
7615
7616
7617 @ReturnMapping(IsMeteredResult)
7618 async def IsMetered(self, charmurl):
7619 '''
7620 charmurl : str
7621 Returns -> bool
7622 '''
7623 # map input types to rpc msg
7624 params = dict()
7625 msg = dict(Type='Charms', Request='IsMetered', Version=2, Params=params)
7626 params['CharmURL'] = charmurl
7627 reply = await self.rpc(msg)
7628 return reply
7629
7630
7631
7632 @ReturnMapping(CharmsListResult)
7633 async def List(self, names):
7634 '''
7635 names : typing.Sequence[str]
7636 Returns -> typing.Sequence[str]
7637 '''
7638 # map input types to rpc msg
7639 params = dict()
7640 msg = dict(Type='Charms', Request='List', Version=2, Params=params)
7641 params['Names'] = names
7642 reply = await self.rpc(msg)
7643 return reply
7644
7645
7646 class CleanerFacade(Type):
7647 name = 'Cleaner'
7648 version = 2
7649 schema = {'definitions': {'Error': {'additionalProperties': False,
7650 'properties': {'Code': {'type': 'string'},
7651 'Info': {'$ref': '#/definitions/ErrorInfo'},
7652 'Message': {'type': 'string'}},
7653 'required': ['Message', 'Code'],
7654 'type': 'object'},
7655 'ErrorInfo': {'additionalProperties': False,
7656 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
7657 'MacaroonPath': {'type': 'string'}},
7658 'type': 'object'},
7659 'Macaroon': {'additionalProperties': False,
7660 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
7661 'type': 'array'},
7662 'data': {'items': {'type': 'integer'},
7663 'type': 'array'},
7664 'id': {'$ref': '#/definitions/packet'},
7665 'location': {'$ref': '#/definitions/packet'},
7666 'sig': {'items': {'type': 'integer'},
7667 'type': 'array'}},
7668 'required': ['data',
7669 'location',
7670 'id',
7671 'caveats',
7672 'sig'],
7673 'type': 'object'},
7674 'NotifyWatchResult': {'additionalProperties': False,
7675 'properties': {'Error': {'$ref': '#/definitions/Error'},
7676 'NotifyWatcherId': {'type': 'string'}},
7677 'required': ['NotifyWatcherId', 'Error'],
7678 'type': 'object'},
7679 'caveat': {'additionalProperties': False,
7680 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
7681 'location': {'$ref': '#/definitions/packet'},
7682 'verificationId': {'$ref': '#/definitions/packet'}},
7683 'required': ['location',
7684 'caveatId',
7685 'verificationId'],
7686 'type': 'object'},
7687 'packet': {'additionalProperties': False,
7688 'properties': {'headerLen': {'type': 'integer'},
7689 'start': {'type': 'integer'},
7690 'totalLen': {'type': 'integer'}},
7691 'required': ['start', 'totalLen', 'headerLen'],
7692 'type': 'object'}},
7693 'properties': {'Cleanup': {'type': 'object'},
7694 'WatchCleanups': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
7695 'type': 'object'}},
7696 'type': 'object'}
7697
7698
7699 @ReturnMapping(None)
7700 async def Cleanup(self):
7701 '''
7702
7703 Returns -> None
7704 '''
7705 # map input types to rpc msg
7706 params = dict()
7707 msg = dict(Type='Cleaner', Request='Cleanup', Version=2, Params=params)
7708
7709 reply = await self.rpc(msg)
7710 return reply
7711
7712
7713
7714 @ReturnMapping(NotifyWatchResult)
7715 async def WatchCleanups(self):
7716 '''
7717
7718 Returns -> typing.Union[_ForwardRef('Error'), str]
7719 '''
7720 # map input types to rpc msg
7721 params = dict()
7722 msg = dict(Type='Cleaner', Request='WatchCleanups', Version=2, Params=params)
7723
7724 reply = await self.rpc(msg)
7725 return reply
7726
7727
7728 class ClientFacade(Type):
7729 name = 'Client'
7730 version = 1
7731 schema = {'definitions': {'APIHostPortsResult': {'additionalProperties': False,
7732 'properties': {'Servers': {'items': {'items': {'$ref': '#/definitions/HostPort'},
7733 'type': 'array'},
7734 'type': 'array'}},
7735 'required': ['Servers'],
7736 'type': 'object'},
7737 'AddCharm': {'additionalProperties': False,
7738 'properties': {'Channel': {'type': 'string'},
7739 'URL': {'type': 'string'}},
7740 'required': ['URL', 'Channel'],
7741 'type': 'object'},
7742 'AddCharmWithAuthorization': {'additionalProperties': False,
7743 'properties': {'Channel': {'type': 'string'},
7744 'CharmStoreMacaroon': {'$ref': '#/definitions/Macaroon'},
7745 'URL': {'type': 'string'}},
7746 'required': ['URL',
7747 'Channel',
7748 'CharmStoreMacaroon'],
7749 'type': 'object'},
7750 'AddMachineParams': {'additionalProperties': False,
7751 'properties': {'Addrs': {'items': {'$ref': '#/definitions/Address'},
7752 'type': 'array'},
7753 'Constraints': {'$ref': '#/definitions/Value'},
7754 'ContainerType': {'type': 'string'},
7755 'Disks': {'items': {'$ref': '#/definitions/Constraints'},
7756 'type': 'array'},
7757 'HardwareCharacteristics': {'$ref': '#/definitions/HardwareCharacteristics'},
7758 'InstanceId': {'type': 'string'},
7759 'Jobs': {'items': {'type': 'string'},
7760 'type': 'array'},
7761 'Nonce': {'type': 'string'},
7762 'ParentId': {'type': 'string'},
7763 'Placement': {'$ref': '#/definitions/Placement'},
7764 'Series': {'type': 'string'}},
7765 'required': ['Series',
7766 'Constraints',
7767 'Jobs',
7768 'Disks',
7769 'Placement',
7770 'ParentId',
7771 'ContainerType',
7772 'InstanceId',
7773 'Nonce',
7774 'HardwareCharacteristics',
7775 'Addrs'],
7776 'type': 'object'},
7777 'AddMachines': {'additionalProperties': False,
7778 'properties': {'MachineParams': {'items': {'$ref': '#/definitions/AddMachineParams'},
7779 'type': 'array'}},
7780 'required': ['MachineParams'],
7781 'type': 'object'},
7782 'AddMachinesResult': {'additionalProperties': False,
7783 'properties': {'Error': {'$ref': '#/definitions/Error'},
7784 'Machine': {'type': 'string'}},
7785 'required': ['Machine', 'Error'],
7786 'type': 'object'},
7787 'AddMachinesResults': {'additionalProperties': False,
7788 'properties': {'Machines': {'items': {'$ref': '#/definitions/AddMachinesResult'},
7789 'type': 'array'}},
7790 'required': ['Machines'],
7791 'type': 'object'},
7792 'Address': {'additionalProperties': False,
7793 'properties': {'Scope': {'type': 'string'},
7794 'SpaceName': {'type': 'string'},
7795 'Type': {'type': 'string'},
7796 'Value': {'type': 'string'}},
7797 'required': ['Value', 'Type', 'Scope'],
7798 'type': 'object'},
7799 'AgentVersionResult': {'additionalProperties': False,
7800 'properties': {'Version': {'$ref': '#/definitions/Number'}},
7801 'required': ['Version'],
7802 'type': 'object'},
7803 'AllWatcherId': {'additionalProperties': False,
7804 'properties': {'AllWatcherId': {'type': 'string'}},
7805 'required': ['AllWatcherId'],
7806 'type': 'object'},
7807 'ApplicationStatus': {'additionalProperties': False,
7808 'properties': {'CanUpgradeTo': {'type': 'string'},
7809 'Charm': {'type': 'string'},
7810 'Err': {'additionalProperties': True,
7811 'type': 'object'},
7812 'Exposed': {'type': 'boolean'},
7813 'Life': {'type': 'string'},
7814 'MeterStatuses': {'patternProperties': {'.*': {'$ref': '#/definitions/MeterStatus'}},
7815 'type': 'object'},
7816 'Relations': {'patternProperties': {'.*': {'items': {'type': 'string'},
7817 'type': 'array'}},
7818 'type': 'object'},
7819 'Status': {'$ref': '#/definitions/DetailedStatus'},
7820 'SubordinateTo': {'items': {'type': 'string'},
7821 'type': 'array'},
7822 'Units': {'patternProperties': {'.*': {'$ref': '#/definitions/UnitStatus'}},
7823 'type': 'object'}},
7824 'required': ['Err',
7825 'Charm',
7826 'Exposed',
7827 'Life',
7828 'Relations',
7829 'CanUpgradeTo',
7830 'SubordinateTo',
7831 'Units',
7832 'MeterStatuses',
7833 'Status'],
7834 'type': 'object'},
7835 'Binary': {'additionalProperties': False,
7836 'properties': {'Arch': {'type': 'string'},
7837 'Number': {'$ref': '#/definitions/Number'},
7838 'Series': {'type': 'string'}},
7839 'required': ['Number', 'Series', 'Arch'],
7840 'type': 'object'},
7841 'BundleChangesChange': {'additionalProperties': False,
7842 'properties': {'args': {'items': {'additionalProperties': True,
7843 'type': 'object'},
7844 'type': 'array'},
7845 'id': {'type': 'string'},
7846 'method': {'type': 'string'},
7847 'requires': {'items': {'type': 'string'},
7848 'type': 'array'}},
7849 'required': ['id',
7850 'method',
7851 'args',
7852 'requires'],
7853 'type': 'object'},
7854 'CharmInfo': {'additionalProperties': False,
7855 'properties': {'CharmURL': {'type': 'string'}},
7856 'required': ['CharmURL'],
7857 'type': 'object'},
7858 'Constraints': {'additionalProperties': False,
7859 'properties': {'Count': {'type': 'integer'},
7860 'Pool': {'type': 'string'},
7861 'Size': {'type': 'integer'}},
7862 'required': ['Pool', 'Size', 'Count'],
7863 'type': 'object'},
7864 'DestroyMachines': {'additionalProperties': False,
7865 'properties': {'Force': {'type': 'boolean'},
7866 'MachineNames': {'items': {'type': 'string'},
7867 'type': 'array'}},
7868 'required': ['MachineNames', 'Force'],
7869 'type': 'object'},
7870 'DetailedStatus': {'additionalProperties': False,
7871 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
7872 'type': 'object'}},
7873 'type': 'object'},
7874 'Err': {'additionalProperties': True,
7875 'type': 'object'},
7876 'Info': {'type': 'string'},
7877 'Kind': {'type': 'string'},
7878 'Life': {'type': 'string'},
7879 'Since': {'format': 'date-time',
7880 'type': 'string'},
7881 'Status': {'type': 'string'},
7882 'Version': {'type': 'string'}},
7883 'required': ['Status',
7884 'Info',
7885 'Data',
7886 'Since',
7887 'Kind',
7888 'Version',
7889 'Life',
7890 'Err'],
7891 'type': 'object'},
7892 'EndpointStatus': {'additionalProperties': False,
7893 'properties': {'ApplicationName': {'type': 'string'},
7894 'Name': {'type': 'string'},
7895 'Role': {'type': 'string'},
7896 'Subordinate': {'type': 'boolean'}},
7897 'required': ['ApplicationName',
7898 'Name',
7899 'Role',
7900 'Subordinate'],
7901 'type': 'object'},
7902 'Entities': {'additionalProperties': False,
7903 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
7904 'type': 'array'}},
7905 'required': ['Entities'],
7906 'type': 'object'},
7907 'Entity': {'additionalProperties': False,
7908 'properties': {'Tag': {'type': 'string'}},
7909 'required': ['Tag'],
7910 'type': 'object'},
7911 'EntityStatus': {'additionalProperties': False,
7912 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
7913 'type': 'object'}},
7914 'type': 'object'},
7915 'Info': {'type': 'string'},
7916 'Since': {'format': 'date-time',
7917 'type': 'string'},
7918 'Status': {'type': 'string'}},
7919 'required': ['Status',
7920 'Info',
7921 'Data',
7922 'Since'],
7923 'type': 'object'},
7924 'Error': {'additionalProperties': False,
7925 'properties': {'Code': {'type': 'string'},
7926 'Info': {'$ref': '#/definitions/ErrorInfo'},
7927 'Message': {'type': 'string'}},
7928 'required': ['Message', 'Code'],
7929 'type': 'object'},
7930 'ErrorInfo': {'additionalProperties': False,
7931 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
7932 'MacaroonPath': {'type': 'string'}},
7933 'type': 'object'},
7934 'ErrorResult': {'additionalProperties': False,
7935 'properties': {'Error': {'$ref': '#/definitions/Error'}},
7936 'required': ['Error'],
7937 'type': 'object'},
7938 'ErrorResults': {'additionalProperties': False,
7939 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
7940 'type': 'array'}},
7941 'required': ['Results'],
7942 'type': 'object'},
7943 'FindToolsParams': {'additionalProperties': False,
7944 'properties': {'Arch': {'type': 'string'},
7945 'MajorVersion': {'type': 'integer'},
7946 'MinorVersion': {'type': 'integer'},
7947 'Number': {'$ref': '#/definitions/Number'},
7948 'Series': {'type': 'string'}},
7949 'required': ['Number',
7950 'MajorVersion',
7951 'MinorVersion',
7952 'Arch',
7953 'Series'],
7954 'type': 'object'},
7955 'FindToolsResult': {'additionalProperties': False,
7956 'properties': {'Error': {'$ref': '#/definitions/Error'},
7957 'List': {'items': {'$ref': '#/definitions/Tools'},
7958 'type': 'array'}},
7959 'required': ['List', 'Error'],
7960 'type': 'object'},
7961 'FullStatus': {'additionalProperties': False,
7962 'properties': {'Applications': {'patternProperties': {'.*': {'$ref': '#/definitions/ApplicationStatus'}},
7963 'type': 'object'},
7964 'AvailableVersion': {'type': 'string'},
7965 'Machines': {'patternProperties': {'.*': {'$ref': '#/definitions/MachineStatus'}},
7966 'type': 'object'},
7967 'ModelName': {'type': 'string'},
7968 'Relations': {'items': {'$ref': '#/definitions/RelationStatus'},
7969 'type': 'array'}},
7970 'required': ['ModelName',
7971 'AvailableVersion',
7972 'Machines',
7973 'Applications',
7974 'Relations'],
7975 'type': 'object'},
7976 'GetBundleChangesParams': {'additionalProperties': False,
7977 'properties': {'yaml': {'type': 'string'}},
7978 'required': ['yaml'],
7979 'type': 'object'},
7980 'GetBundleChangesResults': {'additionalProperties': False,
7981 'properties': {'changes': {'items': {'$ref': '#/definitions/BundleChangesChange'},
7982 'type': 'array'},
7983 'errors': {'items': {'type': 'string'},
7984 'type': 'array'}},
7985 'type': 'object'},
7986 'GetConstraintsResults': {'additionalProperties': False,
7987 'properties': {'Constraints': {'$ref': '#/definitions/Value'}},
7988 'required': ['Constraints'],
7989 'type': 'object'},
7990 'HardwareCharacteristics': {'additionalProperties': False,
7991 'properties': {'Arch': {'type': 'string'},
7992 'AvailabilityZone': {'type': 'string'},
7993 'CpuCores': {'type': 'integer'},
7994 'CpuPower': {'type': 'integer'},
7995 'Mem': {'type': 'integer'},
7996 'RootDisk': {'type': 'integer'},
7997 'Tags': {'items': {'type': 'string'},
7998 'type': 'array'}},
7999 'type': 'object'},
8000 'History': {'additionalProperties': False,
8001 'properties': {'Error': {'$ref': '#/definitions/Error'},
8002 'Statuses': {'items': {'$ref': '#/definitions/DetailedStatus'},
8003 'type': 'array'}},
8004 'required': ['Statuses'],
8005 'type': 'object'},
8006 'HostPort': {'additionalProperties': False,
8007 'properties': {'Address': {'$ref': '#/definitions/Address'},
8008 'Port': {'type': 'integer'}},
8009 'required': ['Address', 'Port'],
8010 'type': 'object'},
8011 'Macaroon': {'additionalProperties': False,
8012 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
8013 'type': 'array'},
8014 'data': {'items': {'type': 'integer'},
8015 'type': 'array'},
8016 'id': {'$ref': '#/definitions/packet'},
8017 'location': {'$ref': '#/definitions/packet'},
8018 'sig': {'items': {'type': 'integer'},
8019 'type': 'array'}},
8020 'required': ['data',
8021 'location',
8022 'id',
8023 'caveats',
8024 'sig'],
8025 'type': 'object'},
8026 'MachineStatus': {'additionalProperties': False,
8027 'properties': {'AgentStatus': {'$ref': '#/definitions/DetailedStatus'},
8028 'Containers': {'patternProperties': {'.*': {'$ref': '#/definitions/MachineStatus'}},
8029 'type': 'object'},
8030 'DNSName': {'type': 'string'},
8031 'Hardware': {'type': 'string'},
8032 'HasVote': {'type': 'boolean'},
8033 'Id': {'type': 'string'},
8034 'InstanceId': {'type': 'string'},
8035 'InstanceStatus': {'$ref': '#/definitions/DetailedStatus'},
8036 'Jobs': {'items': {'type': 'string'},
8037 'type': 'array'},
8038 'Series': {'type': 'string'},
8039 'WantsVote': {'type': 'boolean'}},
8040 'required': ['AgentStatus',
8041 'InstanceStatus',
8042 'DNSName',
8043 'InstanceId',
8044 'Series',
8045 'Id',
8046 'Containers',
8047 'Hardware',
8048 'Jobs',
8049 'HasVote',
8050 'WantsVote'],
8051 'type': 'object'},
8052 'MeterStatus': {'additionalProperties': False,
8053 'properties': {'Color': {'type': 'string'},
8054 'Message': {'type': 'string'}},
8055 'required': ['Color', 'Message'],
8056 'type': 'object'},
8057 'ModelConfigResults': {'additionalProperties': False,
8058 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
8059 'type': 'object'}},
8060 'type': 'object'}},
8061 'required': ['Config'],
8062 'type': 'object'},
8063 'ModelInfo': {'additionalProperties': False,
8064 'properties': {'Cloud': {'type': 'string'},
8065 'DefaultSeries': {'type': 'string'},
8066 'Life': {'type': 'string'},
8067 'Name': {'type': 'string'},
8068 'OwnerTag': {'type': 'string'},
8069 'ProviderType': {'type': 'string'},
8070 'ServerUUID': {'type': 'string'},
8071 'Status': {'$ref': '#/definitions/EntityStatus'},
8072 'UUID': {'type': 'string'},
8073 'Users': {'items': {'$ref': '#/definitions/ModelUserInfo'},
8074 'type': 'array'}},
8075 'required': ['Name',
8076 'UUID',
8077 'ServerUUID',
8078 'ProviderType',
8079 'DefaultSeries',
8080 'Cloud',
8081 'OwnerTag',
8082 'Life',
8083 'Status',
8084 'Users'],
8085 'type': 'object'},
8086 'ModelSet': {'additionalProperties': False,
8087 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
8088 'type': 'object'}},
8089 'type': 'object'}},
8090 'required': ['Config'],
8091 'type': 'object'},
8092 'ModelUnset': {'additionalProperties': False,
8093 'properties': {'Keys': {'items': {'type': 'string'},
8094 'type': 'array'}},
8095 'required': ['Keys'],
8096 'type': 'object'},
8097 'ModelUserInfo': {'additionalProperties': False,
8098 'properties': {'access': {'type': 'string'},
8099 'displayname': {'type': 'string'},
8100 'lastconnection': {'format': 'date-time',
8101 'type': 'string'},
8102 'user': {'type': 'string'}},
8103 'required': ['user',
8104 'displayname',
8105 'lastconnection',
8106 'access'],
8107 'type': 'object'},
8108 'ModelUserInfoResult': {'additionalProperties': False,
8109 'properties': {'error': {'$ref': '#/definitions/Error'},
8110 'result': {'$ref': '#/definitions/ModelUserInfo'}},
8111 'type': 'object'},
8112 'ModelUserInfoResults': {'additionalProperties': False,
8113 'properties': {'results': {'items': {'$ref': '#/definitions/ModelUserInfoResult'},
8114 'type': 'array'}},
8115 'required': ['results'],
8116 'type': 'object'},
8117 'Number': {'additionalProperties': False,
8118 'properties': {'Build': {'type': 'integer'},
8119 'Major': {'type': 'integer'},
8120 'Minor': {'type': 'integer'},
8121 'Patch': {'type': 'integer'},
8122 'Tag': {'type': 'string'}},
8123 'required': ['Major',
8124 'Minor',
8125 'Tag',
8126 'Patch',
8127 'Build'],
8128 'type': 'object'},
8129 'Placement': {'additionalProperties': False,
8130 'properties': {'Directive': {'type': 'string'},
8131 'Scope': {'type': 'string'}},
8132 'required': ['Scope', 'Directive'],
8133 'type': 'object'},
8134 'PrivateAddress': {'additionalProperties': False,
8135 'properties': {'Target': {'type': 'string'}},
8136 'required': ['Target'],
8137 'type': 'object'},
8138 'PrivateAddressResults': {'additionalProperties': False,
8139 'properties': {'PrivateAddress': {'type': 'string'}},
8140 'required': ['PrivateAddress'],
8141 'type': 'object'},
8142 'ProvisioningScriptParams': {'additionalProperties': False,
8143 'properties': {'DataDir': {'type': 'string'},
8144 'DisablePackageCommands': {'type': 'boolean'},
8145 'MachineId': {'type': 'string'},
8146 'Nonce': {'type': 'string'}},
8147 'required': ['MachineId',
8148 'Nonce',
8149 'DataDir',
8150 'DisablePackageCommands'],
8151 'type': 'object'},
8152 'ProvisioningScriptResult': {'additionalProperties': False,
8153 'properties': {'Script': {'type': 'string'}},
8154 'required': ['Script'],
8155 'type': 'object'},
8156 'PublicAddress': {'additionalProperties': False,
8157 'properties': {'Target': {'type': 'string'}},
8158 'required': ['Target'],
8159 'type': 'object'},
8160 'PublicAddressResults': {'additionalProperties': False,
8161 'properties': {'PublicAddress': {'type': 'string'}},
8162 'required': ['PublicAddress'],
8163 'type': 'object'},
8164 'RelationStatus': {'additionalProperties': False,
8165 'properties': {'Endpoints': {'items': {'$ref': '#/definitions/EndpointStatus'},
8166 'type': 'array'},
8167 'Id': {'type': 'integer'},
8168 'Interface': {'type': 'string'},
8169 'Key': {'type': 'string'},
8170 'Scope': {'type': 'string'}},
8171 'required': ['Id',
8172 'Key',
8173 'Interface',
8174 'Scope',
8175 'Endpoints'],
8176 'type': 'object'},
8177 'ResolveCharmResult': {'additionalProperties': False,
8178 'properties': {'Error': {'type': 'string'},
8179 'URL': {'$ref': '#/definitions/URL'}},
8180 'type': 'object'},
8181 'ResolveCharmResults': {'additionalProperties': False,
8182 'properties': {'URLs': {'items': {'$ref': '#/definitions/ResolveCharmResult'},
8183 'type': 'array'}},
8184 'required': ['URLs'],
8185 'type': 'object'},
8186 'ResolveCharms': {'additionalProperties': False,
8187 'properties': {'References': {'items': {'$ref': '#/definitions/URL'},
8188 'type': 'array'}},
8189 'required': ['References'],
8190 'type': 'object'},
8191 'Resolved': {'additionalProperties': False,
8192 'properties': {'Retry': {'type': 'boolean'},
8193 'UnitName': {'type': 'string'}},
8194 'required': ['UnitName', 'Retry'],
8195 'type': 'object'},
8196 'SetConstraints': {'additionalProperties': False,
8197 'properties': {'ApplicationName': {'type': 'string'},
8198 'Constraints': {'$ref': '#/definitions/Value'}},
8199 'required': ['ApplicationName',
8200 'Constraints'],
8201 'type': 'object'},
8202 'SetModelAgentVersion': {'additionalProperties': False,
8203 'properties': {'Version': {'$ref': '#/definitions/Number'}},
8204 'required': ['Version'],
8205 'type': 'object'},
8206 'StatusHistoryFilter': {'additionalProperties': False,
8207 'properties': {'Date': {'format': 'date-time',
8208 'type': 'string'},
8209 'Delta': {'type': 'integer'},
8210 'Size': {'type': 'integer'}},
8211 'required': ['Size', 'Date', 'Delta'],
8212 'type': 'object'},
8213 'StatusHistoryRequest': {'additionalProperties': False,
8214 'properties': {'Filter': {'$ref': '#/definitions/StatusHistoryFilter'},
8215 'HistoryKind': {'type': 'string'},
8216 'Size': {'type': 'integer'},
8217 'Tag': {'type': 'string'}},
8218 'required': ['HistoryKind',
8219 'Size',
8220 'Filter',
8221 'Tag'],
8222 'type': 'object'},
8223 'StatusHistoryRequests': {'additionalProperties': False,
8224 'properties': {'Requests': {'items': {'$ref': '#/definitions/StatusHistoryRequest'},
8225 'type': 'array'}},
8226 'required': ['Requests'],
8227 'type': 'object'},
8228 'StatusHistoryResult': {'additionalProperties': False,
8229 'properties': {'Error': {'$ref': '#/definitions/Error'},
8230 'History': {'$ref': '#/definitions/History'}},
8231 'required': ['History'],
8232 'type': 'object'},
8233 'StatusHistoryResults': {'additionalProperties': False,
8234 'properties': {'Results': {'items': {'$ref': '#/definitions/StatusHistoryResult'},
8235 'type': 'array'}},
8236 'required': ['Results'],
8237 'type': 'object'},
8238 'StatusParams': {'additionalProperties': False,
8239 'properties': {'Patterns': {'items': {'type': 'string'},
8240 'type': 'array'}},
8241 'required': ['Patterns'],
8242 'type': 'object'},
8243 'Tools': {'additionalProperties': False,
8244 'properties': {'sha256': {'type': 'string'},
8245 'size': {'type': 'integer'},
8246 'url': {'type': 'string'},
8247 'version': {'$ref': '#/definitions/Binary'}},
8248 'required': ['version', 'url', 'size'],
8249 'type': 'object'},
8250 'URL': {'additionalProperties': False,
8251 'properties': {'Channel': {'type': 'string'},
8252 'Name': {'type': 'string'},
8253 'Revision': {'type': 'integer'},
8254 'Schema': {'type': 'string'},
8255 'Series': {'type': 'string'},
8256 'User': {'type': 'string'}},
8257 'required': ['Schema',
8258 'User',
8259 'Name',
8260 'Revision',
8261 'Series',
8262 'Channel'],
8263 'type': 'object'},
8264 'UnitStatus': {'additionalProperties': False,
8265 'properties': {'AgentStatus': {'$ref': '#/definitions/DetailedStatus'},
8266 'Charm': {'type': 'string'},
8267 'Machine': {'type': 'string'},
8268 'OpenedPorts': {'items': {'type': 'string'},
8269 'type': 'array'},
8270 'PublicAddress': {'type': 'string'},
8271 'Subordinates': {'patternProperties': {'.*': {'$ref': '#/definitions/UnitStatus'}},
8272 'type': 'object'},
8273 'WorkloadStatus': {'$ref': '#/definitions/DetailedStatus'}},
8274 'required': ['AgentStatus',
8275 'WorkloadStatus',
8276 'Machine',
8277 'OpenedPorts',
8278 'PublicAddress',
8279 'Charm',
8280 'Subordinates'],
8281 'type': 'object'},
8282 'Value': {'additionalProperties': False,
8283 'properties': {'arch': {'type': 'string'},
8284 'container': {'type': 'string'},
8285 'cpu-cores': {'type': 'integer'},
8286 'cpu-power': {'type': 'integer'},
8287 'instance-type': {'type': 'string'},
8288 'mem': {'type': 'integer'},
8289 'root-disk': {'type': 'integer'},
8290 'spaces': {'items': {'type': 'string'},
8291 'type': 'array'},
8292 'tags': {'items': {'type': 'string'},
8293 'type': 'array'},
8294 'virt-type': {'type': 'string'}},
8295 'type': 'object'},
8296 'caveat': {'additionalProperties': False,
8297 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
8298 'location': {'$ref': '#/definitions/packet'},
8299 'verificationId': {'$ref': '#/definitions/packet'}},
8300 'required': ['location',
8301 'caveatId',
8302 'verificationId'],
8303 'type': 'object'},
8304 'packet': {'additionalProperties': False,
8305 'properties': {'headerLen': {'type': 'integer'},
8306 'start': {'type': 'integer'},
8307 'totalLen': {'type': 'integer'}},
8308 'required': ['start', 'totalLen', 'headerLen'],
8309 'type': 'object'}},
8310 'properties': {'APIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/APIHostPortsResult'}},
8311 'type': 'object'},
8312 'AbortCurrentUpgrade': {'type': 'object'},
8313 'AddCharm': {'properties': {'Params': {'$ref': '#/definitions/AddCharm'}},
8314 'type': 'object'},
8315 'AddCharmWithAuthorization': {'properties': {'Params': {'$ref': '#/definitions/AddCharmWithAuthorization'}},
8316 'type': 'object'},
8317 'AddMachines': {'properties': {'Params': {'$ref': '#/definitions/AddMachines'},
8318 'Result': {'$ref': '#/definitions/AddMachinesResults'}},
8319 'type': 'object'},
8320 'AddMachinesV2': {'properties': {'Params': {'$ref': '#/definitions/AddMachines'},
8321 'Result': {'$ref': '#/definitions/AddMachinesResults'}},
8322 'type': 'object'},
8323 'AgentVersion': {'properties': {'Result': {'$ref': '#/definitions/AgentVersionResult'}},
8324 'type': 'object'},
8325 'CharmInfo': {'properties': {'Params': {'$ref': '#/definitions/CharmInfo'},
8326 'Result': {'$ref': '#/definitions/CharmInfo'}},
8327 'type': 'object'},
8328 'DestroyMachines': {'properties': {'Params': {'$ref': '#/definitions/DestroyMachines'}},
8329 'type': 'object'},
8330 'DestroyModel': {'type': 'object'},
8331 'FindTools': {'properties': {'Params': {'$ref': '#/definitions/FindToolsParams'},
8332 'Result': {'$ref': '#/definitions/FindToolsResult'}},
8333 'type': 'object'},
8334 'FullStatus': {'properties': {'Params': {'$ref': '#/definitions/StatusParams'},
8335 'Result': {'$ref': '#/definitions/FullStatus'}},
8336 'type': 'object'},
8337 'GetBundleChanges': {'properties': {'Params': {'$ref': '#/definitions/GetBundleChangesParams'},
8338 'Result': {'$ref': '#/definitions/GetBundleChangesResults'}},
8339 'type': 'object'},
8340 'GetModelConstraints': {'properties': {'Result': {'$ref': '#/definitions/GetConstraintsResults'}},
8341 'type': 'object'},
8342 'InjectMachines': {'properties': {'Params': {'$ref': '#/definitions/AddMachines'},
8343 'Result': {'$ref': '#/definitions/AddMachinesResults'}},
8344 'type': 'object'},
8345 'ModelGet': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResults'}},
8346 'type': 'object'},
8347 'ModelInfo': {'properties': {'Result': {'$ref': '#/definitions/ModelInfo'}},
8348 'type': 'object'},
8349 'ModelSet': {'properties': {'Params': {'$ref': '#/definitions/ModelSet'}},
8350 'type': 'object'},
8351 'ModelUnset': {'properties': {'Params': {'$ref': '#/definitions/ModelUnset'}},
8352 'type': 'object'},
8353 'ModelUserInfo': {'properties': {'Result': {'$ref': '#/definitions/ModelUserInfoResults'}},
8354 'type': 'object'},
8355 'PrivateAddress': {'properties': {'Params': {'$ref': '#/definitions/PrivateAddress'},
8356 'Result': {'$ref': '#/definitions/PrivateAddressResults'}},
8357 'type': 'object'},
8358 'ProvisioningScript': {'properties': {'Params': {'$ref': '#/definitions/ProvisioningScriptParams'},
8359 'Result': {'$ref': '#/definitions/ProvisioningScriptResult'}},
8360 'type': 'object'},
8361 'PublicAddress': {'properties': {'Params': {'$ref': '#/definitions/PublicAddress'},
8362 'Result': {'$ref': '#/definitions/PublicAddressResults'}},
8363 'type': 'object'},
8364 'ResolveCharms': {'properties': {'Params': {'$ref': '#/definitions/ResolveCharms'},
8365 'Result': {'$ref': '#/definitions/ResolveCharmResults'}},
8366 'type': 'object'},
8367 'Resolved': {'properties': {'Params': {'$ref': '#/definitions/Resolved'}},
8368 'type': 'object'},
8369 'RetryProvisioning': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
8370 'Result': {'$ref': '#/definitions/ErrorResults'}},
8371 'type': 'object'},
8372 'SetModelAgentVersion': {'properties': {'Params': {'$ref': '#/definitions/SetModelAgentVersion'}},
8373 'type': 'object'},
8374 'SetModelConstraints': {'properties': {'Params': {'$ref': '#/definitions/SetConstraints'}},
8375 'type': 'object'},
8376 'StatusHistory': {'properties': {'Params': {'$ref': '#/definitions/StatusHistoryRequests'},
8377 'Result': {'$ref': '#/definitions/StatusHistoryResults'}},
8378 'type': 'object'},
8379 'WatchAll': {'properties': {'Result': {'$ref': '#/definitions/AllWatcherId'}},
8380 'type': 'object'}},
8381 'type': 'object'}
8382
8383
8384 @ReturnMapping(APIHostPortsResult)
8385 async def APIHostPorts(self):
8386 '''
8387
8388 Returns -> typing.Sequence[~HostPort]
8389 '''
8390 # map input types to rpc msg
8391 params = dict()
8392 msg = dict(Type='Client', Request='APIHostPorts', Version=1, Params=params)
8393
8394 reply = await self.rpc(msg)
8395 return reply
8396
8397
8398
8399 @ReturnMapping(None)
8400 async def AbortCurrentUpgrade(self):
8401 '''
8402
8403 Returns -> None
8404 '''
8405 # map input types to rpc msg
8406 params = dict()
8407 msg = dict(Type='Client', Request='AbortCurrentUpgrade', Version=1, Params=params)
8408
8409 reply = await self.rpc(msg)
8410 return reply
8411
8412
8413
8414 @ReturnMapping(None)
8415 async def AddCharm(self, channel, url):
8416 '''
8417 channel : str
8418 url : str
8419 Returns -> None
8420 '''
8421 # map input types to rpc msg
8422 params = dict()
8423 msg = dict(Type='Client', Request='AddCharm', Version=1, Params=params)
8424 params['Channel'] = channel
8425 params['URL'] = url
8426 reply = await self.rpc(msg)
8427 return reply
8428
8429
8430
8431 @ReturnMapping(None)
8432 async def AddCharmWithAuthorization(self, channel, charmstoremacaroon, url):
8433 '''
8434 channel : str
8435 charmstoremacaroon : Macaroon
8436 url : str
8437 Returns -> None
8438 '''
8439 # map input types to rpc msg
8440 params = dict()
8441 msg = dict(Type='Client', Request='AddCharmWithAuthorization', Version=1, Params=params)
8442 params['Channel'] = channel
8443 params['CharmStoreMacaroon'] = charmstoremacaroon
8444 params['URL'] = url
8445 reply = await self.rpc(msg)
8446 return reply
8447
8448
8449
8450 @ReturnMapping(AddMachinesResults)
8451 async def AddMachines(self, machineparams):
8452 '''
8453 machineparams : typing.Sequence[~AddMachineParams]
8454 Returns -> typing.Sequence[~AddMachinesResult]
8455 '''
8456 # map input types to rpc msg
8457 params = dict()
8458 msg = dict(Type='Client', Request='AddMachines', Version=1, Params=params)
8459 params['MachineParams'] = machineparams
8460 reply = await self.rpc(msg)
8461 return reply
8462
8463
8464
8465 @ReturnMapping(AddMachinesResults)
8466 async def AddMachinesV2(self, machineparams):
8467 '''
8468 machineparams : typing.Sequence[~AddMachineParams]
8469 Returns -> typing.Sequence[~AddMachinesResult]
8470 '''
8471 # map input types to rpc msg
8472 params = dict()
8473 msg = dict(Type='Client', Request='AddMachinesV2', Version=1, Params=params)
8474 params['MachineParams'] = machineparams
8475 reply = await self.rpc(msg)
8476 return reply
8477
8478
8479
8480 @ReturnMapping(AgentVersionResult)
8481 async def AgentVersion(self):
8482 '''
8483
8484 Returns -> Number
8485 '''
8486 # map input types to rpc msg
8487 params = dict()
8488 msg = dict(Type='Client', Request='AgentVersion', Version=1, Params=params)
8489
8490 reply = await self.rpc(msg)
8491 return reply
8492
8493
8494
8495 @ReturnMapping(CharmInfo)
8496 async def CharmInfo(self, charmurl):
8497 '''
8498 charmurl : str
8499 Returns -> str
8500 '''
8501 # map input types to rpc msg
8502 params = dict()
8503 msg = dict(Type='Client', Request='CharmInfo', Version=1, Params=params)
8504 params['CharmURL'] = charmurl
8505 reply = await self.rpc(msg)
8506 return reply
8507
8508
8509
8510 @ReturnMapping(None)
8511 async def DestroyMachines(self, force, machinenames):
8512 '''
8513 force : bool
8514 machinenames : typing.Sequence[str]
8515 Returns -> None
8516 '''
8517 # map input types to rpc msg
8518 params = dict()
8519 msg = dict(Type='Client', Request='DestroyMachines', Version=1, Params=params)
8520 params['Force'] = force
8521 params['MachineNames'] = machinenames
8522 reply = await self.rpc(msg)
8523 return reply
8524
8525
8526
8527 @ReturnMapping(None)
8528 async def DestroyModel(self):
8529 '''
8530
8531 Returns -> None
8532 '''
8533 # map input types to rpc msg
8534 params = dict()
8535 msg = dict(Type='Client', Request='DestroyModel', Version=1, Params=params)
8536
8537 reply = await self.rpc(msg)
8538 return reply
8539
8540
8541
8542 @ReturnMapping(FindToolsResult)
8543 async def FindTools(self, arch, majorversion, minorversion, number, series):
8544 '''
8545 arch : str
8546 majorversion : int
8547 minorversion : int
8548 number : Number
8549 series : str
8550 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[~Tools]]
8551 '''
8552 # map input types to rpc msg
8553 params = dict()
8554 msg = dict(Type='Client', Request='FindTools', Version=1, Params=params)
8555 params['Arch'] = arch
8556 params['MajorVersion'] = majorversion
8557 params['MinorVersion'] = minorversion
8558 params['Number'] = number
8559 params['Series'] = series
8560 reply = await self.rpc(msg)
8561 return reply
8562
8563
8564
8565 @ReturnMapping(FullStatus)
8566 async def FullStatus(self, patterns):
8567 '''
8568 patterns : typing.Sequence[str]
8569 Returns -> typing.Union[typing.Mapping[str, ~MachineStatus], typing.Sequence[~RelationStatus]]
8570 '''
8571 # map input types to rpc msg
8572 params = dict()
8573 msg = dict(Type='Client', Request='FullStatus', Version=1, Params=params)
8574 params['Patterns'] = patterns
8575 reply = await self.rpc(msg)
8576 return reply
8577
8578
8579
8580 @ReturnMapping(GetBundleChangesResults)
8581 async def GetBundleChanges(self, yaml):
8582 '''
8583 yaml : str
8584 Returns -> typing.Sequence[~BundleChangesChange]
8585 '''
8586 # map input types to rpc msg
8587 params = dict()
8588 msg = dict(Type='Client', Request='GetBundleChanges', Version=1, Params=params)
8589 params['yaml'] = yaml
8590 reply = await self.rpc(msg)
8591 return reply
8592
8593
8594
8595 @ReturnMapping(GetConstraintsResults)
8596 async def GetModelConstraints(self):
8597 '''
8598
8599 Returns -> Value
8600 '''
8601 # map input types to rpc msg
8602 params = dict()
8603 msg = dict(Type='Client', Request='GetModelConstraints', Version=1, Params=params)
8604
8605 reply = await self.rpc(msg)
8606 return reply
8607
8608
8609
8610 @ReturnMapping(AddMachinesResults)
8611 async def InjectMachines(self, machineparams):
8612 '''
8613 machineparams : typing.Sequence[~AddMachineParams]
8614 Returns -> typing.Sequence[~AddMachinesResult]
8615 '''
8616 # map input types to rpc msg
8617 params = dict()
8618 msg = dict(Type='Client', Request='InjectMachines', Version=1, Params=params)
8619 params['MachineParams'] = machineparams
8620 reply = await self.rpc(msg)
8621 return reply
8622
8623
8624
8625 @ReturnMapping(ModelConfigResults)
8626 async def ModelGet(self):
8627 '''
8628
8629 Returns -> typing.Mapping[str, typing.Any]
8630 '''
8631 # map input types to rpc msg
8632 params = dict()
8633 msg = dict(Type='Client', Request='ModelGet', Version=1, Params=params)
8634
8635 reply = await self.rpc(msg)
8636 return reply
8637
8638
8639
8640 @ReturnMapping(ModelInfo)
8641 async def ModelInfo(self):
8642 '''
8643
8644 Returns -> typing.Union[_ForwardRef('EntityStatus'), typing.Sequence[~ModelUserInfo]]
8645 '''
8646 # map input types to rpc msg
8647 params = dict()
8648 msg = dict(Type='Client', Request='ModelInfo', Version=1, Params=params)
8649
8650 reply = await self.rpc(msg)
8651 return reply
8652
8653
8654
8655 @ReturnMapping(None)
8656 async def ModelSet(self, config):
8657 '''
8658 config : typing.Mapping[str, typing.Any]
8659 Returns -> None
8660 '''
8661 # map input types to rpc msg
8662 params = dict()
8663 msg = dict(Type='Client', Request='ModelSet', Version=1, Params=params)
8664 params['Config'] = config
8665 reply = await self.rpc(msg)
8666 return reply
8667
8668
8669
8670 @ReturnMapping(None)
8671 async def ModelUnset(self, keys):
8672 '''
8673 keys : typing.Sequence[str]
8674 Returns -> None
8675 '''
8676 # map input types to rpc msg
8677 params = dict()
8678 msg = dict(Type='Client', Request='ModelUnset', Version=1, Params=params)
8679 params['Keys'] = keys
8680 reply = await self.rpc(msg)
8681 return reply
8682
8683
8684
8685 @ReturnMapping(ModelUserInfoResults)
8686 async def ModelUserInfo(self):
8687 '''
8688
8689 Returns -> typing.Sequence[~ModelUserInfoResult]
8690 '''
8691 # map input types to rpc msg
8692 params = dict()
8693 msg = dict(Type='Client', Request='ModelUserInfo', Version=1, Params=params)
8694
8695 reply = await self.rpc(msg)
8696 return reply
8697
8698
8699
8700 @ReturnMapping(PrivateAddressResults)
8701 async def PrivateAddress(self, target):
8702 '''
8703 target : str
8704 Returns -> str
8705 '''
8706 # map input types to rpc msg
8707 params = dict()
8708 msg = dict(Type='Client', Request='PrivateAddress', Version=1, Params=params)
8709 params['Target'] = target
8710 reply = await self.rpc(msg)
8711 return reply
8712
8713
8714
8715 @ReturnMapping(ProvisioningScriptResult)
8716 async def ProvisioningScript(self, datadir, disablepackagecommands, machineid, nonce):
8717 '''
8718 datadir : str
8719 disablepackagecommands : bool
8720 machineid : str
8721 nonce : str
8722 Returns -> str
8723 '''
8724 # map input types to rpc msg
8725 params = dict()
8726 msg = dict(Type='Client', Request='ProvisioningScript', Version=1, Params=params)
8727 params['DataDir'] = datadir
8728 params['DisablePackageCommands'] = disablepackagecommands
8729 params['MachineId'] = machineid
8730 params['Nonce'] = nonce
8731 reply = await self.rpc(msg)
8732 return reply
8733
8734
8735
8736 @ReturnMapping(PublicAddressResults)
8737 async def PublicAddress(self, target):
8738 '''
8739 target : str
8740 Returns -> str
8741 '''
8742 # map input types to rpc msg
8743 params = dict()
8744 msg = dict(Type='Client', Request='PublicAddress', Version=1, Params=params)
8745 params['Target'] = target
8746 reply = await self.rpc(msg)
8747 return reply
8748
8749
8750
8751 @ReturnMapping(ResolveCharmResults)
8752 async def ResolveCharms(self, references):
8753 '''
8754 references : typing.Sequence[~URL]
8755 Returns -> typing.Sequence[~ResolveCharmResult]
8756 '''
8757 # map input types to rpc msg
8758 params = dict()
8759 msg = dict(Type='Client', Request='ResolveCharms', Version=1, Params=params)
8760 params['References'] = references
8761 reply = await self.rpc(msg)
8762 return reply
8763
8764
8765
8766 @ReturnMapping(None)
8767 async def Resolved(self, retry, unitname):
8768 '''
8769 retry : bool
8770 unitname : str
8771 Returns -> None
8772 '''
8773 # map input types to rpc msg
8774 params = dict()
8775 msg = dict(Type='Client', Request='Resolved', Version=1, Params=params)
8776 params['Retry'] = retry
8777 params['UnitName'] = unitname
8778 reply = await self.rpc(msg)
8779 return reply
8780
8781
8782
8783 @ReturnMapping(ErrorResults)
8784 async def RetryProvisioning(self, entities):
8785 '''
8786 entities : typing.Sequence[~Entity]
8787 Returns -> typing.Sequence[~ErrorResult]
8788 '''
8789 # map input types to rpc msg
8790 params = dict()
8791 msg = dict(Type='Client', Request='RetryProvisioning', Version=1, Params=params)
8792 params['Entities'] = entities
8793 reply = await self.rpc(msg)
8794 return reply
8795
8796
8797
8798 @ReturnMapping(None)
8799 async def SetModelAgentVersion(self, build, major, minor, patch, tag):
8800 '''
8801 build : int
8802 major : int
8803 minor : int
8804 patch : int
8805 tag : str
8806 Returns -> None
8807 '''
8808 # map input types to rpc msg
8809 params = dict()
8810 msg = dict(Type='Client', Request='SetModelAgentVersion', Version=1, Params=params)
8811 params['Build'] = build
8812 params['Major'] = major
8813 params['Minor'] = minor
8814 params['Patch'] = patch
8815 params['Tag'] = tag
8816 reply = await self.rpc(msg)
8817 return reply
8818
8819
8820
8821 @ReturnMapping(None)
8822 async def SetModelConstraints(self, applicationname, constraints):
8823 '''
8824 applicationname : str
8825 constraints : Value
8826 Returns -> None
8827 '''
8828 # map input types to rpc msg
8829 params = dict()
8830 msg = dict(Type='Client', Request='SetModelConstraints', Version=1, Params=params)
8831 params['ApplicationName'] = applicationname
8832 params['Constraints'] = constraints
8833 reply = await self.rpc(msg)
8834 return reply
8835
8836
8837
8838 @ReturnMapping(StatusHistoryResults)
8839 async def StatusHistory(self, requests):
8840 '''
8841 requests : typing.Sequence[~StatusHistoryRequest]
8842 Returns -> typing.Sequence[~StatusHistoryResult]
8843 '''
8844 # map input types to rpc msg
8845 params = dict()
8846 msg = dict(Type='Client', Request='StatusHistory', Version=1, Params=params)
8847 params['Requests'] = requests
8848 reply = await self.rpc(msg)
8849 return reply
8850
8851
8852
8853 @ReturnMapping(AllWatcherId)
8854 async def WatchAll(self):
8855 '''
8856
8857 Returns -> str
8858 '''
8859 # map input types to rpc msg
8860 params = dict()
8861 msg = dict(Type='Client', Request='WatchAll', Version=1, Params=params)
8862
8863 reply = await self.rpc(msg)
8864 return reply
8865
8866
8867 class ControllerFacade(Type):
8868 name = 'Controller'
8869 version = 3
8870 schema = {'definitions': {'AllWatcherId': {'additionalProperties': False,
8871 'properties': {'AllWatcherId': {'type': 'string'}},
8872 'required': ['AllWatcherId'],
8873 'type': 'object'},
8874 'DestroyControllerArgs': {'additionalProperties': False,
8875 'properties': {'destroy-models': {'type': 'boolean'}},
8876 'required': ['destroy-models'],
8877 'type': 'object'},
8878 'Entities': {'additionalProperties': False,
8879 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
8880 'type': 'array'}},
8881 'required': ['Entities'],
8882 'type': 'object'},
8883 'Entity': {'additionalProperties': False,
8884 'properties': {'Tag': {'type': 'string'}},
8885 'required': ['Tag'],
8886 'type': 'object'},
8887 'Error': {'additionalProperties': False,
8888 'properties': {'Code': {'type': 'string'},
8889 'Info': {'$ref': '#/definitions/ErrorInfo'},
8890 'Message': {'type': 'string'}},
8891 'required': ['Message', 'Code'],
8892 'type': 'object'},
8893 'ErrorInfo': {'additionalProperties': False,
8894 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
8895 'MacaroonPath': {'type': 'string'}},
8896 'type': 'object'},
8897 'InitiateModelMigrationArgs': {'additionalProperties': False,
8898 'properties': {'specs': {'items': {'$ref': '#/definitions/ModelMigrationSpec'},
8899 'type': 'array'}},
8900 'required': ['specs'],
8901 'type': 'object'},
8902 'InitiateModelMigrationResult': {'additionalProperties': False,
8903 'properties': {'error': {'$ref': '#/definitions/Error'},
8904 'id': {'type': 'string'},
8905 'model-tag': {'type': 'string'}},
8906 'required': ['model-tag',
8907 'error',
8908 'id'],
8909 'type': 'object'},
8910 'InitiateModelMigrationResults': {'additionalProperties': False,
8911 'properties': {'results': {'items': {'$ref': '#/definitions/InitiateModelMigrationResult'},
8912 'type': 'array'}},
8913 'required': ['results'],
8914 'type': 'object'},
8915 'Macaroon': {'additionalProperties': False,
8916 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
8917 'type': 'array'},
8918 'data': {'items': {'type': 'integer'},
8919 'type': 'array'},
8920 'id': {'$ref': '#/definitions/packet'},
8921 'location': {'$ref': '#/definitions/packet'},
8922 'sig': {'items': {'type': 'integer'},
8923 'type': 'array'}},
8924 'required': ['data',
8925 'location',
8926 'id',
8927 'caveats',
8928 'sig'],
8929 'type': 'object'},
8930 'Model': {'additionalProperties': False,
8931 'properties': {'Name': {'type': 'string'},
8932 'OwnerTag': {'type': 'string'},
8933 'UUID': {'type': 'string'}},
8934 'required': ['Name', 'UUID', 'OwnerTag'],
8935 'type': 'object'},
8936 'ModelBlockInfo': {'additionalProperties': False,
8937 'properties': {'blocks': {'items': {'type': 'string'},
8938 'type': 'array'},
8939 'model-uuid': {'type': 'string'},
8940 'name': {'type': 'string'},
8941 'owner-tag': {'type': 'string'}},
8942 'required': ['name',
8943 'model-uuid',
8944 'owner-tag',
8945 'blocks'],
8946 'type': 'object'},
8947 'ModelBlockInfoList': {'additionalProperties': False,
8948 'properties': {'models': {'items': {'$ref': '#/definitions/ModelBlockInfo'},
8949 'type': 'array'}},
8950 'type': 'object'},
8951 'ModelConfigResults': {'additionalProperties': False,
8952 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
8953 'type': 'object'}},
8954 'type': 'object'}},
8955 'required': ['Config'],
8956 'type': 'object'},
8957 'ModelMigrationSpec': {'additionalProperties': False,
8958 'properties': {'model-tag': {'type': 'string'},
8959 'target-info': {'$ref': '#/definitions/ModelMigrationTargetInfo'}},
8960 'required': ['model-tag',
8961 'target-info'],
8962 'type': 'object'},
8963 'ModelMigrationTargetInfo': {'additionalProperties': False,
8964 'properties': {'addrs': {'items': {'type': 'string'},
8965 'type': 'array'},
8966 'auth-tag': {'type': 'string'},
8967 'ca-cert': {'type': 'string'},
8968 'controller-tag': {'type': 'string'},
8969 'password': {'type': 'string'}},
8970 'required': ['controller-tag',
8971 'addrs',
8972 'ca-cert',
8973 'auth-tag',
8974 'password'],
8975 'type': 'object'},
8976 'ModelStatus': {'additionalProperties': False,
8977 'properties': {'application-count': {'type': 'integer'},
8978 'hosted-machine-count': {'type': 'integer'},
8979 'life': {'type': 'string'},
8980 'model-tag': {'type': 'string'},
8981 'owner-tag': {'type': 'string'}},
8982 'required': ['model-tag',
8983 'life',
8984 'hosted-machine-count',
8985 'application-count',
8986 'owner-tag'],
8987 'type': 'object'},
8988 'ModelStatusResults': {'additionalProperties': False,
8989 'properties': {'models': {'items': {'$ref': '#/definitions/ModelStatus'},
8990 'type': 'array'}},
8991 'required': ['models'],
8992 'type': 'object'},
8993 'RemoveBlocksArgs': {'additionalProperties': False,
8994 'properties': {'all': {'type': 'boolean'}},
8995 'required': ['all'],
8996 'type': 'object'},
8997 'UserModel': {'additionalProperties': False,
8998 'properties': {'LastConnection': {'format': 'date-time',
8999 'type': 'string'},
9000 'Model': {'$ref': '#/definitions/Model'}},
9001 'required': ['Model', 'LastConnection'],
9002 'type': 'object'},
9003 'UserModelList': {'additionalProperties': False,
9004 'properties': {'UserModels': {'items': {'$ref': '#/definitions/UserModel'},
9005 'type': 'array'}},
9006 'required': ['UserModels'],
9007 'type': 'object'},
9008 'caveat': {'additionalProperties': False,
9009 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
9010 'location': {'$ref': '#/definitions/packet'},
9011 'verificationId': {'$ref': '#/definitions/packet'}},
9012 'required': ['location',
9013 'caveatId',
9014 'verificationId'],
9015 'type': 'object'},
9016 'packet': {'additionalProperties': False,
9017 'properties': {'headerLen': {'type': 'integer'},
9018 'start': {'type': 'integer'},
9019 'totalLen': {'type': 'integer'}},
9020 'required': ['start', 'totalLen', 'headerLen'],
9021 'type': 'object'}},
9022 'properties': {'AllModels': {'properties': {'Result': {'$ref': '#/definitions/UserModelList'}},
9023 'type': 'object'},
9024 'DestroyController': {'properties': {'Params': {'$ref': '#/definitions/DestroyControllerArgs'}},
9025 'type': 'object'},
9026 'InitiateModelMigration': {'properties': {'Params': {'$ref': '#/definitions/InitiateModelMigrationArgs'},
9027 'Result': {'$ref': '#/definitions/InitiateModelMigrationResults'}},
9028 'type': 'object'},
9029 'ListBlockedModels': {'properties': {'Result': {'$ref': '#/definitions/ModelBlockInfoList'}},
9030 'type': 'object'},
9031 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResults'}},
9032 'type': 'object'},
9033 'ModelStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
9034 'Result': {'$ref': '#/definitions/ModelStatusResults'}},
9035 'type': 'object'},
9036 'RemoveBlocks': {'properties': {'Params': {'$ref': '#/definitions/RemoveBlocksArgs'}},
9037 'type': 'object'},
9038 'WatchAllModels': {'properties': {'Result': {'$ref': '#/definitions/AllWatcherId'}},
9039 'type': 'object'}},
9040 'type': 'object'}
9041
9042
9043 @ReturnMapping(UserModelList)
9044 async def AllModels(self):
9045 '''
9046
9047 Returns -> typing.Sequence[~UserModel]
9048 '''
9049 # map input types to rpc msg
9050 params = dict()
9051 msg = dict(Type='Controller', Request='AllModels', Version=3, Params=params)
9052
9053 reply = await self.rpc(msg)
9054 return reply
9055
9056
9057
9058 @ReturnMapping(None)
9059 async def DestroyController(self, destroy_models):
9060 '''
9061 destroy_models : bool
9062 Returns -> None
9063 '''
9064 # map input types to rpc msg
9065 params = dict()
9066 msg = dict(Type='Controller', Request='DestroyController', Version=3, Params=params)
9067 params['destroy-models'] = destroy_models
9068 reply = await self.rpc(msg)
9069 return reply
9070
9071
9072
9073 @ReturnMapping(InitiateModelMigrationResults)
9074 async def InitiateModelMigration(self, specs):
9075 '''
9076 specs : typing.Sequence[~ModelMigrationSpec]
9077 Returns -> typing.Sequence[~InitiateModelMigrationResult]
9078 '''
9079 # map input types to rpc msg
9080 params = dict()
9081 msg = dict(Type='Controller', Request='InitiateModelMigration', Version=3, Params=params)
9082 params['specs'] = specs
9083 reply = await self.rpc(msg)
9084 return reply
9085
9086
9087
9088 @ReturnMapping(ModelBlockInfoList)
9089 async def ListBlockedModels(self):
9090 '''
9091
9092 Returns -> typing.Sequence[~ModelBlockInfo]
9093 '''
9094 # map input types to rpc msg
9095 params = dict()
9096 msg = dict(Type='Controller', Request='ListBlockedModels', Version=3, Params=params)
9097
9098 reply = await self.rpc(msg)
9099 return reply
9100
9101
9102
9103 @ReturnMapping(ModelConfigResults)
9104 async def ModelConfig(self):
9105 '''
9106
9107 Returns -> typing.Mapping[str, typing.Any]
9108 '''
9109 # map input types to rpc msg
9110 params = dict()
9111 msg = dict(Type='Controller', Request='ModelConfig', Version=3, Params=params)
9112
9113 reply = await self.rpc(msg)
9114 return reply
9115
9116
9117
9118 @ReturnMapping(ModelStatusResults)
9119 async def ModelStatus(self, entities):
9120 '''
9121 entities : typing.Sequence[~Entity]
9122 Returns -> typing.Sequence[~ModelStatus]
9123 '''
9124 # map input types to rpc msg
9125 params = dict()
9126 msg = dict(Type='Controller', Request='ModelStatus', Version=3, Params=params)
9127 params['Entities'] = entities
9128 reply = await self.rpc(msg)
9129 return reply
9130
9131
9132
9133 @ReturnMapping(None)
9134 async def RemoveBlocks(self, all_):
9135 '''
9136 all_ : bool
9137 Returns -> None
9138 '''
9139 # map input types to rpc msg
9140 params = dict()
9141 msg = dict(Type='Controller', Request='RemoveBlocks', Version=3, Params=params)
9142 params['all'] = all_
9143 reply = await self.rpc(msg)
9144 return reply
9145
9146
9147
9148 @ReturnMapping(AllWatcherId)
9149 async def WatchAllModels(self):
9150 '''
9151
9152 Returns -> str
9153 '''
9154 # map input types to rpc msg
9155 params = dict()
9156 msg = dict(Type='Controller', Request='WatchAllModels', Version=3, Params=params)
9157
9158 reply = await self.rpc(msg)
9159 return reply
9160
9161
9162 class DeployerFacade(Type):
9163 name = 'Deployer'
9164 version = 1
9165 schema = {'definitions': {'APIHostPortsResult': {'additionalProperties': False,
9166 'properties': {'Servers': {'items': {'items': {'$ref': '#/definitions/HostPort'},
9167 'type': 'array'},
9168 'type': 'array'}},
9169 'required': ['Servers'],
9170 'type': 'object'},
9171 'Address': {'additionalProperties': False,
9172 'properties': {'Scope': {'type': 'string'},
9173 'SpaceName': {'type': 'string'},
9174 'Type': {'type': 'string'},
9175 'Value': {'type': 'string'}},
9176 'required': ['Value', 'Type', 'Scope'],
9177 'type': 'object'},
9178 'BytesResult': {'additionalProperties': False,
9179 'properties': {'Result': {'items': {'type': 'integer'},
9180 'type': 'array'}},
9181 'required': ['Result'],
9182 'type': 'object'},
9183 'DeployerConnectionValues': {'additionalProperties': False,
9184 'properties': {'APIAddresses': {'items': {'type': 'string'},
9185 'type': 'array'},
9186 'StateAddresses': {'items': {'type': 'string'},
9187 'type': 'array'}},
9188 'required': ['StateAddresses',
9189 'APIAddresses'],
9190 'type': 'object'},
9191 'Entities': {'additionalProperties': False,
9192 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
9193 'type': 'array'}},
9194 'required': ['Entities'],
9195 'type': 'object'},
9196 'Entity': {'additionalProperties': False,
9197 'properties': {'Tag': {'type': 'string'}},
9198 'required': ['Tag'],
9199 'type': 'object'},
9200 'EntityPassword': {'additionalProperties': False,
9201 'properties': {'Password': {'type': 'string'},
9202 'Tag': {'type': 'string'}},
9203 'required': ['Tag', 'Password'],
9204 'type': 'object'},
9205 'EntityPasswords': {'additionalProperties': False,
9206 'properties': {'Changes': {'items': {'$ref': '#/definitions/EntityPassword'},
9207 'type': 'array'}},
9208 'required': ['Changes'],
9209 'type': 'object'},
9210 'Error': {'additionalProperties': False,
9211 'properties': {'Code': {'type': 'string'},
9212 'Info': {'$ref': '#/definitions/ErrorInfo'},
9213 'Message': {'type': 'string'}},
9214 'required': ['Message', 'Code'],
9215 'type': 'object'},
9216 'ErrorInfo': {'additionalProperties': False,
9217 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
9218 'MacaroonPath': {'type': 'string'}},
9219 'type': 'object'},
9220 'ErrorResult': {'additionalProperties': False,
9221 'properties': {'Error': {'$ref': '#/definitions/Error'}},
9222 'required': ['Error'],
9223 'type': 'object'},
9224 'ErrorResults': {'additionalProperties': False,
9225 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
9226 'type': 'array'}},
9227 'required': ['Results'],
9228 'type': 'object'},
9229 'HostPort': {'additionalProperties': False,
9230 'properties': {'Address': {'$ref': '#/definitions/Address'},
9231 'Port': {'type': 'integer'}},
9232 'required': ['Address', 'Port'],
9233 'type': 'object'},
9234 'LifeResult': {'additionalProperties': False,
9235 'properties': {'Error': {'$ref': '#/definitions/Error'},
9236 'Life': {'type': 'string'}},
9237 'required': ['Life', 'Error'],
9238 'type': 'object'},
9239 'LifeResults': {'additionalProperties': False,
9240 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
9241 'type': 'array'}},
9242 'required': ['Results'],
9243 'type': 'object'},
9244 'Macaroon': {'additionalProperties': False,
9245 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
9246 'type': 'array'},
9247 'data': {'items': {'type': 'integer'},
9248 'type': 'array'},
9249 'id': {'$ref': '#/definitions/packet'},
9250 'location': {'$ref': '#/definitions/packet'},
9251 'sig': {'items': {'type': 'integer'},
9252 'type': 'array'}},
9253 'required': ['data',
9254 'location',
9255 'id',
9256 'caveats',
9257 'sig'],
9258 'type': 'object'},
9259 'NotifyWatchResult': {'additionalProperties': False,
9260 'properties': {'Error': {'$ref': '#/definitions/Error'},
9261 'NotifyWatcherId': {'type': 'string'}},
9262 'required': ['NotifyWatcherId', 'Error'],
9263 'type': 'object'},
9264 'StringResult': {'additionalProperties': False,
9265 'properties': {'Error': {'$ref': '#/definitions/Error'},
9266 'Result': {'type': 'string'}},
9267 'required': ['Error', 'Result'],
9268 'type': 'object'},
9269 'StringsResult': {'additionalProperties': False,
9270 'properties': {'Error': {'$ref': '#/definitions/Error'},
9271 'Result': {'items': {'type': 'string'},
9272 'type': 'array'}},
9273 'required': ['Error', 'Result'],
9274 'type': 'object'},
9275 'StringsWatchResult': {'additionalProperties': False,
9276 'properties': {'Changes': {'items': {'type': 'string'},
9277 'type': 'array'},
9278 'Error': {'$ref': '#/definitions/Error'},
9279 'StringsWatcherId': {'type': 'string'}},
9280 'required': ['StringsWatcherId',
9281 'Changes',
9282 'Error'],
9283 'type': 'object'},
9284 'StringsWatchResults': {'additionalProperties': False,
9285 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsWatchResult'},
9286 'type': 'array'}},
9287 'required': ['Results'],
9288 'type': 'object'},
9289 'caveat': {'additionalProperties': False,
9290 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
9291 'location': {'$ref': '#/definitions/packet'},
9292 'verificationId': {'$ref': '#/definitions/packet'}},
9293 'required': ['location',
9294 'caveatId',
9295 'verificationId'],
9296 'type': 'object'},
9297 'packet': {'additionalProperties': False,
9298 'properties': {'headerLen': {'type': 'integer'},
9299 'start': {'type': 'integer'},
9300 'totalLen': {'type': 'integer'}},
9301 'required': ['start', 'totalLen', 'headerLen'],
9302 'type': 'object'}},
9303 'properties': {'APIAddresses': {'properties': {'Result': {'$ref': '#/definitions/StringsResult'}},
9304 'type': 'object'},
9305 'APIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/APIHostPortsResult'}},
9306 'type': 'object'},
9307 'CACert': {'properties': {'Result': {'$ref': '#/definitions/BytesResult'}},
9308 'type': 'object'},
9309 'ConnectionInfo': {'properties': {'Result': {'$ref': '#/definitions/DeployerConnectionValues'}},
9310 'type': 'object'},
9311 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
9312 'Result': {'$ref': '#/definitions/LifeResults'}},
9313 'type': 'object'},
9314 'ModelUUID': {'properties': {'Result': {'$ref': '#/definitions/StringResult'}},
9315 'type': 'object'},
9316 'Remove': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
9317 'Result': {'$ref': '#/definitions/ErrorResults'}},
9318 'type': 'object'},
9319 'SetPasswords': {'properties': {'Params': {'$ref': '#/definitions/EntityPasswords'},
9320 'Result': {'$ref': '#/definitions/ErrorResults'}},
9321 'type': 'object'},
9322 'StateAddresses': {'properties': {'Result': {'$ref': '#/definitions/StringsResult'}},
9323 'type': 'object'},
9324 'WatchAPIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
9325 'type': 'object'},
9326 'WatchUnits': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
9327 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
9328 'type': 'object'}},
9329 'type': 'object'}
9330
9331
9332 @ReturnMapping(StringsResult)
9333 async def APIAddresses(self):
9334 '''
9335
9336 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[str]]
9337 '''
9338 # map input types to rpc msg
9339 params = dict()
9340 msg = dict(Type='Deployer', Request='APIAddresses', Version=1, Params=params)
9341
9342 reply = await self.rpc(msg)
9343 return reply
9344
9345
9346
9347 @ReturnMapping(APIHostPortsResult)
9348 async def APIHostPorts(self):
9349 '''
9350
9351 Returns -> typing.Sequence[~HostPort]
9352 '''
9353 # map input types to rpc msg
9354 params = dict()
9355 msg = dict(Type='Deployer', Request='APIHostPorts', Version=1, Params=params)
9356
9357 reply = await self.rpc(msg)
9358 return reply
9359
9360
9361
9362 @ReturnMapping(BytesResult)
9363 async def CACert(self):
9364 '''
9365
9366 Returns -> typing.Sequence[int]
9367 '''
9368 # map input types to rpc msg
9369 params = dict()
9370 msg = dict(Type='Deployer', Request='CACert', Version=1, Params=params)
9371
9372 reply = await self.rpc(msg)
9373 return reply
9374
9375
9376
9377 @ReturnMapping(DeployerConnectionValues)
9378 async def ConnectionInfo(self):
9379 '''
9380
9381 Returns -> typing.Sequence[str]
9382 '''
9383 # map input types to rpc msg
9384 params = dict()
9385 msg = dict(Type='Deployer', Request='ConnectionInfo', Version=1, Params=params)
9386
9387 reply = await self.rpc(msg)
9388 return reply
9389
9390
9391
9392 @ReturnMapping(LifeResults)
9393 async def Life(self, entities):
9394 '''
9395 entities : typing.Sequence[~Entity]
9396 Returns -> typing.Sequence[~LifeResult]
9397 '''
9398 # map input types to rpc msg
9399 params = dict()
9400 msg = dict(Type='Deployer', Request='Life', Version=1, Params=params)
9401 params['Entities'] = entities
9402 reply = await self.rpc(msg)
9403 return reply
9404
9405
9406
9407 @ReturnMapping(StringResult)
9408 async def ModelUUID(self):
9409 '''
9410
9411 Returns -> typing.Union[_ForwardRef('Error'), str]
9412 '''
9413 # map input types to rpc msg
9414 params = dict()
9415 msg = dict(Type='Deployer', Request='ModelUUID', Version=1, Params=params)
9416
9417 reply = await self.rpc(msg)
9418 return reply
9419
9420
9421
9422 @ReturnMapping(ErrorResults)
9423 async def Remove(self, entities):
9424 '''
9425 entities : typing.Sequence[~Entity]
9426 Returns -> typing.Sequence[~ErrorResult]
9427 '''
9428 # map input types to rpc msg
9429 params = dict()
9430 msg = dict(Type='Deployer', Request='Remove', Version=1, Params=params)
9431 params['Entities'] = entities
9432 reply = await self.rpc(msg)
9433 return reply
9434
9435
9436
9437 @ReturnMapping(ErrorResults)
9438 async def SetPasswords(self, changes):
9439 '''
9440 changes : typing.Sequence[~EntityPassword]
9441 Returns -> typing.Sequence[~ErrorResult]
9442 '''
9443 # map input types to rpc msg
9444 params = dict()
9445 msg = dict(Type='Deployer', Request='SetPasswords', Version=1, Params=params)
9446 params['Changes'] = changes
9447 reply = await self.rpc(msg)
9448 return reply
9449
9450
9451
9452 @ReturnMapping(StringsResult)
9453 async def StateAddresses(self):
9454 '''
9455
9456 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[str]]
9457 '''
9458 # map input types to rpc msg
9459 params = dict()
9460 msg = dict(Type='Deployer', Request='StateAddresses', Version=1, Params=params)
9461
9462 reply = await self.rpc(msg)
9463 return reply
9464
9465
9466
9467 @ReturnMapping(NotifyWatchResult)
9468 async def WatchAPIHostPorts(self):
9469 '''
9470
9471 Returns -> typing.Union[_ForwardRef('Error'), str]
9472 '''
9473 # map input types to rpc msg
9474 params = dict()
9475 msg = dict(Type='Deployer', Request='WatchAPIHostPorts', Version=1, Params=params)
9476
9477 reply = await self.rpc(msg)
9478 return reply
9479
9480
9481
9482 @ReturnMapping(StringsWatchResults)
9483 async def WatchUnits(self, entities):
9484 '''
9485 entities : typing.Sequence[~Entity]
9486 Returns -> typing.Sequence[~StringsWatchResult]
9487 '''
9488 # map input types to rpc msg
9489 params = dict()
9490 msg = dict(Type='Deployer', Request='WatchUnits', Version=1, Params=params)
9491 params['Entities'] = entities
9492 reply = await self.rpc(msg)
9493 return reply
9494
9495
9496 class DiscoverSpacesFacade(Type):
9497 name = 'DiscoverSpaces'
9498 version = 2
9499 schema = {'definitions': {'AddSubnetParams': {'additionalProperties': False,
9500 'properties': {'SpaceTag': {'type': 'string'},
9501 'SubnetProviderId': {'type': 'string'},
9502 'SubnetTag': {'type': 'string'},
9503 'Zones': {'items': {'type': 'string'},
9504 'type': 'array'}},
9505 'required': ['SpaceTag'],
9506 'type': 'object'},
9507 'AddSubnetsParams': {'additionalProperties': False,
9508 'properties': {'Subnets': {'items': {'$ref': '#/definitions/AddSubnetParams'},
9509 'type': 'array'}},
9510 'required': ['Subnets'],
9511 'type': 'object'},
9512 'CreateSpaceParams': {'additionalProperties': False,
9513 'properties': {'ProviderId': {'type': 'string'},
9514 'Public': {'type': 'boolean'},
9515 'SpaceTag': {'type': 'string'},
9516 'SubnetTags': {'items': {'type': 'string'},
9517 'type': 'array'}},
9518 'required': ['SubnetTags',
9519 'SpaceTag',
9520 'Public'],
9521 'type': 'object'},
9522 'CreateSpacesParams': {'additionalProperties': False,
9523 'properties': {'Spaces': {'items': {'$ref': '#/definitions/CreateSpaceParams'},
9524 'type': 'array'}},
9525 'required': ['Spaces'],
9526 'type': 'object'},
9527 'DiscoverSpacesResults': {'additionalProperties': False,
9528 'properties': {'Results': {'items': {'$ref': '#/definitions/ProviderSpace'},
9529 'type': 'array'}},
9530 'required': ['Results'],
9531 'type': 'object'},
9532 'Error': {'additionalProperties': False,
9533 'properties': {'Code': {'type': 'string'},
9534 'Info': {'$ref': '#/definitions/ErrorInfo'},
9535 'Message': {'type': 'string'}},
9536 'required': ['Message', 'Code'],
9537 'type': 'object'},
9538 'ErrorInfo': {'additionalProperties': False,
9539 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
9540 'MacaroonPath': {'type': 'string'}},
9541 'type': 'object'},
9542 'ErrorResult': {'additionalProperties': False,
9543 'properties': {'Error': {'$ref': '#/definitions/Error'}},
9544 'required': ['Error'],
9545 'type': 'object'},
9546 'ErrorResults': {'additionalProperties': False,
9547 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
9548 'type': 'array'}},
9549 'required': ['Results'],
9550 'type': 'object'},
9551 'ListSubnetsResults': {'additionalProperties': False,
9552 'properties': {'Results': {'items': {'$ref': '#/definitions/Subnet'},
9553 'type': 'array'}},
9554 'required': ['Results'],
9555 'type': 'object'},
9556 'Macaroon': {'additionalProperties': False,
9557 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
9558 'type': 'array'},
9559 'data': {'items': {'type': 'integer'},
9560 'type': 'array'},
9561 'id': {'$ref': '#/definitions/packet'},
9562 'location': {'$ref': '#/definitions/packet'},
9563 'sig': {'items': {'type': 'integer'},
9564 'type': 'array'}},
9565 'required': ['data',
9566 'location',
9567 'id',
9568 'caveats',
9569 'sig'],
9570 'type': 'object'},
9571 'ModelConfigResult': {'additionalProperties': False,
9572 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
9573 'type': 'object'}},
9574 'type': 'object'}},
9575 'required': ['Config'],
9576 'type': 'object'},
9577 'ProviderSpace': {'additionalProperties': False,
9578 'properties': {'Error': {'$ref': '#/definitions/Error'},
9579 'Name': {'type': 'string'},
9580 'ProviderId': {'type': 'string'},
9581 'Subnets': {'items': {'$ref': '#/definitions/Subnet'},
9582 'type': 'array'}},
9583 'required': ['Name',
9584 'ProviderId',
9585 'Subnets'],
9586 'type': 'object'},
9587 'Subnet': {'additionalProperties': False,
9588 'properties': {'CIDR': {'type': 'string'},
9589 'Life': {'type': 'string'},
9590 'ProviderId': {'type': 'string'},
9591 'SpaceTag': {'type': 'string'},
9592 'StaticRangeHighIP': {'items': {'type': 'integer'},
9593 'type': 'array'},
9594 'StaticRangeLowIP': {'items': {'type': 'integer'},
9595 'type': 'array'},
9596 'Status': {'type': 'string'},
9597 'VLANTag': {'type': 'integer'},
9598 'Zones': {'items': {'type': 'string'},
9599 'type': 'array'}},
9600 'required': ['CIDR',
9601 'VLANTag',
9602 'Life',
9603 'SpaceTag',
9604 'Zones'],
9605 'type': 'object'},
9606 'SubnetsFilters': {'additionalProperties': False,
9607 'properties': {'SpaceTag': {'type': 'string'},
9608 'Zone': {'type': 'string'}},
9609 'type': 'object'},
9610 'caveat': {'additionalProperties': False,
9611 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
9612 'location': {'$ref': '#/definitions/packet'},
9613 'verificationId': {'$ref': '#/definitions/packet'}},
9614 'required': ['location',
9615 'caveatId',
9616 'verificationId'],
9617 'type': 'object'},
9618 'packet': {'additionalProperties': False,
9619 'properties': {'headerLen': {'type': 'integer'},
9620 'start': {'type': 'integer'},
9621 'totalLen': {'type': 'integer'}},
9622 'required': ['start', 'totalLen', 'headerLen'],
9623 'type': 'object'}},
9624 'properties': {'AddSubnets': {'properties': {'Params': {'$ref': '#/definitions/AddSubnetsParams'},
9625 'Result': {'$ref': '#/definitions/ErrorResults'}},
9626 'type': 'object'},
9627 'CreateSpaces': {'properties': {'Params': {'$ref': '#/definitions/CreateSpacesParams'},
9628 'Result': {'$ref': '#/definitions/ErrorResults'}},
9629 'type': 'object'},
9630 'ListSpaces': {'properties': {'Result': {'$ref': '#/definitions/DiscoverSpacesResults'}},
9631 'type': 'object'},
9632 'ListSubnets': {'properties': {'Params': {'$ref': '#/definitions/SubnetsFilters'},
9633 'Result': {'$ref': '#/definitions/ListSubnetsResults'}},
9634 'type': 'object'},
9635 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
9636 'type': 'object'}},
9637 'type': 'object'}
9638
9639
9640 @ReturnMapping(ErrorResults)
9641 async def AddSubnets(self, subnets):
9642 '''
9643 subnets : typing.Sequence[~AddSubnetParams]
9644 Returns -> typing.Sequence[~ErrorResult]
9645 '''
9646 # map input types to rpc msg
9647 params = dict()
9648 msg = dict(Type='DiscoverSpaces', Request='AddSubnets', Version=2, Params=params)
9649 params['Subnets'] = subnets
9650 reply = await self.rpc(msg)
9651 return reply
9652
9653
9654
9655 @ReturnMapping(ErrorResults)
9656 async def CreateSpaces(self, spaces):
9657 '''
9658 spaces : typing.Sequence[~CreateSpaceParams]
9659 Returns -> typing.Sequence[~ErrorResult]
9660 '''
9661 # map input types to rpc msg
9662 params = dict()
9663 msg = dict(Type='DiscoverSpaces', Request='CreateSpaces', Version=2, Params=params)
9664 params['Spaces'] = spaces
9665 reply = await self.rpc(msg)
9666 return reply
9667
9668
9669
9670 @ReturnMapping(DiscoverSpacesResults)
9671 async def ListSpaces(self):
9672 '''
9673
9674 Returns -> typing.Sequence[~ProviderSpace]
9675 '''
9676 # map input types to rpc msg
9677 params = dict()
9678 msg = dict(Type='DiscoverSpaces', Request='ListSpaces', Version=2, Params=params)
9679
9680 reply = await self.rpc(msg)
9681 return reply
9682
9683
9684
9685 @ReturnMapping(ListSubnetsResults)
9686 async def ListSubnets(self, spacetag, zone):
9687 '''
9688 spacetag : str
9689 zone : str
9690 Returns -> typing.Sequence[~Subnet]
9691 '''
9692 # map input types to rpc msg
9693 params = dict()
9694 msg = dict(Type='DiscoverSpaces', Request='ListSubnets', Version=2, Params=params)
9695 params['SpaceTag'] = spacetag
9696 params['Zone'] = zone
9697 reply = await self.rpc(msg)
9698 return reply
9699
9700
9701
9702 @ReturnMapping(ModelConfigResult)
9703 async def ModelConfig(self):
9704 '''
9705
9706 Returns -> typing.Mapping[str, typing.Any]
9707 '''
9708 # map input types to rpc msg
9709 params = dict()
9710 msg = dict(Type='DiscoverSpaces', Request='ModelConfig', Version=2, Params=params)
9711
9712 reply = await self.rpc(msg)
9713 return reply
9714
9715
9716 class DiskManagerFacade(Type):
9717 name = 'DiskManager'
9718 version = 2
9719 schema = {'definitions': {'BlockDevice': {'additionalProperties': False,
9720 'properties': {'BusAddress': {'type': 'string'},
9721 'DeviceLinks': {'items': {'type': 'string'},
9722 'type': 'array'},
9723 'DeviceName': {'type': 'string'},
9724 'FilesystemType': {'type': 'string'},
9725 'HardwareId': {'type': 'string'},
9726 'InUse': {'type': 'boolean'},
9727 'Label': {'type': 'string'},
9728 'MountPoint': {'type': 'string'},
9729 'Size': {'type': 'integer'},
9730 'UUID': {'type': 'string'}},
9731 'required': ['DeviceName',
9732 'DeviceLinks',
9733 'Label',
9734 'UUID',
9735 'HardwareId',
9736 'BusAddress',
9737 'Size',
9738 'FilesystemType',
9739 'InUse',
9740 'MountPoint'],
9741 'type': 'object'},
9742 'Error': {'additionalProperties': False,
9743 'properties': {'Code': {'type': 'string'},
9744 'Info': {'$ref': '#/definitions/ErrorInfo'},
9745 'Message': {'type': 'string'}},
9746 'required': ['Message', 'Code'],
9747 'type': 'object'},
9748 'ErrorInfo': {'additionalProperties': False,
9749 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
9750 'MacaroonPath': {'type': 'string'}},
9751 'type': 'object'},
9752 'ErrorResult': {'additionalProperties': False,
9753 'properties': {'Error': {'$ref': '#/definitions/Error'}},
9754 'required': ['Error'],
9755 'type': 'object'},
9756 'ErrorResults': {'additionalProperties': False,
9757 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
9758 'type': 'array'}},
9759 'required': ['Results'],
9760 'type': 'object'},
9761 'Macaroon': {'additionalProperties': False,
9762 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
9763 'type': 'array'},
9764 'data': {'items': {'type': 'integer'},
9765 'type': 'array'},
9766 'id': {'$ref': '#/definitions/packet'},
9767 'location': {'$ref': '#/definitions/packet'},
9768 'sig': {'items': {'type': 'integer'},
9769 'type': 'array'}},
9770 'required': ['data',
9771 'location',
9772 'id',
9773 'caveats',
9774 'sig'],
9775 'type': 'object'},
9776 'MachineBlockDevices': {'additionalProperties': False,
9777 'properties': {'blockdevices': {'items': {'$ref': '#/definitions/BlockDevice'},
9778 'type': 'array'},
9779 'machine': {'type': 'string'}},
9780 'required': ['machine'],
9781 'type': 'object'},
9782 'SetMachineBlockDevices': {'additionalProperties': False,
9783 'properties': {'machineblockdevices': {'items': {'$ref': '#/definitions/MachineBlockDevices'},
9784 'type': 'array'}},
9785 'required': ['machineblockdevices'],
9786 'type': 'object'},
9787 'caveat': {'additionalProperties': False,
9788 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
9789 'location': {'$ref': '#/definitions/packet'},
9790 'verificationId': {'$ref': '#/definitions/packet'}},
9791 'required': ['location',
9792 'caveatId',
9793 'verificationId'],
9794 'type': 'object'},
9795 'packet': {'additionalProperties': False,
9796 'properties': {'headerLen': {'type': 'integer'},
9797 'start': {'type': 'integer'},
9798 'totalLen': {'type': 'integer'}},
9799 'required': ['start', 'totalLen', 'headerLen'],
9800 'type': 'object'}},
9801 'properties': {'SetMachineBlockDevices': {'properties': {'Params': {'$ref': '#/definitions/SetMachineBlockDevices'},
9802 'Result': {'$ref': '#/definitions/ErrorResults'}},
9803 'type': 'object'}},
9804 'type': 'object'}
9805
9806
9807 @ReturnMapping(ErrorResults)
9808 async def SetMachineBlockDevices(self, machineblockdevices):
9809 '''
9810 machineblockdevices : typing.Sequence[~MachineBlockDevices]
9811 Returns -> typing.Sequence[~ErrorResult]
9812 '''
9813 # map input types to rpc msg
9814 params = dict()
9815 msg = dict(Type='DiskManager', Request='SetMachineBlockDevices', Version=2, Params=params)
9816 params['machineblockdevices'] = machineblockdevices
9817 reply = await self.rpc(msg)
9818 return reply
9819
9820
9821 class EntityWatcherFacade(Type):
9822 name = 'EntityWatcher'
9823 version = 2
9824 schema = {'definitions': {'EntitiesWatchResult': {'additionalProperties': False,
9825 'properties': {'Changes': {'items': {'type': 'string'},
9826 'type': 'array'},
9827 'EntityWatcherId': {'type': 'string'},
9828 'Error': {'$ref': '#/definitions/Error'}},
9829 'required': ['EntityWatcherId',
9830 'Changes',
9831 'Error'],
9832 'type': 'object'},
9833 'Error': {'additionalProperties': False,
9834 'properties': {'Code': {'type': 'string'},
9835 'Info': {'$ref': '#/definitions/ErrorInfo'},
9836 'Message': {'type': 'string'}},
9837 'required': ['Message', 'Code'],
9838 'type': 'object'},
9839 'ErrorInfo': {'additionalProperties': False,
9840 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
9841 'MacaroonPath': {'type': 'string'}},
9842 'type': 'object'},
9843 'Macaroon': {'additionalProperties': False,
9844 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
9845 'type': 'array'},
9846 'data': {'items': {'type': 'integer'},
9847 'type': 'array'},
9848 'id': {'$ref': '#/definitions/packet'},
9849 'location': {'$ref': '#/definitions/packet'},
9850 'sig': {'items': {'type': 'integer'},
9851 'type': 'array'}},
9852 'required': ['data',
9853 'location',
9854 'id',
9855 'caveats',
9856 'sig'],
9857 'type': 'object'},
9858 'caveat': {'additionalProperties': False,
9859 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
9860 'location': {'$ref': '#/definitions/packet'},
9861 'verificationId': {'$ref': '#/definitions/packet'}},
9862 'required': ['location',
9863 'caveatId',
9864 'verificationId'],
9865 'type': 'object'},
9866 'packet': {'additionalProperties': False,
9867 'properties': {'headerLen': {'type': 'integer'},
9868 'start': {'type': 'integer'},
9869 'totalLen': {'type': 'integer'}},
9870 'required': ['start', 'totalLen', 'headerLen'],
9871 'type': 'object'}},
9872 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/EntitiesWatchResult'}},
9873 'type': 'object'},
9874 'Stop': {'type': 'object'}},
9875 'type': 'object'}
9876
9877
9878 @ReturnMapping(EntitiesWatchResult)
9879 async def Next(self):
9880 '''
9881
9882 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
9883 '''
9884 # map input types to rpc msg
9885 params = dict()
9886 msg = dict(Type='EntityWatcher', Request='Next', Version=2, Params=params)
9887
9888 reply = await self.rpc(msg)
9889 return reply
9890
9891
9892
9893 @ReturnMapping(None)
9894 async def Stop(self):
9895 '''
9896
9897 Returns -> None
9898 '''
9899 # map input types to rpc msg
9900 params = dict()
9901 msg = dict(Type='EntityWatcher', Request='Stop', Version=2, Params=params)
9902
9903 reply = await self.rpc(msg)
9904 return reply
9905
9906
9907 class FilesystemAttachmentsWatcherFacade(Type):
9908 name = 'FilesystemAttachmentsWatcher'
9909 version = 2
9910 schema = {'definitions': {'Error': {'additionalProperties': False,
9911 'properties': {'Code': {'type': 'string'},
9912 'Info': {'$ref': '#/definitions/ErrorInfo'},
9913 'Message': {'type': 'string'}},
9914 'required': ['Message', 'Code'],
9915 'type': 'object'},
9916 'ErrorInfo': {'additionalProperties': False,
9917 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
9918 'MacaroonPath': {'type': 'string'}},
9919 'type': 'object'},
9920 'Macaroon': {'additionalProperties': False,
9921 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
9922 'type': 'array'},
9923 'data': {'items': {'type': 'integer'},
9924 'type': 'array'},
9925 'id': {'$ref': '#/definitions/packet'},
9926 'location': {'$ref': '#/definitions/packet'},
9927 'sig': {'items': {'type': 'integer'},
9928 'type': 'array'}},
9929 'required': ['data',
9930 'location',
9931 'id',
9932 'caveats',
9933 'sig'],
9934 'type': 'object'},
9935 'MachineStorageId': {'additionalProperties': False,
9936 'properties': {'attachmenttag': {'type': 'string'},
9937 'machinetag': {'type': 'string'}},
9938 'required': ['machinetag',
9939 'attachmenttag'],
9940 'type': 'object'},
9941 'MachineStorageIdsWatchResult': {'additionalProperties': False,
9942 'properties': {'Changes': {'items': {'$ref': '#/definitions/MachineStorageId'},
9943 'type': 'array'},
9944 'Error': {'$ref': '#/definitions/Error'},
9945 'MachineStorageIdsWatcherId': {'type': 'string'}},
9946 'required': ['MachineStorageIdsWatcherId',
9947 'Changes',
9948 'Error'],
9949 'type': 'object'},
9950 'caveat': {'additionalProperties': False,
9951 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
9952 'location': {'$ref': '#/definitions/packet'},
9953 'verificationId': {'$ref': '#/definitions/packet'}},
9954 'required': ['location',
9955 'caveatId',
9956 'verificationId'],
9957 'type': 'object'},
9958 'packet': {'additionalProperties': False,
9959 'properties': {'headerLen': {'type': 'integer'},
9960 'start': {'type': 'integer'},
9961 'totalLen': {'type': 'integer'}},
9962 'required': ['start', 'totalLen', 'headerLen'],
9963 'type': 'object'}},
9964 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/MachineStorageIdsWatchResult'}},
9965 'type': 'object'},
9966 'Stop': {'type': 'object'}},
9967 'type': 'object'}
9968
9969
9970 @ReturnMapping(MachineStorageIdsWatchResult)
9971 async def Next(self):
9972 '''
9973
9974 Returns -> typing.Union[typing.Sequence[~MachineStorageId], _ForwardRef('Error')]
9975 '''
9976 # map input types to rpc msg
9977 params = dict()
9978 msg = dict(Type='FilesystemAttachmentsWatcher', Request='Next', Version=2, Params=params)
9979
9980 reply = await self.rpc(msg)
9981 return reply
9982
9983
9984
9985 @ReturnMapping(None)
9986 async def Stop(self):
9987 '''
9988
9989 Returns -> None
9990 '''
9991 # map input types to rpc msg
9992 params = dict()
9993 msg = dict(Type='FilesystemAttachmentsWatcher', Request='Stop', Version=2, Params=params)
9994
9995 reply = await self.rpc(msg)
9996 return reply
9997
9998
9999 class FirewallerFacade(Type):
10000 name = 'Firewaller'
10001 version = 3
10002 schema = {'definitions': {'BoolResult': {'additionalProperties': False,
10003 'properties': {'Error': {'$ref': '#/definitions/Error'},
10004 'Result': {'type': 'boolean'}},
10005 'required': ['Error', 'Result'],
10006 'type': 'object'},
10007 'BoolResults': {'additionalProperties': False,
10008 'properties': {'Results': {'items': {'$ref': '#/definitions/BoolResult'},
10009 'type': 'array'}},
10010 'required': ['Results'],
10011 'type': 'object'},
10012 'Entities': {'additionalProperties': False,
10013 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
10014 'type': 'array'}},
10015 'required': ['Entities'],
10016 'type': 'object'},
10017 'Entity': {'additionalProperties': False,
10018 'properties': {'Tag': {'type': 'string'}},
10019 'required': ['Tag'],
10020 'type': 'object'},
10021 'Error': {'additionalProperties': False,
10022 'properties': {'Code': {'type': 'string'},
10023 'Info': {'$ref': '#/definitions/ErrorInfo'},
10024 'Message': {'type': 'string'}},
10025 'required': ['Message', 'Code'],
10026 'type': 'object'},
10027 'ErrorInfo': {'additionalProperties': False,
10028 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
10029 'MacaroonPath': {'type': 'string'}},
10030 'type': 'object'},
10031 'LifeResult': {'additionalProperties': False,
10032 'properties': {'Error': {'$ref': '#/definitions/Error'},
10033 'Life': {'type': 'string'}},
10034 'required': ['Life', 'Error'],
10035 'type': 'object'},
10036 'LifeResults': {'additionalProperties': False,
10037 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
10038 'type': 'array'}},
10039 'required': ['Results'],
10040 'type': 'object'},
10041 'Macaroon': {'additionalProperties': False,
10042 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
10043 'type': 'array'},
10044 'data': {'items': {'type': 'integer'},
10045 'type': 'array'},
10046 'id': {'$ref': '#/definitions/packet'},
10047 'location': {'$ref': '#/definitions/packet'},
10048 'sig': {'items': {'type': 'integer'},
10049 'type': 'array'}},
10050 'required': ['data',
10051 'location',
10052 'id',
10053 'caveats',
10054 'sig'],
10055 'type': 'object'},
10056 'MachinePortRange': {'additionalProperties': False,
10057 'properties': {'PortRange': {'$ref': '#/definitions/PortRange'},
10058 'RelationTag': {'type': 'string'},
10059 'UnitTag': {'type': 'string'}},
10060 'required': ['UnitTag',
10061 'RelationTag',
10062 'PortRange'],
10063 'type': 'object'},
10064 'MachinePorts': {'additionalProperties': False,
10065 'properties': {'MachineTag': {'type': 'string'},
10066 'SubnetTag': {'type': 'string'}},
10067 'required': ['MachineTag', 'SubnetTag'],
10068 'type': 'object'},
10069 'MachinePortsParams': {'additionalProperties': False,
10070 'properties': {'Params': {'items': {'$ref': '#/definitions/MachinePorts'},
10071 'type': 'array'}},
10072 'required': ['Params'],
10073 'type': 'object'},
10074 'MachinePortsResult': {'additionalProperties': False,
10075 'properties': {'Error': {'$ref': '#/definitions/Error'},
10076 'Ports': {'items': {'$ref': '#/definitions/MachinePortRange'},
10077 'type': 'array'}},
10078 'required': ['Error', 'Ports'],
10079 'type': 'object'},
10080 'MachinePortsResults': {'additionalProperties': False,
10081 'properties': {'Results': {'items': {'$ref': '#/definitions/MachinePortsResult'},
10082 'type': 'array'}},
10083 'required': ['Results'],
10084 'type': 'object'},
10085 'ModelConfigResult': {'additionalProperties': False,
10086 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
10087 'type': 'object'}},
10088 'type': 'object'}},
10089 'required': ['Config'],
10090 'type': 'object'},
10091 'NotifyWatchResult': {'additionalProperties': False,
10092 'properties': {'Error': {'$ref': '#/definitions/Error'},
10093 'NotifyWatcherId': {'type': 'string'}},
10094 'required': ['NotifyWatcherId', 'Error'],
10095 'type': 'object'},
10096 'NotifyWatchResults': {'additionalProperties': False,
10097 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
10098 'type': 'array'}},
10099 'required': ['Results'],
10100 'type': 'object'},
10101 'PortRange': {'additionalProperties': False,
10102 'properties': {'FromPort': {'type': 'integer'},
10103 'Protocol': {'type': 'string'},
10104 'ToPort': {'type': 'integer'}},
10105 'required': ['FromPort', 'ToPort', 'Protocol'],
10106 'type': 'object'},
10107 'StringResult': {'additionalProperties': False,
10108 'properties': {'Error': {'$ref': '#/definitions/Error'},
10109 'Result': {'type': 'string'}},
10110 'required': ['Error', 'Result'],
10111 'type': 'object'},
10112 'StringResults': {'additionalProperties': False,
10113 'properties': {'Results': {'items': {'$ref': '#/definitions/StringResult'},
10114 'type': 'array'}},
10115 'required': ['Results'],
10116 'type': 'object'},
10117 'StringsResult': {'additionalProperties': False,
10118 'properties': {'Error': {'$ref': '#/definitions/Error'},
10119 'Result': {'items': {'type': 'string'},
10120 'type': 'array'}},
10121 'required': ['Error', 'Result'],
10122 'type': 'object'},
10123 'StringsResults': {'additionalProperties': False,
10124 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsResult'},
10125 'type': 'array'}},
10126 'required': ['Results'],
10127 'type': 'object'},
10128 'StringsWatchResult': {'additionalProperties': False,
10129 'properties': {'Changes': {'items': {'type': 'string'},
10130 'type': 'array'},
10131 'Error': {'$ref': '#/definitions/Error'},
10132 'StringsWatcherId': {'type': 'string'}},
10133 'required': ['StringsWatcherId',
10134 'Changes',
10135 'Error'],
10136 'type': 'object'},
10137 'StringsWatchResults': {'additionalProperties': False,
10138 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsWatchResult'},
10139 'type': 'array'}},
10140 'required': ['Results'],
10141 'type': 'object'},
10142 'caveat': {'additionalProperties': False,
10143 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
10144 'location': {'$ref': '#/definitions/packet'},
10145 'verificationId': {'$ref': '#/definitions/packet'}},
10146 'required': ['location',
10147 'caveatId',
10148 'verificationId'],
10149 'type': 'object'},
10150 'packet': {'additionalProperties': False,
10151 'properties': {'headerLen': {'type': 'integer'},
10152 'start': {'type': 'integer'},
10153 'totalLen': {'type': 'integer'}},
10154 'required': ['start', 'totalLen', 'headerLen'],
10155 'type': 'object'}},
10156 'properties': {'GetAssignedMachine': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10157 'Result': {'$ref': '#/definitions/StringResults'}},
10158 'type': 'object'},
10159 'GetExposed': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10160 'Result': {'$ref': '#/definitions/BoolResults'}},
10161 'type': 'object'},
10162 'GetMachineActiveSubnets': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10163 'Result': {'$ref': '#/definitions/StringsResults'}},
10164 'type': 'object'},
10165 'GetMachinePorts': {'properties': {'Params': {'$ref': '#/definitions/MachinePortsParams'},
10166 'Result': {'$ref': '#/definitions/MachinePortsResults'}},
10167 'type': 'object'},
10168 'InstanceId': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10169 'Result': {'$ref': '#/definitions/StringResults'}},
10170 'type': 'object'},
10171 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10172 'Result': {'$ref': '#/definitions/LifeResults'}},
10173 'type': 'object'},
10174 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
10175 'type': 'object'},
10176 'Watch': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10177 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
10178 'type': 'object'},
10179 'WatchForModelConfigChanges': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
10180 'type': 'object'},
10181 'WatchModelMachines': {'properties': {'Result': {'$ref': '#/definitions/StringsWatchResult'}},
10182 'type': 'object'},
10183 'WatchOpenedPorts': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10184 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
10185 'type': 'object'},
10186 'WatchUnits': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
10187 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
10188 'type': 'object'}},
10189 'type': 'object'}
10190
10191
10192 @ReturnMapping(StringResults)
10193 async def GetAssignedMachine(self, entities):
10194 '''
10195 entities : typing.Sequence[~Entity]
10196 Returns -> typing.Sequence[~StringResult]
10197 '''
10198 # map input types to rpc msg
10199 params = dict()
10200 msg = dict(Type='Firewaller', Request='GetAssignedMachine', Version=3, Params=params)
10201 params['Entities'] = entities
10202 reply = await self.rpc(msg)
10203 return reply
10204
10205
10206
10207 @ReturnMapping(BoolResults)
10208 async def GetExposed(self, entities):
10209 '''
10210 entities : typing.Sequence[~Entity]
10211 Returns -> typing.Sequence[~BoolResult]
10212 '''
10213 # map input types to rpc msg
10214 params = dict()
10215 msg = dict(Type='Firewaller', Request='GetExposed', Version=3, Params=params)
10216 params['Entities'] = entities
10217 reply = await self.rpc(msg)
10218 return reply
10219
10220
10221
10222 @ReturnMapping(StringsResults)
10223 async def GetMachineActiveSubnets(self, entities):
10224 '''
10225 entities : typing.Sequence[~Entity]
10226 Returns -> typing.Sequence[~StringsResult]
10227 '''
10228 # map input types to rpc msg
10229 params = dict()
10230 msg = dict(Type='Firewaller', Request='GetMachineActiveSubnets', Version=3, Params=params)
10231 params['Entities'] = entities
10232 reply = await self.rpc(msg)
10233 return reply
10234
10235
10236
10237 @ReturnMapping(MachinePortsResults)
10238 async def GetMachinePorts(self, params):
10239 '''
10240 params : typing.Sequence[~MachinePorts]
10241 Returns -> typing.Sequence[~MachinePortsResult]
10242 '''
10243 # map input types to rpc msg
10244 params = dict()
10245 msg = dict(Type='Firewaller', Request='GetMachinePorts', Version=3, Params=params)
10246 params['Params'] = params
10247 reply = await self.rpc(msg)
10248 return reply
10249
10250
10251
10252 @ReturnMapping(StringResults)
10253 async def InstanceId(self, entities):
10254 '''
10255 entities : typing.Sequence[~Entity]
10256 Returns -> typing.Sequence[~StringResult]
10257 '''
10258 # map input types to rpc msg
10259 params = dict()
10260 msg = dict(Type='Firewaller', Request='InstanceId', Version=3, Params=params)
10261 params['Entities'] = entities
10262 reply = await self.rpc(msg)
10263 return reply
10264
10265
10266
10267 @ReturnMapping(LifeResults)
10268 async def Life(self, entities):
10269 '''
10270 entities : typing.Sequence[~Entity]
10271 Returns -> typing.Sequence[~LifeResult]
10272 '''
10273 # map input types to rpc msg
10274 params = dict()
10275 msg = dict(Type='Firewaller', Request='Life', Version=3, Params=params)
10276 params['Entities'] = entities
10277 reply = await self.rpc(msg)
10278 return reply
10279
10280
10281
10282 @ReturnMapping(ModelConfigResult)
10283 async def ModelConfig(self):
10284 '''
10285
10286 Returns -> typing.Mapping[str, typing.Any]
10287 '''
10288 # map input types to rpc msg
10289 params = dict()
10290 msg = dict(Type='Firewaller', Request='ModelConfig', Version=3, Params=params)
10291
10292 reply = await self.rpc(msg)
10293 return reply
10294
10295
10296
10297 @ReturnMapping(NotifyWatchResults)
10298 async def Watch(self, entities):
10299 '''
10300 entities : typing.Sequence[~Entity]
10301 Returns -> typing.Sequence[~NotifyWatchResult]
10302 '''
10303 # map input types to rpc msg
10304 params = dict()
10305 msg = dict(Type='Firewaller', Request='Watch', Version=3, Params=params)
10306 params['Entities'] = entities
10307 reply = await self.rpc(msg)
10308 return reply
10309
10310
10311
10312 @ReturnMapping(NotifyWatchResult)
10313 async def WatchForModelConfigChanges(self):
10314 '''
10315
10316 Returns -> typing.Union[_ForwardRef('Error'), str]
10317 '''
10318 # map input types to rpc msg
10319 params = dict()
10320 msg = dict(Type='Firewaller', Request='WatchForModelConfigChanges', Version=3, Params=params)
10321
10322 reply = await self.rpc(msg)
10323 return reply
10324
10325
10326
10327 @ReturnMapping(StringsWatchResult)
10328 async def WatchModelMachines(self):
10329 '''
10330
10331 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
10332 '''
10333 # map input types to rpc msg
10334 params = dict()
10335 msg = dict(Type='Firewaller', Request='WatchModelMachines', Version=3, Params=params)
10336
10337 reply = await self.rpc(msg)
10338 return reply
10339
10340
10341
10342 @ReturnMapping(StringsWatchResults)
10343 async def WatchOpenedPorts(self, entities):
10344 '''
10345 entities : typing.Sequence[~Entity]
10346 Returns -> typing.Sequence[~StringsWatchResult]
10347 '''
10348 # map input types to rpc msg
10349 params = dict()
10350 msg = dict(Type='Firewaller', Request='WatchOpenedPorts', Version=3, Params=params)
10351 params['Entities'] = entities
10352 reply = await self.rpc(msg)
10353 return reply
10354
10355
10356
10357 @ReturnMapping(StringsWatchResults)
10358 async def WatchUnits(self, entities):
10359 '''
10360 entities : typing.Sequence[~Entity]
10361 Returns -> typing.Sequence[~StringsWatchResult]
10362 '''
10363 # map input types to rpc msg
10364 params = dict()
10365 msg = dict(Type='Firewaller', Request='WatchUnits', Version=3, Params=params)
10366 params['Entities'] = entities
10367 reply = await self.rpc(msg)
10368 return reply
10369
10370
10371 class HighAvailabilityFacade(Type):
10372 name = 'HighAvailability'
10373 version = 2
10374 schema = {'definitions': {'Address': {'additionalProperties': False,
10375 'properties': {'Scope': {'type': 'string'},
10376 'SpaceName': {'type': 'string'},
10377 'SpaceProviderId': {'type': 'string'},
10378 'Type': {'type': 'string'},
10379 'Value': {'type': 'string'}},
10380 'required': ['Value',
10381 'Type',
10382 'Scope',
10383 'SpaceName',
10384 'SpaceProviderId'],
10385 'type': 'object'},
10386 'ControllersChangeResult': {'additionalProperties': False,
10387 'properties': {'Error': {'$ref': '#/definitions/Error'},
10388 'Result': {'$ref': '#/definitions/ControllersChanges'}},
10389 'required': ['Result', 'Error'],
10390 'type': 'object'},
10391 'ControllersChangeResults': {'additionalProperties': False,
10392 'properties': {'Results': {'items': {'$ref': '#/definitions/ControllersChangeResult'},
10393 'type': 'array'}},
10394 'required': ['Results'],
10395 'type': 'object'},
10396 'ControllersChanges': {'additionalProperties': False,
10397 'properties': {'added': {'items': {'type': 'string'},
10398 'type': 'array'},
10399 'converted': {'items': {'type': 'string'},
10400 'type': 'array'},
10401 'demoted': {'items': {'type': 'string'},
10402 'type': 'array'},
10403 'maintained': {'items': {'type': 'string'},
10404 'type': 'array'},
10405 'promoted': {'items': {'type': 'string'},
10406 'type': 'array'},
10407 'removed': {'items': {'type': 'string'},
10408 'type': 'array'}},
10409 'type': 'object'},
10410 'ControllersSpec': {'additionalProperties': False,
10411 'properties': {'ModelTag': {'type': 'string'},
10412 'constraints': {'$ref': '#/definitions/Value'},
10413 'num-controllers': {'type': 'integer'},
10414 'placement': {'items': {'type': 'string'},
10415 'type': 'array'},
10416 'series': {'type': 'string'}},
10417 'required': ['ModelTag',
10418 'num-controllers'],
10419 'type': 'object'},
10420 'ControllersSpecs': {'additionalProperties': False,
10421 'properties': {'Specs': {'items': {'$ref': '#/definitions/ControllersSpec'},
10422 'type': 'array'}},
10423 'required': ['Specs'],
10424 'type': 'object'},
10425 'Error': {'additionalProperties': False,
10426 'properties': {'Code': {'type': 'string'},
10427 'Info': {'$ref': '#/definitions/ErrorInfo'},
10428 'Message': {'type': 'string'}},
10429 'required': ['Message', 'Code'],
10430 'type': 'object'},
10431 'ErrorInfo': {'additionalProperties': False,
10432 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
10433 'MacaroonPath': {'type': 'string'}},
10434 'type': 'object'},
10435 'HAMember': {'additionalProperties': False,
10436 'properties': {'PublicAddress': {'$ref': '#/definitions/Address'},
10437 'Series': {'type': 'string'},
10438 'Tag': {'type': 'string'}},
10439 'required': ['Tag', 'PublicAddress', 'Series'],
10440 'type': 'object'},
10441 'Macaroon': {'additionalProperties': False,
10442 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
10443 'type': 'array'},
10444 'data': {'items': {'type': 'integer'},
10445 'type': 'array'},
10446 'id': {'$ref': '#/definitions/packet'},
10447 'location': {'$ref': '#/definitions/packet'},
10448 'sig': {'items': {'type': 'integer'},
10449 'type': 'array'}},
10450 'required': ['data',
10451 'location',
10452 'id',
10453 'caveats',
10454 'sig'],
10455 'type': 'object'},
10456 'Member': {'additionalProperties': False,
10457 'properties': {'Address': {'type': 'string'},
10458 'Arbiter': {'type': 'boolean'},
10459 'BuildIndexes': {'type': 'boolean'},
10460 'Hidden': {'type': 'boolean'},
10461 'Id': {'type': 'integer'},
10462 'Priority': {'type': 'number'},
10463 'SlaveDelay': {'type': 'integer'},
10464 'Tags': {'patternProperties': {'.*': {'type': 'string'}},
10465 'type': 'object'},
10466 'Votes': {'type': 'integer'}},
10467 'required': ['Id',
10468 'Address',
10469 'Arbiter',
10470 'BuildIndexes',
10471 'Hidden',
10472 'Priority',
10473 'Tags',
10474 'SlaveDelay',
10475 'Votes'],
10476 'type': 'object'},
10477 'MongoUpgradeResults': {'additionalProperties': False,
10478 'properties': {'Master': {'$ref': '#/definitions/HAMember'},
10479 'Members': {'items': {'$ref': '#/definitions/HAMember'},
10480 'type': 'array'},
10481 'RsMembers': {'items': {'$ref': '#/definitions/Member'},
10482 'type': 'array'}},
10483 'required': ['RsMembers',
10484 'Master',
10485 'Members'],
10486 'type': 'object'},
10487 'ResumeReplicationParams': {'additionalProperties': False,
10488 'properties': {'Members': {'items': {'$ref': '#/definitions/Member'},
10489 'type': 'array'}},
10490 'required': ['Members'],
10491 'type': 'object'},
10492 'UpgradeMongoParams': {'additionalProperties': False,
10493 'properties': {'Target': {'$ref': '#/definitions/Version'}},
10494 'required': ['Target'],
10495 'type': 'object'},
10496 'Value': {'additionalProperties': False,
10497 'properties': {'arch': {'type': 'string'},
10498 'container': {'type': 'string'},
10499 'cpu-cores': {'type': 'integer'},
10500 'cpu-power': {'type': 'integer'},
10501 'instance-type': {'type': 'string'},
10502 'mem': {'type': 'integer'},
10503 'root-disk': {'type': 'integer'},
10504 'spaces': {'items': {'type': 'string'},
10505 'type': 'array'},
10506 'tags': {'items': {'type': 'string'},
10507 'type': 'array'},
10508 'virt-type': {'type': 'string'}},
10509 'type': 'object'},
10510 'Version': {'additionalProperties': False,
10511 'properties': {'Major': {'type': 'integer'},
10512 'Minor': {'type': 'integer'},
10513 'Patch': {'type': 'string'},
10514 'StorageEngine': {'type': 'string'}},
10515 'required': ['Major',
10516 'Minor',
10517 'Patch',
10518 'StorageEngine'],
10519 'type': 'object'},
10520 'caveat': {'additionalProperties': False,
10521 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
10522 'location': {'$ref': '#/definitions/packet'},
10523 'verificationId': {'$ref': '#/definitions/packet'}},
10524 'required': ['location',
10525 'caveatId',
10526 'verificationId'],
10527 'type': 'object'},
10528 'packet': {'additionalProperties': False,
10529 'properties': {'headerLen': {'type': 'integer'},
10530 'start': {'type': 'integer'},
10531 'totalLen': {'type': 'integer'}},
10532 'required': ['start', 'totalLen', 'headerLen'],
10533 'type': 'object'}},
10534 'properties': {'EnableHA': {'properties': {'Params': {'$ref': '#/definitions/ControllersSpecs'},
10535 'Result': {'$ref': '#/definitions/ControllersChangeResults'}},
10536 'type': 'object'},
10537 'ResumeHAReplicationAfterUpgrade': {'properties': {'Params': {'$ref': '#/definitions/ResumeReplicationParams'}},
10538 'type': 'object'},
10539 'StopHAReplicationForUpgrade': {'properties': {'Params': {'$ref': '#/definitions/UpgradeMongoParams'},
10540 'Result': {'$ref': '#/definitions/MongoUpgradeResults'}},
10541 'type': 'object'}},
10542 'type': 'object'}
10543
10544
10545 @ReturnMapping(ControllersChangeResults)
10546 async def EnableHA(self, specs):
10547 '''
10548 specs : typing.Sequence[~ControllersSpec]
10549 Returns -> typing.Sequence[~ControllersChangeResult]
10550 '''
10551 # map input types to rpc msg
10552 params = dict()
10553 msg = dict(Type='HighAvailability', Request='EnableHA', Version=2, Params=params)
10554 params['Specs'] = specs
10555 reply = await self.rpc(msg)
10556 return reply
10557
10558
10559
10560 @ReturnMapping(None)
10561 async def ResumeHAReplicationAfterUpgrade(self, members):
10562 '''
10563 members : typing.Sequence[~Member]
10564 Returns -> None
10565 '''
10566 # map input types to rpc msg
10567 params = dict()
10568 msg = dict(Type='HighAvailability', Request='ResumeHAReplicationAfterUpgrade', Version=2, Params=params)
10569 params['Members'] = members
10570 reply = await self.rpc(msg)
10571 return reply
10572
10573
10574
10575 @ReturnMapping(MongoUpgradeResults)
10576 async def StopHAReplicationForUpgrade(self, major, minor, patch, storageengine):
10577 '''
10578 major : int
10579 minor : int
10580 patch : str
10581 storageengine : str
10582 Returns -> typing.Union[_ForwardRef('HAMember'), typing.Sequence[~Member]]
10583 '''
10584 # map input types to rpc msg
10585 params = dict()
10586 msg = dict(Type='HighAvailability', Request='StopHAReplicationForUpgrade', Version=2, Params=params)
10587 params['Major'] = major
10588 params['Minor'] = minor
10589 params['Patch'] = patch
10590 params['StorageEngine'] = storageengine
10591 reply = await self.rpc(msg)
10592 return reply
10593
10594
10595 class HostKeyReporterFacade(Type):
10596 name = 'HostKeyReporter'
10597 version = 1
10598 schema = {'definitions': {'Error': {'additionalProperties': False,
10599 'properties': {'Code': {'type': 'string'},
10600 'Info': {'$ref': '#/definitions/ErrorInfo'},
10601 'Message': {'type': 'string'}},
10602 'required': ['Message', 'Code'],
10603 'type': 'object'},
10604 'ErrorInfo': {'additionalProperties': False,
10605 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
10606 'MacaroonPath': {'type': 'string'}},
10607 'type': 'object'},
10608 'ErrorResult': {'additionalProperties': False,
10609 'properties': {'Error': {'$ref': '#/definitions/Error'}},
10610 'required': ['Error'],
10611 'type': 'object'},
10612 'ErrorResults': {'additionalProperties': False,
10613 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
10614 'type': 'array'}},
10615 'required': ['Results'],
10616 'type': 'object'},
10617 'Macaroon': {'additionalProperties': False,
10618 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
10619 'type': 'array'},
10620 'data': {'items': {'type': 'integer'},
10621 'type': 'array'},
10622 'id': {'$ref': '#/definitions/packet'},
10623 'location': {'$ref': '#/definitions/packet'},
10624 'sig': {'items': {'type': 'integer'},
10625 'type': 'array'}},
10626 'required': ['data',
10627 'location',
10628 'id',
10629 'caveats',
10630 'sig'],
10631 'type': 'object'},
10632 'SSHHostKeySet': {'additionalProperties': False,
10633 'properties': {'entity-keys': {'items': {'$ref': '#/definitions/SSHHostKeys'},
10634 'type': 'array'}},
10635 'required': ['entity-keys'],
10636 'type': 'object'},
10637 'SSHHostKeys': {'additionalProperties': False,
10638 'properties': {'public-keys': {'items': {'type': 'string'},
10639 'type': 'array'},
10640 'tag': {'type': 'string'}},
10641 'required': ['tag', 'public-keys'],
10642 'type': 'object'},
10643 'caveat': {'additionalProperties': False,
10644 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
10645 'location': {'$ref': '#/definitions/packet'},
10646 'verificationId': {'$ref': '#/definitions/packet'}},
10647 'required': ['location',
10648 'caveatId',
10649 'verificationId'],
10650 'type': 'object'},
10651 'packet': {'additionalProperties': False,
10652 'properties': {'headerLen': {'type': 'integer'},
10653 'start': {'type': 'integer'},
10654 'totalLen': {'type': 'integer'}},
10655 'required': ['start', 'totalLen', 'headerLen'],
10656 'type': 'object'}},
10657 'properties': {'ReportKeys': {'properties': {'Params': {'$ref': '#/definitions/SSHHostKeySet'},
10658 'Result': {'$ref': '#/definitions/ErrorResults'}},
10659 'type': 'object'}},
10660 'type': 'object'}
10661
10662
10663 @ReturnMapping(ErrorResults)
10664 async def ReportKeys(self, entity_keys):
10665 '''
10666 entity_keys : typing.Sequence[~SSHHostKeys]
10667 Returns -> typing.Sequence[~ErrorResult]
10668 '''
10669 # map input types to rpc msg
10670 params = dict()
10671 msg = dict(Type='HostKeyReporter', Request='ReportKeys', Version=1, Params=params)
10672 params['entity-keys'] = entity_keys
10673 reply = await self.rpc(msg)
10674 return reply
10675
10676
10677 class ImageManagerFacade(Type):
10678 name = 'ImageManager'
10679 version = 2
10680 schema = {'definitions': {'Error': {'additionalProperties': False,
10681 'properties': {'Code': {'type': 'string'},
10682 'Info': {'$ref': '#/definitions/ErrorInfo'},
10683 'Message': {'type': 'string'}},
10684 'required': ['Message', 'Code'],
10685 'type': 'object'},
10686 'ErrorInfo': {'additionalProperties': False,
10687 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
10688 'MacaroonPath': {'type': 'string'}},
10689 'type': 'object'},
10690 'ErrorResult': {'additionalProperties': False,
10691 'properties': {'Error': {'$ref': '#/definitions/Error'}},
10692 'required': ['Error'],
10693 'type': 'object'},
10694 'ErrorResults': {'additionalProperties': False,
10695 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
10696 'type': 'array'}},
10697 'required': ['Results'],
10698 'type': 'object'},
10699 'ImageFilterParams': {'additionalProperties': False,
10700 'properties': {'images': {'items': {'$ref': '#/definitions/ImageSpec'},
10701 'type': 'array'}},
10702 'required': ['images'],
10703 'type': 'object'},
10704 'ImageMetadata': {'additionalProperties': False,
10705 'properties': {'arch': {'type': 'string'},
10706 'created': {'format': 'date-time',
10707 'type': 'string'},
10708 'kind': {'type': 'string'},
10709 'series': {'type': 'string'},
10710 'url': {'type': 'string'}},
10711 'required': ['kind',
10712 'arch',
10713 'series',
10714 'url',
10715 'created'],
10716 'type': 'object'},
10717 'ImageSpec': {'additionalProperties': False,
10718 'properties': {'arch': {'type': 'string'},
10719 'kind': {'type': 'string'},
10720 'series': {'type': 'string'}},
10721 'required': ['kind', 'arch', 'series'],
10722 'type': 'object'},
10723 'ListImageResult': {'additionalProperties': False,
10724 'properties': {'result': {'items': {'$ref': '#/definitions/ImageMetadata'},
10725 'type': 'array'}},
10726 'required': ['result'],
10727 'type': 'object'},
10728 'Macaroon': {'additionalProperties': False,
10729 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
10730 'type': 'array'},
10731 'data': {'items': {'type': 'integer'},
10732 'type': 'array'},
10733 'id': {'$ref': '#/definitions/packet'},
10734 'location': {'$ref': '#/definitions/packet'},
10735 'sig': {'items': {'type': 'integer'},
10736 'type': 'array'}},
10737 'required': ['data',
10738 'location',
10739 'id',
10740 'caveats',
10741 'sig'],
10742 'type': 'object'},
10743 'caveat': {'additionalProperties': False,
10744 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
10745 'location': {'$ref': '#/definitions/packet'},
10746 'verificationId': {'$ref': '#/definitions/packet'}},
10747 'required': ['location',
10748 'caveatId',
10749 'verificationId'],
10750 'type': 'object'},
10751 'packet': {'additionalProperties': False,
10752 'properties': {'headerLen': {'type': 'integer'},
10753 'start': {'type': 'integer'},
10754 'totalLen': {'type': 'integer'}},
10755 'required': ['start', 'totalLen', 'headerLen'],
10756 'type': 'object'}},
10757 'properties': {'DeleteImages': {'properties': {'Params': {'$ref': '#/definitions/ImageFilterParams'},
10758 'Result': {'$ref': '#/definitions/ErrorResults'}},
10759 'type': 'object'},
10760 'ListImages': {'properties': {'Params': {'$ref': '#/definitions/ImageFilterParams'},
10761 'Result': {'$ref': '#/definitions/ListImageResult'}},
10762 'type': 'object'}},
10763 'type': 'object'}
10764
10765
10766 @ReturnMapping(ErrorResults)
10767 async def DeleteImages(self, images):
10768 '''
10769 images : typing.Sequence[~ImageSpec]
10770 Returns -> typing.Sequence[~ErrorResult]
10771 '''
10772 # map input types to rpc msg
10773 params = dict()
10774 msg = dict(Type='ImageManager', Request='DeleteImages', Version=2, Params=params)
10775 params['images'] = images
10776 reply = await self.rpc(msg)
10777 return reply
10778
10779
10780
10781 @ReturnMapping(ListImageResult)
10782 async def ListImages(self, images):
10783 '''
10784 images : typing.Sequence[~ImageSpec]
10785 Returns -> typing.Sequence[~ImageMetadata]
10786 '''
10787 # map input types to rpc msg
10788 params = dict()
10789 msg = dict(Type='ImageManager', Request='ListImages', Version=2, Params=params)
10790 params['images'] = images
10791 reply = await self.rpc(msg)
10792 return reply
10793
10794
10795 class ImageMetadataFacade(Type):
10796 name = 'ImageMetadata'
10797 version = 2
10798 schema = {'definitions': {'CloudImageMetadata': {'additionalProperties': False,
10799 'properties': {'arch': {'type': 'string'},
10800 'image_id': {'type': 'string'},
10801 'priority': {'type': 'integer'},
10802 'region': {'type': 'string'},
10803 'root_storage_size': {'type': 'integer'},
10804 'root_storage_type': {'type': 'string'},
10805 'series': {'type': 'string'},
10806 'source': {'type': 'string'},
10807 'stream': {'type': 'string'},
10808 'version': {'type': 'string'},
10809 'virt_type': {'type': 'string'}},
10810 'required': ['image_id',
10811 'region',
10812 'version',
10813 'series',
10814 'arch',
10815 'source',
10816 'priority'],
10817 'type': 'object'},
10818 'CloudImageMetadataList': {'additionalProperties': False,
10819 'properties': {'metadata': {'items': {'$ref': '#/definitions/CloudImageMetadata'},
10820 'type': 'array'}},
10821 'type': 'object'},
10822 'Error': {'additionalProperties': False,
10823 'properties': {'Code': {'type': 'string'},
10824 'Info': {'$ref': '#/definitions/ErrorInfo'},
10825 'Message': {'type': 'string'}},
10826 'required': ['Message', 'Code'],
10827 'type': 'object'},
10828 'ErrorInfo': {'additionalProperties': False,
10829 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
10830 'MacaroonPath': {'type': 'string'}},
10831 'type': 'object'},
10832 'ErrorResult': {'additionalProperties': False,
10833 'properties': {'Error': {'$ref': '#/definitions/Error'}},
10834 'required': ['Error'],
10835 'type': 'object'},
10836 'ErrorResults': {'additionalProperties': False,
10837 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
10838 'type': 'array'}},
10839 'required': ['Results'],
10840 'type': 'object'},
10841 'ImageMetadataFilter': {'additionalProperties': False,
10842 'properties': {'arches': {'items': {'type': 'string'},
10843 'type': 'array'},
10844 'region': {'type': 'string'},
10845 'root-storage-type': {'type': 'string'},
10846 'series': {'items': {'type': 'string'},
10847 'type': 'array'},
10848 'stream': {'type': 'string'},
10849 'virt_type': {'type': 'string'}},
10850 'type': 'object'},
10851 'ListCloudImageMetadataResult': {'additionalProperties': False,
10852 'properties': {'result': {'items': {'$ref': '#/definitions/CloudImageMetadata'},
10853 'type': 'array'}},
10854 'required': ['result'],
10855 'type': 'object'},
10856 'Macaroon': {'additionalProperties': False,
10857 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
10858 'type': 'array'},
10859 'data': {'items': {'type': 'integer'},
10860 'type': 'array'},
10861 'id': {'$ref': '#/definitions/packet'},
10862 'location': {'$ref': '#/definitions/packet'},
10863 'sig': {'items': {'type': 'integer'},
10864 'type': 'array'}},
10865 'required': ['data',
10866 'location',
10867 'id',
10868 'caveats',
10869 'sig'],
10870 'type': 'object'},
10871 'MetadataImageIds': {'additionalProperties': False,
10872 'properties': {'image_ids': {'items': {'type': 'string'},
10873 'type': 'array'}},
10874 'required': ['image_ids'],
10875 'type': 'object'},
10876 'MetadataSaveParams': {'additionalProperties': False,
10877 'properties': {'metadata': {'items': {'$ref': '#/definitions/CloudImageMetadataList'},
10878 'type': 'array'}},
10879 'type': 'object'},
10880 'caveat': {'additionalProperties': False,
10881 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
10882 'location': {'$ref': '#/definitions/packet'},
10883 'verificationId': {'$ref': '#/definitions/packet'}},
10884 'required': ['location',
10885 'caveatId',
10886 'verificationId'],
10887 'type': 'object'},
10888 'packet': {'additionalProperties': False,
10889 'properties': {'headerLen': {'type': 'integer'},
10890 'start': {'type': 'integer'},
10891 'totalLen': {'type': 'integer'}},
10892 'required': ['start', 'totalLen', 'headerLen'],
10893 'type': 'object'}},
10894 'properties': {'Delete': {'properties': {'Params': {'$ref': '#/definitions/MetadataImageIds'},
10895 'Result': {'$ref': '#/definitions/ErrorResults'}},
10896 'type': 'object'},
10897 'List': {'properties': {'Params': {'$ref': '#/definitions/ImageMetadataFilter'},
10898 'Result': {'$ref': '#/definitions/ListCloudImageMetadataResult'}},
10899 'type': 'object'},
10900 'Save': {'properties': {'Params': {'$ref': '#/definitions/MetadataSaveParams'},
10901 'Result': {'$ref': '#/definitions/ErrorResults'}},
10902 'type': 'object'},
10903 'UpdateFromPublishedImages': {'type': 'object'}},
10904 'type': 'object'}
10905
10906
10907 @ReturnMapping(ErrorResults)
10908 async def Delete(self, image_ids):
10909 '''
10910 image_ids : typing.Sequence[str]
10911 Returns -> typing.Sequence[~ErrorResult]
10912 '''
10913 # map input types to rpc msg
10914 params = dict()
10915 msg = dict(Type='ImageMetadata', Request='Delete', Version=2, Params=params)
10916 params['image_ids'] = image_ids
10917 reply = await self.rpc(msg)
10918 return reply
10919
10920
10921
10922 @ReturnMapping(ListCloudImageMetadataResult)
10923 async def List(self, arches, region, root_storage_type, series, stream, virt_type):
10924 '''
10925 arches : typing.Sequence[str]
10926 region : str
10927 root_storage_type : str
10928 series : typing.Sequence[str]
10929 stream : str
10930 virt_type : str
10931 Returns -> typing.Sequence[~CloudImageMetadata]
10932 '''
10933 # map input types to rpc msg
10934 params = dict()
10935 msg = dict(Type='ImageMetadata', Request='List', Version=2, Params=params)
10936 params['arches'] = arches
10937 params['region'] = region
10938 params['root-storage-type'] = root_storage_type
10939 params['series'] = series
10940 params['stream'] = stream
10941 params['virt_type'] = virt_type
10942 reply = await self.rpc(msg)
10943 return reply
10944
10945
10946
10947 @ReturnMapping(ErrorResults)
10948 async def Save(self, metadata):
10949 '''
10950 metadata : typing.Sequence[~CloudImageMetadataList]
10951 Returns -> typing.Sequence[~ErrorResult]
10952 '''
10953 # map input types to rpc msg
10954 params = dict()
10955 msg = dict(Type='ImageMetadata', Request='Save', Version=2, Params=params)
10956 params['metadata'] = metadata
10957 reply = await self.rpc(msg)
10958 return reply
10959
10960
10961
10962 @ReturnMapping(None)
10963 async def UpdateFromPublishedImages(self):
10964 '''
10965
10966 Returns -> None
10967 '''
10968 # map input types to rpc msg
10969 params = dict()
10970 msg = dict(Type='ImageMetadata', Request='UpdateFromPublishedImages', Version=2, Params=params)
10971
10972 reply = await self.rpc(msg)
10973 return reply
10974
10975
10976 class InstancePollerFacade(Type):
10977 name = 'InstancePoller'
10978 version = 3
10979 schema = {'definitions': {'Address': {'additionalProperties': False,
10980 'properties': {'Scope': {'type': 'string'},
10981 'SpaceName': {'type': 'string'},
10982 'Type': {'type': 'string'},
10983 'Value': {'type': 'string'}},
10984 'required': ['Value', 'Type', 'Scope'],
10985 'type': 'object'},
10986 'BoolResult': {'additionalProperties': False,
10987 'properties': {'Error': {'$ref': '#/definitions/Error'},
10988 'Result': {'type': 'boolean'}},
10989 'required': ['Error', 'Result'],
10990 'type': 'object'},
10991 'BoolResults': {'additionalProperties': False,
10992 'properties': {'Results': {'items': {'$ref': '#/definitions/BoolResult'},
10993 'type': 'array'}},
10994 'required': ['Results'],
10995 'type': 'object'},
10996 'Entities': {'additionalProperties': False,
10997 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
10998 'type': 'array'}},
10999 'required': ['Entities'],
11000 'type': 'object'},
11001 'Entity': {'additionalProperties': False,
11002 'properties': {'Tag': {'type': 'string'}},
11003 'required': ['Tag'],
11004 'type': 'object'},
11005 'EntityStatusArgs': {'additionalProperties': False,
11006 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
11007 'type': 'object'}},
11008 'type': 'object'},
11009 'Info': {'type': 'string'},
11010 'Status': {'type': 'string'},
11011 'Tag': {'type': 'string'}},
11012 'required': ['Tag',
11013 'Status',
11014 'Info',
11015 'Data'],
11016 'type': 'object'},
11017 'Error': {'additionalProperties': False,
11018 'properties': {'Code': {'type': 'string'},
11019 'Info': {'$ref': '#/definitions/ErrorInfo'},
11020 'Message': {'type': 'string'}},
11021 'required': ['Message', 'Code'],
11022 'type': 'object'},
11023 'ErrorInfo': {'additionalProperties': False,
11024 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
11025 'MacaroonPath': {'type': 'string'}},
11026 'type': 'object'},
11027 'ErrorResult': {'additionalProperties': False,
11028 'properties': {'Error': {'$ref': '#/definitions/Error'}},
11029 'required': ['Error'],
11030 'type': 'object'},
11031 'ErrorResults': {'additionalProperties': False,
11032 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
11033 'type': 'array'}},
11034 'required': ['Results'],
11035 'type': 'object'},
11036 'LifeResult': {'additionalProperties': False,
11037 'properties': {'Error': {'$ref': '#/definitions/Error'},
11038 'Life': {'type': 'string'}},
11039 'required': ['Life', 'Error'],
11040 'type': 'object'},
11041 'LifeResults': {'additionalProperties': False,
11042 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
11043 'type': 'array'}},
11044 'required': ['Results'],
11045 'type': 'object'},
11046 'Macaroon': {'additionalProperties': False,
11047 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
11048 'type': 'array'},
11049 'data': {'items': {'type': 'integer'},
11050 'type': 'array'},
11051 'id': {'$ref': '#/definitions/packet'},
11052 'location': {'$ref': '#/definitions/packet'},
11053 'sig': {'items': {'type': 'integer'},
11054 'type': 'array'}},
11055 'required': ['data',
11056 'location',
11057 'id',
11058 'caveats',
11059 'sig'],
11060 'type': 'object'},
11061 'MachineAddresses': {'additionalProperties': False,
11062 'properties': {'Addresses': {'items': {'$ref': '#/definitions/Address'},
11063 'type': 'array'},
11064 'Tag': {'type': 'string'}},
11065 'required': ['Tag', 'Addresses'],
11066 'type': 'object'},
11067 'MachineAddressesResult': {'additionalProperties': False,
11068 'properties': {'Addresses': {'items': {'$ref': '#/definitions/Address'},
11069 'type': 'array'},
11070 'Error': {'$ref': '#/definitions/Error'}},
11071 'required': ['Error', 'Addresses'],
11072 'type': 'object'},
11073 'MachineAddressesResults': {'additionalProperties': False,
11074 'properties': {'Results': {'items': {'$ref': '#/definitions/MachineAddressesResult'},
11075 'type': 'array'}},
11076 'required': ['Results'],
11077 'type': 'object'},
11078 'ModelConfigResult': {'additionalProperties': False,
11079 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
11080 'type': 'object'}},
11081 'type': 'object'}},
11082 'required': ['Config'],
11083 'type': 'object'},
11084 'NotifyWatchResult': {'additionalProperties': False,
11085 'properties': {'Error': {'$ref': '#/definitions/Error'},
11086 'NotifyWatcherId': {'type': 'string'}},
11087 'required': ['NotifyWatcherId', 'Error'],
11088 'type': 'object'},
11089 'SetMachinesAddresses': {'additionalProperties': False,
11090 'properties': {'MachineAddresses': {'items': {'$ref': '#/definitions/MachineAddresses'},
11091 'type': 'array'}},
11092 'required': ['MachineAddresses'],
11093 'type': 'object'},
11094 'SetStatus': {'additionalProperties': False,
11095 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
11096 'type': 'array'}},
11097 'required': ['Entities'],
11098 'type': 'object'},
11099 'StatusResult': {'additionalProperties': False,
11100 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
11101 'type': 'object'}},
11102 'type': 'object'},
11103 'Error': {'$ref': '#/definitions/Error'},
11104 'Id': {'type': 'string'},
11105 'Info': {'type': 'string'},
11106 'Life': {'type': 'string'},
11107 'Since': {'format': 'date-time',
11108 'type': 'string'},
11109 'Status': {'type': 'string'}},
11110 'required': ['Error',
11111 'Id',
11112 'Life',
11113 'Status',
11114 'Info',
11115 'Data',
11116 'Since'],
11117 'type': 'object'},
11118 'StatusResults': {'additionalProperties': False,
11119 'properties': {'Results': {'items': {'$ref': '#/definitions/StatusResult'},
11120 'type': 'array'}},
11121 'required': ['Results'],
11122 'type': 'object'},
11123 'StringResult': {'additionalProperties': False,
11124 'properties': {'Error': {'$ref': '#/definitions/Error'},
11125 'Result': {'type': 'string'}},
11126 'required': ['Error', 'Result'],
11127 'type': 'object'},
11128 'StringResults': {'additionalProperties': False,
11129 'properties': {'Results': {'items': {'$ref': '#/definitions/StringResult'},
11130 'type': 'array'}},
11131 'required': ['Results'],
11132 'type': 'object'},
11133 'StringsWatchResult': {'additionalProperties': False,
11134 'properties': {'Changes': {'items': {'type': 'string'},
11135 'type': 'array'},
11136 'Error': {'$ref': '#/definitions/Error'},
11137 'StringsWatcherId': {'type': 'string'}},
11138 'required': ['StringsWatcherId',
11139 'Changes',
11140 'Error'],
11141 'type': 'object'},
11142 'caveat': {'additionalProperties': False,
11143 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
11144 'location': {'$ref': '#/definitions/packet'},
11145 'verificationId': {'$ref': '#/definitions/packet'}},
11146 'required': ['location',
11147 'caveatId',
11148 'verificationId'],
11149 'type': 'object'},
11150 'packet': {'additionalProperties': False,
11151 'properties': {'headerLen': {'type': 'integer'},
11152 'start': {'type': 'integer'},
11153 'totalLen': {'type': 'integer'}},
11154 'required': ['start', 'totalLen', 'headerLen'],
11155 'type': 'object'}},
11156 'properties': {'AreManuallyProvisioned': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11157 'Result': {'$ref': '#/definitions/BoolResults'}},
11158 'type': 'object'},
11159 'InstanceId': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11160 'Result': {'$ref': '#/definitions/StringResults'}},
11161 'type': 'object'},
11162 'InstanceStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11163 'Result': {'$ref': '#/definitions/StatusResults'}},
11164 'type': 'object'},
11165 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11166 'Result': {'$ref': '#/definitions/LifeResults'}},
11167 'type': 'object'},
11168 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
11169 'type': 'object'},
11170 'ProviderAddresses': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11171 'Result': {'$ref': '#/definitions/MachineAddressesResults'}},
11172 'type': 'object'},
11173 'SetInstanceStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
11174 'Result': {'$ref': '#/definitions/ErrorResults'}},
11175 'type': 'object'},
11176 'SetProviderAddresses': {'properties': {'Params': {'$ref': '#/definitions/SetMachinesAddresses'},
11177 'Result': {'$ref': '#/definitions/ErrorResults'}},
11178 'type': 'object'},
11179 'Status': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11180 'Result': {'$ref': '#/definitions/StatusResults'}},
11181 'type': 'object'},
11182 'WatchForModelConfigChanges': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
11183 'type': 'object'},
11184 'WatchModelMachines': {'properties': {'Result': {'$ref': '#/definitions/StringsWatchResult'}},
11185 'type': 'object'}},
11186 'type': 'object'}
11187
11188
11189 @ReturnMapping(BoolResults)
11190 async def AreManuallyProvisioned(self, entities):
11191 '''
11192 entities : typing.Sequence[~Entity]
11193 Returns -> typing.Sequence[~BoolResult]
11194 '''
11195 # map input types to rpc msg
11196 params = dict()
11197 msg = dict(Type='InstancePoller', Request='AreManuallyProvisioned', Version=3, Params=params)
11198 params['Entities'] = entities
11199 reply = await self.rpc(msg)
11200 return reply
11201
11202
11203
11204 @ReturnMapping(StringResults)
11205 async def InstanceId(self, entities):
11206 '''
11207 entities : typing.Sequence[~Entity]
11208 Returns -> typing.Sequence[~StringResult]
11209 '''
11210 # map input types to rpc msg
11211 params = dict()
11212 msg = dict(Type='InstancePoller', Request='InstanceId', Version=3, Params=params)
11213 params['Entities'] = entities
11214 reply = await self.rpc(msg)
11215 return reply
11216
11217
11218
11219 @ReturnMapping(StatusResults)
11220 async def InstanceStatus(self, entities):
11221 '''
11222 entities : typing.Sequence[~Entity]
11223 Returns -> typing.Sequence[~StatusResult]
11224 '''
11225 # map input types to rpc msg
11226 params = dict()
11227 msg = dict(Type='InstancePoller', Request='InstanceStatus', Version=3, Params=params)
11228 params['Entities'] = entities
11229 reply = await self.rpc(msg)
11230 return reply
11231
11232
11233
11234 @ReturnMapping(LifeResults)
11235 async def Life(self, entities):
11236 '''
11237 entities : typing.Sequence[~Entity]
11238 Returns -> typing.Sequence[~LifeResult]
11239 '''
11240 # map input types to rpc msg
11241 params = dict()
11242 msg = dict(Type='InstancePoller', Request='Life', Version=3, Params=params)
11243 params['Entities'] = entities
11244 reply = await self.rpc(msg)
11245 return reply
11246
11247
11248
11249 @ReturnMapping(ModelConfigResult)
11250 async def ModelConfig(self):
11251 '''
11252
11253 Returns -> typing.Mapping[str, typing.Any]
11254 '''
11255 # map input types to rpc msg
11256 params = dict()
11257 msg = dict(Type='InstancePoller', Request='ModelConfig', Version=3, Params=params)
11258
11259 reply = await self.rpc(msg)
11260 return reply
11261
11262
11263
11264 @ReturnMapping(MachineAddressesResults)
11265 async def ProviderAddresses(self, entities):
11266 '''
11267 entities : typing.Sequence[~Entity]
11268 Returns -> typing.Sequence[~MachineAddressesResult]
11269 '''
11270 # map input types to rpc msg
11271 params = dict()
11272 msg = dict(Type='InstancePoller', Request='ProviderAddresses', Version=3, Params=params)
11273 params['Entities'] = entities
11274 reply = await self.rpc(msg)
11275 return reply
11276
11277
11278
11279 @ReturnMapping(ErrorResults)
11280 async def SetInstanceStatus(self, entities):
11281 '''
11282 entities : typing.Sequence[~EntityStatusArgs]
11283 Returns -> typing.Sequence[~ErrorResult]
11284 '''
11285 # map input types to rpc msg
11286 params = dict()
11287 msg = dict(Type='InstancePoller', Request='SetInstanceStatus', Version=3, Params=params)
11288 params['Entities'] = entities
11289 reply = await self.rpc(msg)
11290 return reply
11291
11292
11293
11294 @ReturnMapping(ErrorResults)
11295 async def SetProviderAddresses(self, machineaddresses):
11296 '''
11297 machineaddresses : typing.Sequence[~MachineAddresses]
11298 Returns -> typing.Sequence[~ErrorResult]
11299 '''
11300 # map input types to rpc msg
11301 params = dict()
11302 msg = dict(Type='InstancePoller', Request='SetProviderAddresses', Version=3, Params=params)
11303 params['MachineAddresses'] = machineaddresses
11304 reply = await self.rpc(msg)
11305 return reply
11306
11307
11308
11309 @ReturnMapping(StatusResults)
11310 async def Status(self, entities):
11311 '''
11312 entities : typing.Sequence[~Entity]
11313 Returns -> typing.Sequence[~StatusResult]
11314 '''
11315 # map input types to rpc msg
11316 params = dict()
11317 msg = dict(Type='InstancePoller', Request='Status', Version=3, Params=params)
11318 params['Entities'] = entities
11319 reply = await self.rpc(msg)
11320 return reply
11321
11322
11323
11324 @ReturnMapping(NotifyWatchResult)
11325 async def WatchForModelConfigChanges(self):
11326 '''
11327
11328 Returns -> typing.Union[_ForwardRef('Error'), str]
11329 '''
11330 # map input types to rpc msg
11331 params = dict()
11332 msg = dict(Type='InstancePoller', Request='WatchForModelConfigChanges', Version=3, Params=params)
11333
11334 reply = await self.rpc(msg)
11335 return reply
11336
11337
11338
11339 @ReturnMapping(StringsWatchResult)
11340 async def WatchModelMachines(self):
11341 '''
11342
11343 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
11344 '''
11345 # map input types to rpc msg
11346 params = dict()
11347 msg = dict(Type='InstancePoller', Request='WatchModelMachines', Version=3, Params=params)
11348
11349 reply = await self.rpc(msg)
11350 return reply
11351
11352
11353 class KeyManagerFacade(Type):
11354 name = 'KeyManager'
11355 version = 1
11356 schema = {'definitions': {'Entities': {'additionalProperties': False,
11357 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
11358 'type': 'array'}},
11359 'required': ['Entities'],
11360 'type': 'object'},
11361 'Entity': {'additionalProperties': False,
11362 'properties': {'Tag': {'type': 'string'}},
11363 'required': ['Tag'],
11364 'type': 'object'},
11365 'Error': {'additionalProperties': False,
11366 'properties': {'Code': {'type': 'string'},
11367 'Info': {'$ref': '#/definitions/ErrorInfo'},
11368 'Message': {'type': 'string'}},
11369 'required': ['Message', 'Code'],
11370 'type': 'object'},
11371 'ErrorInfo': {'additionalProperties': False,
11372 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
11373 'MacaroonPath': {'type': 'string'}},
11374 'type': 'object'},
11375 'ErrorResult': {'additionalProperties': False,
11376 'properties': {'Error': {'$ref': '#/definitions/Error'}},
11377 'required': ['Error'],
11378 'type': 'object'},
11379 'ErrorResults': {'additionalProperties': False,
11380 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
11381 'type': 'array'}},
11382 'required': ['Results'],
11383 'type': 'object'},
11384 'ListSSHKeys': {'additionalProperties': False,
11385 'properties': {'Entities': {'$ref': '#/definitions/Entities'},
11386 'Mode': {'type': 'boolean'}},
11387 'required': ['Entities', 'Mode'],
11388 'type': 'object'},
11389 'Macaroon': {'additionalProperties': False,
11390 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
11391 'type': 'array'},
11392 'data': {'items': {'type': 'integer'},
11393 'type': 'array'},
11394 'id': {'$ref': '#/definitions/packet'},
11395 'location': {'$ref': '#/definitions/packet'},
11396 'sig': {'items': {'type': 'integer'},
11397 'type': 'array'}},
11398 'required': ['data',
11399 'location',
11400 'id',
11401 'caveats',
11402 'sig'],
11403 'type': 'object'},
11404 'ModifyUserSSHKeys': {'additionalProperties': False,
11405 'properties': {'Keys': {'items': {'type': 'string'},
11406 'type': 'array'},
11407 'User': {'type': 'string'}},
11408 'required': ['User', 'Keys'],
11409 'type': 'object'},
11410 'StringsResult': {'additionalProperties': False,
11411 'properties': {'Error': {'$ref': '#/definitions/Error'},
11412 'Result': {'items': {'type': 'string'},
11413 'type': 'array'}},
11414 'required': ['Error', 'Result'],
11415 'type': 'object'},
11416 'StringsResults': {'additionalProperties': False,
11417 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsResult'},
11418 'type': 'array'}},
11419 'required': ['Results'],
11420 'type': 'object'},
11421 'caveat': {'additionalProperties': False,
11422 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
11423 'location': {'$ref': '#/definitions/packet'},
11424 'verificationId': {'$ref': '#/definitions/packet'}},
11425 'required': ['location',
11426 'caveatId',
11427 'verificationId'],
11428 'type': 'object'},
11429 'packet': {'additionalProperties': False,
11430 'properties': {'headerLen': {'type': 'integer'},
11431 'start': {'type': 'integer'},
11432 'totalLen': {'type': 'integer'}},
11433 'required': ['start', 'totalLen', 'headerLen'],
11434 'type': 'object'}},
11435 'properties': {'AddKeys': {'properties': {'Params': {'$ref': '#/definitions/ModifyUserSSHKeys'},
11436 'Result': {'$ref': '#/definitions/ErrorResults'}},
11437 'type': 'object'},
11438 'DeleteKeys': {'properties': {'Params': {'$ref': '#/definitions/ModifyUserSSHKeys'},
11439 'Result': {'$ref': '#/definitions/ErrorResults'}},
11440 'type': 'object'},
11441 'ImportKeys': {'properties': {'Params': {'$ref': '#/definitions/ModifyUserSSHKeys'},
11442 'Result': {'$ref': '#/definitions/ErrorResults'}},
11443 'type': 'object'},
11444 'ListKeys': {'properties': {'Params': {'$ref': '#/definitions/ListSSHKeys'},
11445 'Result': {'$ref': '#/definitions/StringsResults'}},
11446 'type': 'object'}},
11447 'type': 'object'}
11448
11449
11450 @ReturnMapping(ErrorResults)
11451 async def AddKeys(self, keys, user):
11452 '''
11453 keys : typing.Sequence[str]
11454 user : str
11455 Returns -> typing.Sequence[~ErrorResult]
11456 '''
11457 # map input types to rpc msg
11458 params = dict()
11459 msg = dict(Type='KeyManager', Request='AddKeys', Version=1, Params=params)
11460 params['Keys'] = keys
11461 params['User'] = user
11462 reply = await self.rpc(msg)
11463 return reply
11464
11465
11466
11467 @ReturnMapping(ErrorResults)
11468 async def DeleteKeys(self, keys, user):
11469 '''
11470 keys : typing.Sequence[str]
11471 user : str
11472 Returns -> typing.Sequence[~ErrorResult]
11473 '''
11474 # map input types to rpc msg
11475 params = dict()
11476 msg = dict(Type='KeyManager', Request='DeleteKeys', Version=1, Params=params)
11477 params['Keys'] = keys
11478 params['User'] = user
11479 reply = await self.rpc(msg)
11480 return reply
11481
11482
11483
11484 @ReturnMapping(ErrorResults)
11485 async def ImportKeys(self, keys, user):
11486 '''
11487 keys : typing.Sequence[str]
11488 user : str
11489 Returns -> typing.Sequence[~ErrorResult]
11490 '''
11491 # map input types to rpc msg
11492 params = dict()
11493 msg = dict(Type='KeyManager', Request='ImportKeys', Version=1, Params=params)
11494 params['Keys'] = keys
11495 params['User'] = user
11496 reply = await self.rpc(msg)
11497 return reply
11498
11499
11500
11501 @ReturnMapping(StringsResults)
11502 async def ListKeys(self, entities, mode):
11503 '''
11504 entities : Entities
11505 mode : bool
11506 Returns -> typing.Sequence[~StringsResult]
11507 '''
11508 # map input types to rpc msg
11509 params = dict()
11510 msg = dict(Type='KeyManager', Request='ListKeys', Version=1, Params=params)
11511 params['Entities'] = entities
11512 params['Mode'] = mode
11513 reply = await self.rpc(msg)
11514 return reply
11515
11516
11517 class KeyUpdaterFacade(Type):
11518 name = 'KeyUpdater'
11519 version = 1
11520 schema = {'definitions': {'Entities': {'additionalProperties': False,
11521 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
11522 'type': 'array'}},
11523 'required': ['Entities'],
11524 'type': 'object'},
11525 'Entity': {'additionalProperties': False,
11526 'properties': {'Tag': {'type': 'string'}},
11527 'required': ['Tag'],
11528 'type': 'object'},
11529 'Error': {'additionalProperties': False,
11530 'properties': {'Code': {'type': 'string'},
11531 'Info': {'$ref': '#/definitions/ErrorInfo'},
11532 'Message': {'type': 'string'}},
11533 'required': ['Message', 'Code'],
11534 'type': 'object'},
11535 'ErrorInfo': {'additionalProperties': False,
11536 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
11537 'MacaroonPath': {'type': 'string'}},
11538 'type': 'object'},
11539 'Macaroon': {'additionalProperties': False,
11540 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
11541 'type': 'array'},
11542 'data': {'items': {'type': 'integer'},
11543 'type': 'array'},
11544 'id': {'$ref': '#/definitions/packet'},
11545 'location': {'$ref': '#/definitions/packet'},
11546 'sig': {'items': {'type': 'integer'},
11547 'type': 'array'}},
11548 'required': ['data',
11549 'location',
11550 'id',
11551 'caveats',
11552 'sig'],
11553 'type': 'object'},
11554 'NotifyWatchResult': {'additionalProperties': False,
11555 'properties': {'Error': {'$ref': '#/definitions/Error'},
11556 'NotifyWatcherId': {'type': 'string'}},
11557 'required': ['NotifyWatcherId', 'Error'],
11558 'type': 'object'},
11559 'NotifyWatchResults': {'additionalProperties': False,
11560 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
11561 'type': 'array'}},
11562 'required': ['Results'],
11563 'type': 'object'},
11564 'StringsResult': {'additionalProperties': False,
11565 'properties': {'Error': {'$ref': '#/definitions/Error'},
11566 'Result': {'items': {'type': 'string'},
11567 'type': 'array'}},
11568 'required': ['Error', 'Result'],
11569 'type': 'object'},
11570 'StringsResults': {'additionalProperties': False,
11571 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsResult'},
11572 'type': 'array'}},
11573 'required': ['Results'],
11574 'type': 'object'},
11575 'caveat': {'additionalProperties': False,
11576 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
11577 'location': {'$ref': '#/definitions/packet'},
11578 'verificationId': {'$ref': '#/definitions/packet'}},
11579 'required': ['location',
11580 'caveatId',
11581 'verificationId'],
11582 'type': 'object'},
11583 'packet': {'additionalProperties': False,
11584 'properties': {'headerLen': {'type': 'integer'},
11585 'start': {'type': 'integer'},
11586 'totalLen': {'type': 'integer'}},
11587 'required': ['start', 'totalLen', 'headerLen'],
11588 'type': 'object'}},
11589 'properties': {'AuthorisedKeys': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11590 'Result': {'$ref': '#/definitions/StringsResults'}},
11591 'type': 'object'},
11592 'WatchAuthorisedKeys': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11593 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
11594 'type': 'object'}},
11595 'type': 'object'}
11596
11597
11598 @ReturnMapping(StringsResults)
11599 async def AuthorisedKeys(self, entities):
11600 '''
11601 entities : typing.Sequence[~Entity]
11602 Returns -> typing.Sequence[~StringsResult]
11603 '''
11604 # map input types to rpc msg
11605 params = dict()
11606 msg = dict(Type='KeyUpdater', Request='AuthorisedKeys', Version=1, Params=params)
11607 params['Entities'] = entities
11608 reply = await self.rpc(msg)
11609 return reply
11610
11611
11612
11613 @ReturnMapping(NotifyWatchResults)
11614 async def WatchAuthorisedKeys(self, entities):
11615 '''
11616 entities : typing.Sequence[~Entity]
11617 Returns -> typing.Sequence[~NotifyWatchResult]
11618 '''
11619 # map input types to rpc msg
11620 params = dict()
11621 msg = dict(Type='KeyUpdater', Request='WatchAuthorisedKeys', Version=1, Params=params)
11622 params['Entities'] = entities
11623 reply = await self.rpc(msg)
11624 return reply
11625
11626
11627 class LeadershipServiceFacade(Type):
11628 name = 'LeadershipService'
11629 version = 2
11630 schema = {'definitions': {'ApplicationTag': {'additionalProperties': False,
11631 'properties': {'Name': {'type': 'string'}},
11632 'required': ['Name'],
11633 'type': 'object'},
11634 'ClaimLeadershipBulkParams': {'additionalProperties': False,
11635 'properties': {'Params': {'items': {'$ref': '#/definitions/ClaimLeadershipParams'},
11636 'type': 'array'}},
11637 'required': ['Params'],
11638 'type': 'object'},
11639 'ClaimLeadershipBulkResults': {'additionalProperties': False,
11640 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
11641 'type': 'array'}},
11642 'required': ['Results'],
11643 'type': 'object'},
11644 'ClaimLeadershipParams': {'additionalProperties': False,
11645 'properties': {'ApplicationTag': {'type': 'string'},
11646 'DurationSeconds': {'type': 'number'},
11647 'UnitTag': {'type': 'string'}},
11648 'required': ['ApplicationTag',
11649 'UnitTag',
11650 'DurationSeconds'],
11651 'type': 'object'},
11652 'Error': {'additionalProperties': False,
11653 'properties': {'Code': {'type': 'string'},
11654 'Info': {'$ref': '#/definitions/ErrorInfo'},
11655 'Message': {'type': 'string'}},
11656 'required': ['Message', 'Code'],
11657 'type': 'object'},
11658 'ErrorInfo': {'additionalProperties': False,
11659 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
11660 'MacaroonPath': {'type': 'string'}},
11661 'type': 'object'},
11662 'ErrorResult': {'additionalProperties': False,
11663 'properties': {'Error': {'$ref': '#/definitions/Error'}},
11664 'required': ['Error'],
11665 'type': 'object'},
11666 'Macaroon': {'additionalProperties': False,
11667 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
11668 'type': 'array'},
11669 'data': {'items': {'type': 'integer'},
11670 'type': 'array'},
11671 'id': {'$ref': '#/definitions/packet'},
11672 'location': {'$ref': '#/definitions/packet'},
11673 'sig': {'items': {'type': 'integer'},
11674 'type': 'array'}},
11675 'required': ['data',
11676 'location',
11677 'id',
11678 'caveats',
11679 'sig'],
11680 'type': 'object'},
11681 'caveat': {'additionalProperties': False,
11682 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
11683 'location': {'$ref': '#/definitions/packet'},
11684 'verificationId': {'$ref': '#/definitions/packet'}},
11685 'required': ['location',
11686 'caveatId',
11687 'verificationId'],
11688 'type': 'object'},
11689 'packet': {'additionalProperties': False,
11690 'properties': {'headerLen': {'type': 'integer'},
11691 'start': {'type': 'integer'},
11692 'totalLen': {'type': 'integer'}},
11693 'required': ['start', 'totalLen', 'headerLen'],
11694 'type': 'object'}},
11695 'properties': {'BlockUntilLeadershipReleased': {'properties': {'Params': {'$ref': '#/definitions/ApplicationTag'},
11696 'Result': {'$ref': '#/definitions/ErrorResult'}},
11697 'type': 'object'},
11698 'ClaimLeadership': {'properties': {'Params': {'$ref': '#/definitions/ClaimLeadershipBulkParams'},
11699 'Result': {'$ref': '#/definitions/ClaimLeadershipBulkResults'}},
11700 'type': 'object'}},
11701 'type': 'object'}
11702
11703
11704 @ReturnMapping(ErrorResult)
11705 async def BlockUntilLeadershipReleased(self, name):
11706 '''
11707 name : str
11708 Returns -> Error
11709 '''
11710 # map input types to rpc msg
11711 params = dict()
11712 msg = dict(Type='LeadershipService', Request='BlockUntilLeadershipReleased', Version=2, Params=params)
11713 params['Name'] = name
11714 reply = await self.rpc(msg)
11715 return reply
11716
11717
11718
11719 @ReturnMapping(ClaimLeadershipBulkResults)
11720 async def ClaimLeadership(self, params):
11721 '''
11722 params : typing.Sequence[~ClaimLeadershipParams]
11723 Returns -> typing.Sequence[~ErrorResult]
11724 '''
11725 # map input types to rpc msg
11726 params = dict()
11727 msg = dict(Type='LeadershipService', Request='ClaimLeadership', Version=2, Params=params)
11728 params['Params'] = params
11729 reply = await self.rpc(msg)
11730 return reply
11731
11732
11733 class LifeFlagFacade(Type):
11734 name = 'LifeFlag'
11735 version = 1
11736 schema = {'definitions': {'Entities': {'additionalProperties': False,
11737 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
11738 'type': 'array'}},
11739 'required': ['Entities'],
11740 'type': 'object'},
11741 'Entity': {'additionalProperties': False,
11742 'properties': {'Tag': {'type': 'string'}},
11743 'required': ['Tag'],
11744 'type': 'object'},
11745 'Error': {'additionalProperties': False,
11746 'properties': {'Code': {'type': 'string'},
11747 'Info': {'$ref': '#/definitions/ErrorInfo'},
11748 'Message': {'type': 'string'}},
11749 'required': ['Message', 'Code'],
11750 'type': 'object'},
11751 'ErrorInfo': {'additionalProperties': False,
11752 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
11753 'MacaroonPath': {'type': 'string'}},
11754 'type': 'object'},
11755 'LifeResult': {'additionalProperties': False,
11756 'properties': {'Error': {'$ref': '#/definitions/Error'},
11757 'Life': {'type': 'string'}},
11758 'required': ['Life', 'Error'],
11759 'type': 'object'},
11760 'LifeResults': {'additionalProperties': False,
11761 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
11762 'type': 'array'}},
11763 'required': ['Results'],
11764 'type': 'object'},
11765 'Macaroon': {'additionalProperties': False,
11766 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
11767 'type': 'array'},
11768 'data': {'items': {'type': 'integer'},
11769 'type': 'array'},
11770 'id': {'$ref': '#/definitions/packet'},
11771 'location': {'$ref': '#/definitions/packet'},
11772 'sig': {'items': {'type': 'integer'},
11773 'type': 'array'}},
11774 'required': ['data',
11775 'location',
11776 'id',
11777 'caveats',
11778 'sig'],
11779 'type': 'object'},
11780 'NotifyWatchResult': {'additionalProperties': False,
11781 'properties': {'Error': {'$ref': '#/definitions/Error'},
11782 'NotifyWatcherId': {'type': 'string'}},
11783 'required': ['NotifyWatcherId', 'Error'],
11784 'type': 'object'},
11785 'NotifyWatchResults': {'additionalProperties': False,
11786 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
11787 'type': 'array'}},
11788 'required': ['Results'],
11789 'type': 'object'},
11790 'caveat': {'additionalProperties': False,
11791 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
11792 'location': {'$ref': '#/definitions/packet'},
11793 'verificationId': {'$ref': '#/definitions/packet'}},
11794 'required': ['location',
11795 'caveatId',
11796 'verificationId'],
11797 'type': 'object'},
11798 'packet': {'additionalProperties': False,
11799 'properties': {'headerLen': {'type': 'integer'},
11800 'start': {'type': 'integer'},
11801 'totalLen': {'type': 'integer'}},
11802 'required': ['start', 'totalLen', 'headerLen'],
11803 'type': 'object'}},
11804 'properties': {'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11805 'Result': {'$ref': '#/definitions/LifeResults'}},
11806 'type': 'object'},
11807 'Watch': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11808 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
11809 'type': 'object'}},
11810 'type': 'object'}
11811
11812
11813 @ReturnMapping(LifeResults)
11814 async def Life(self, entities):
11815 '''
11816 entities : typing.Sequence[~Entity]
11817 Returns -> typing.Sequence[~LifeResult]
11818 '''
11819 # map input types to rpc msg
11820 params = dict()
11821 msg = dict(Type='LifeFlag', Request='Life', Version=1, Params=params)
11822 params['Entities'] = entities
11823 reply = await self.rpc(msg)
11824 return reply
11825
11826
11827
11828 @ReturnMapping(NotifyWatchResults)
11829 async def Watch(self, entities):
11830 '''
11831 entities : typing.Sequence[~Entity]
11832 Returns -> typing.Sequence[~NotifyWatchResult]
11833 '''
11834 # map input types to rpc msg
11835 params = dict()
11836 msg = dict(Type='LifeFlag', Request='Watch', Version=1, Params=params)
11837 params['Entities'] = entities
11838 reply = await self.rpc(msg)
11839 return reply
11840
11841
11842 class LoggerFacade(Type):
11843 name = 'Logger'
11844 version = 1
11845 schema = {'definitions': {'Entities': {'additionalProperties': False,
11846 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
11847 'type': 'array'}},
11848 'required': ['Entities'],
11849 'type': 'object'},
11850 'Entity': {'additionalProperties': False,
11851 'properties': {'Tag': {'type': 'string'}},
11852 'required': ['Tag'],
11853 'type': 'object'},
11854 'Error': {'additionalProperties': False,
11855 'properties': {'Code': {'type': 'string'},
11856 'Info': {'$ref': '#/definitions/ErrorInfo'},
11857 'Message': {'type': 'string'}},
11858 'required': ['Message', 'Code'],
11859 'type': 'object'},
11860 'ErrorInfo': {'additionalProperties': False,
11861 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
11862 'MacaroonPath': {'type': 'string'}},
11863 'type': 'object'},
11864 'Macaroon': {'additionalProperties': False,
11865 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
11866 'type': 'array'},
11867 'data': {'items': {'type': 'integer'},
11868 'type': 'array'},
11869 'id': {'$ref': '#/definitions/packet'},
11870 'location': {'$ref': '#/definitions/packet'},
11871 'sig': {'items': {'type': 'integer'},
11872 'type': 'array'}},
11873 'required': ['data',
11874 'location',
11875 'id',
11876 'caveats',
11877 'sig'],
11878 'type': 'object'},
11879 'NotifyWatchResult': {'additionalProperties': False,
11880 'properties': {'Error': {'$ref': '#/definitions/Error'},
11881 'NotifyWatcherId': {'type': 'string'}},
11882 'required': ['NotifyWatcherId', 'Error'],
11883 'type': 'object'},
11884 'NotifyWatchResults': {'additionalProperties': False,
11885 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
11886 'type': 'array'}},
11887 'required': ['Results'],
11888 'type': 'object'},
11889 'StringResult': {'additionalProperties': False,
11890 'properties': {'Error': {'$ref': '#/definitions/Error'},
11891 'Result': {'type': 'string'}},
11892 'required': ['Error', 'Result'],
11893 'type': 'object'},
11894 'StringResults': {'additionalProperties': False,
11895 'properties': {'Results': {'items': {'$ref': '#/definitions/StringResult'},
11896 'type': 'array'}},
11897 'required': ['Results'],
11898 'type': 'object'},
11899 'caveat': {'additionalProperties': False,
11900 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
11901 'location': {'$ref': '#/definitions/packet'},
11902 'verificationId': {'$ref': '#/definitions/packet'}},
11903 'required': ['location',
11904 'caveatId',
11905 'verificationId'],
11906 'type': 'object'},
11907 'packet': {'additionalProperties': False,
11908 'properties': {'headerLen': {'type': 'integer'},
11909 'start': {'type': 'integer'},
11910 'totalLen': {'type': 'integer'}},
11911 'required': ['start', 'totalLen', 'headerLen'],
11912 'type': 'object'}},
11913 'properties': {'LoggingConfig': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11914 'Result': {'$ref': '#/definitions/StringResults'}},
11915 'type': 'object'},
11916 'WatchLoggingConfig': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
11917 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
11918 'type': 'object'}},
11919 'type': 'object'}
11920
11921
11922 @ReturnMapping(StringResults)
11923 async def LoggingConfig(self, entities):
11924 '''
11925 entities : typing.Sequence[~Entity]
11926 Returns -> typing.Sequence[~StringResult]
11927 '''
11928 # map input types to rpc msg
11929 params = dict()
11930 msg = dict(Type='Logger', Request='LoggingConfig', Version=1, Params=params)
11931 params['Entities'] = entities
11932 reply = await self.rpc(msg)
11933 return reply
11934
11935
11936
11937 @ReturnMapping(NotifyWatchResults)
11938 async def WatchLoggingConfig(self, entities):
11939 '''
11940 entities : typing.Sequence[~Entity]
11941 Returns -> typing.Sequence[~NotifyWatchResult]
11942 '''
11943 # map input types to rpc msg
11944 params = dict()
11945 msg = dict(Type='Logger', Request='WatchLoggingConfig', Version=1, Params=params)
11946 params['Entities'] = entities
11947 reply = await self.rpc(msg)
11948 return reply
11949
11950
11951 class MachineActionsFacade(Type):
11952 name = 'MachineActions'
11953 version = 1
11954 schema = {'definitions': {'Action': {'additionalProperties': False,
11955 'properties': {'name': {'type': 'string'},
11956 'parameters': {'patternProperties': {'.*': {'additionalProperties': True,
11957 'type': 'object'}},
11958 'type': 'object'},
11959 'receiver': {'type': 'string'},
11960 'tag': {'type': 'string'}},
11961 'required': ['tag', 'receiver', 'name'],
11962 'type': 'object'},
11963 'ActionExecutionResult': {'additionalProperties': False,
11964 'properties': {'actiontag': {'type': 'string'},
11965 'message': {'type': 'string'},
11966 'results': {'patternProperties': {'.*': {'additionalProperties': True,
11967 'type': 'object'}},
11968 'type': 'object'},
11969 'status': {'type': 'string'}},
11970 'required': ['actiontag', 'status'],
11971 'type': 'object'},
11972 'ActionExecutionResults': {'additionalProperties': False,
11973 'properties': {'results': {'items': {'$ref': '#/definitions/ActionExecutionResult'},
11974 'type': 'array'}},
11975 'type': 'object'},
11976 'ActionResult': {'additionalProperties': False,
11977 'properties': {'action': {'$ref': '#/definitions/Action'},
11978 'completed': {'format': 'date-time',
11979 'type': 'string'},
11980 'enqueued': {'format': 'date-time',
11981 'type': 'string'},
11982 'error': {'$ref': '#/definitions/Error'},
11983 'message': {'type': 'string'},
11984 'output': {'patternProperties': {'.*': {'additionalProperties': True,
11985 'type': 'object'}},
11986 'type': 'object'},
11987 'started': {'format': 'date-time',
11988 'type': 'string'},
11989 'status': {'type': 'string'}},
11990 'type': 'object'},
11991 'ActionResults': {'additionalProperties': False,
11992 'properties': {'results': {'items': {'$ref': '#/definitions/ActionResult'},
11993 'type': 'array'}},
11994 'type': 'object'},
11995 'ActionsByReceiver': {'additionalProperties': False,
11996 'properties': {'actions': {'items': {'$ref': '#/definitions/ActionResult'},
11997 'type': 'array'},
11998 'error': {'$ref': '#/definitions/Error'},
11999 'receiver': {'type': 'string'}},
12000 'type': 'object'},
12001 'ActionsByReceivers': {'additionalProperties': False,
12002 'properties': {'actions': {'items': {'$ref': '#/definitions/ActionsByReceiver'},
12003 'type': 'array'}},
12004 'type': 'object'},
12005 'Entities': {'additionalProperties': False,
12006 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
12007 'type': 'array'}},
12008 'required': ['Entities'],
12009 'type': 'object'},
12010 'Entity': {'additionalProperties': False,
12011 'properties': {'Tag': {'type': 'string'}},
12012 'required': ['Tag'],
12013 'type': 'object'},
12014 'Error': {'additionalProperties': False,
12015 'properties': {'Code': {'type': 'string'},
12016 'Info': {'$ref': '#/definitions/ErrorInfo'},
12017 'Message': {'type': 'string'}},
12018 'required': ['Message', 'Code'],
12019 'type': 'object'},
12020 'ErrorInfo': {'additionalProperties': False,
12021 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
12022 'MacaroonPath': {'type': 'string'}},
12023 'type': 'object'},
12024 'ErrorResult': {'additionalProperties': False,
12025 'properties': {'Error': {'$ref': '#/definitions/Error'}},
12026 'required': ['Error'],
12027 'type': 'object'},
12028 'ErrorResults': {'additionalProperties': False,
12029 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
12030 'type': 'array'}},
12031 'required': ['Results'],
12032 'type': 'object'},
12033 'Macaroon': {'additionalProperties': False,
12034 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
12035 'type': 'array'},
12036 'data': {'items': {'type': 'integer'},
12037 'type': 'array'},
12038 'id': {'$ref': '#/definitions/packet'},
12039 'location': {'$ref': '#/definitions/packet'},
12040 'sig': {'items': {'type': 'integer'},
12041 'type': 'array'}},
12042 'required': ['data',
12043 'location',
12044 'id',
12045 'caveats',
12046 'sig'],
12047 'type': 'object'},
12048 'StringsWatchResult': {'additionalProperties': False,
12049 'properties': {'Changes': {'items': {'type': 'string'},
12050 'type': 'array'},
12051 'Error': {'$ref': '#/definitions/Error'},
12052 'StringsWatcherId': {'type': 'string'}},
12053 'required': ['StringsWatcherId',
12054 'Changes',
12055 'Error'],
12056 'type': 'object'},
12057 'StringsWatchResults': {'additionalProperties': False,
12058 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsWatchResult'},
12059 'type': 'array'}},
12060 'required': ['Results'],
12061 'type': 'object'},
12062 'caveat': {'additionalProperties': False,
12063 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
12064 'location': {'$ref': '#/definitions/packet'},
12065 'verificationId': {'$ref': '#/definitions/packet'}},
12066 'required': ['location',
12067 'caveatId',
12068 'verificationId'],
12069 'type': 'object'},
12070 'packet': {'additionalProperties': False,
12071 'properties': {'headerLen': {'type': 'integer'},
12072 'start': {'type': 'integer'},
12073 'totalLen': {'type': 'integer'}},
12074 'required': ['start', 'totalLen', 'headerLen'],
12075 'type': 'object'}},
12076 'properties': {'Actions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12077 'Result': {'$ref': '#/definitions/ActionResults'}},
12078 'type': 'object'},
12079 'BeginActions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12080 'Result': {'$ref': '#/definitions/ErrorResults'}},
12081 'type': 'object'},
12082 'FinishActions': {'properties': {'Params': {'$ref': '#/definitions/ActionExecutionResults'},
12083 'Result': {'$ref': '#/definitions/ErrorResults'}},
12084 'type': 'object'},
12085 'RunningActions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12086 'Result': {'$ref': '#/definitions/ActionsByReceivers'}},
12087 'type': 'object'},
12088 'WatchActionNotifications': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12089 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
12090 'type': 'object'}},
12091 'type': 'object'}
12092
12093
12094 @ReturnMapping(ActionResults)
12095 async def Actions(self, entities):
12096 '''
12097 entities : typing.Sequence[~Entity]
12098 Returns -> typing.Sequence[~ActionResult]
12099 '''
12100 # map input types to rpc msg
12101 params = dict()
12102 msg = dict(Type='MachineActions', Request='Actions', Version=1, Params=params)
12103 params['Entities'] = entities
12104 reply = await self.rpc(msg)
12105 return reply
12106
12107
12108
12109 @ReturnMapping(ErrorResults)
12110 async def BeginActions(self, entities):
12111 '''
12112 entities : typing.Sequence[~Entity]
12113 Returns -> typing.Sequence[~ErrorResult]
12114 '''
12115 # map input types to rpc msg
12116 params = dict()
12117 msg = dict(Type='MachineActions', Request='BeginActions', Version=1, Params=params)
12118 params['Entities'] = entities
12119 reply = await self.rpc(msg)
12120 return reply
12121
12122
12123
12124 @ReturnMapping(ErrorResults)
12125 async def FinishActions(self, results):
12126 '''
12127 results : typing.Sequence[~ActionExecutionResult]
12128 Returns -> typing.Sequence[~ErrorResult]
12129 '''
12130 # map input types to rpc msg
12131 params = dict()
12132 msg = dict(Type='MachineActions', Request='FinishActions', Version=1, Params=params)
12133 params['results'] = results
12134 reply = await self.rpc(msg)
12135 return reply
12136
12137
12138
12139 @ReturnMapping(ActionsByReceivers)
12140 async def RunningActions(self, entities):
12141 '''
12142 entities : typing.Sequence[~Entity]
12143 Returns -> typing.Sequence[~ActionsByReceiver]
12144 '''
12145 # map input types to rpc msg
12146 params = dict()
12147 msg = dict(Type='MachineActions', Request='RunningActions', Version=1, Params=params)
12148 params['Entities'] = entities
12149 reply = await self.rpc(msg)
12150 return reply
12151
12152
12153
12154 @ReturnMapping(StringsWatchResults)
12155 async def WatchActionNotifications(self, entities):
12156 '''
12157 entities : typing.Sequence[~Entity]
12158 Returns -> typing.Sequence[~StringsWatchResult]
12159 '''
12160 # map input types to rpc msg
12161 params = dict()
12162 msg = dict(Type='MachineActions', Request='WatchActionNotifications', Version=1, Params=params)
12163 params['Entities'] = entities
12164 reply = await self.rpc(msg)
12165 return reply
12166
12167
12168 class MachineManagerFacade(Type):
12169 name = 'MachineManager'
12170 version = 2
12171 schema = {'definitions': {'AddMachineParams': {'additionalProperties': False,
12172 'properties': {'Addrs': {'items': {'$ref': '#/definitions/Address'},
12173 'type': 'array'},
12174 'Constraints': {'$ref': '#/definitions/Value'},
12175 'ContainerType': {'type': 'string'},
12176 'Disks': {'items': {'$ref': '#/definitions/Constraints'},
12177 'type': 'array'},
12178 'HardwareCharacteristics': {'$ref': '#/definitions/HardwareCharacteristics'},
12179 'InstanceId': {'type': 'string'},
12180 'Jobs': {'items': {'type': 'string'},
12181 'type': 'array'},
12182 'Nonce': {'type': 'string'},
12183 'ParentId': {'type': 'string'},
12184 'Placement': {'$ref': '#/definitions/Placement'},
12185 'Series': {'type': 'string'}},
12186 'required': ['Series',
12187 'Constraints',
12188 'Jobs',
12189 'Disks',
12190 'Placement',
12191 'ParentId',
12192 'ContainerType',
12193 'InstanceId',
12194 'Nonce',
12195 'HardwareCharacteristics',
12196 'Addrs'],
12197 'type': 'object'},
12198 'AddMachines': {'additionalProperties': False,
12199 'properties': {'MachineParams': {'items': {'$ref': '#/definitions/AddMachineParams'},
12200 'type': 'array'}},
12201 'required': ['MachineParams'],
12202 'type': 'object'},
12203 'AddMachinesResult': {'additionalProperties': False,
12204 'properties': {'Error': {'$ref': '#/definitions/Error'},
12205 'Machine': {'type': 'string'}},
12206 'required': ['Machine', 'Error'],
12207 'type': 'object'},
12208 'AddMachinesResults': {'additionalProperties': False,
12209 'properties': {'Machines': {'items': {'$ref': '#/definitions/AddMachinesResult'},
12210 'type': 'array'}},
12211 'required': ['Machines'],
12212 'type': 'object'},
12213 'Address': {'additionalProperties': False,
12214 'properties': {'Scope': {'type': 'string'},
12215 'SpaceName': {'type': 'string'},
12216 'Type': {'type': 'string'},
12217 'Value': {'type': 'string'}},
12218 'required': ['Value', 'Type', 'Scope'],
12219 'type': 'object'},
12220 'Constraints': {'additionalProperties': False,
12221 'properties': {'Count': {'type': 'integer'},
12222 'Pool': {'type': 'string'},
12223 'Size': {'type': 'integer'}},
12224 'required': ['Pool', 'Size', 'Count'],
12225 'type': 'object'},
12226 'Error': {'additionalProperties': False,
12227 'properties': {'Code': {'type': 'string'},
12228 'Info': {'$ref': '#/definitions/ErrorInfo'},
12229 'Message': {'type': 'string'}},
12230 'required': ['Message', 'Code'],
12231 'type': 'object'},
12232 'ErrorInfo': {'additionalProperties': False,
12233 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
12234 'MacaroonPath': {'type': 'string'}},
12235 'type': 'object'},
12236 'HardwareCharacteristics': {'additionalProperties': False,
12237 'properties': {'Arch': {'type': 'string'},
12238 'AvailabilityZone': {'type': 'string'},
12239 'CpuCores': {'type': 'integer'},
12240 'CpuPower': {'type': 'integer'},
12241 'Mem': {'type': 'integer'},
12242 'RootDisk': {'type': 'integer'},
12243 'Tags': {'items': {'type': 'string'},
12244 'type': 'array'}},
12245 'type': 'object'},
12246 'Macaroon': {'additionalProperties': False,
12247 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
12248 'type': 'array'},
12249 'data': {'items': {'type': 'integer'},
12250 'type': 'array'},
12251 'id': {'$ref': '#/definitions/packet'},
12252 'location': {'$ref': '#/definitions/packet'},
12253 'sig': {'items': {'type': 'integer'},
12254 'type': 'array'}},
12255 'required': ['data',
12256 'location',
12257 'id',
12258 'caveats',
12259 'sig'],
12260 'type': 'object'},
12261 'Placement': {'additionalProperties': False,
12262 'properties': {'Directive': {'type': 'string'},
12263 'Scope': {'type': 'string'}},
12264 'required': ['Scope', 'Directive'],
12265 'type': 'object'},
12266 'Value': {'additionalProperties': False,
12267 'properties': {'arch': {'type': 'string'},
12268 'container': {'type': 'string'},
12269 'cpu-cores': {'type': 'integer'},
12270 'cpu-power': {'type': 'integer'},
12271 'instance-type': {'type': 'string'},
12272 'mem': {'type': 'integer'},
12273 'root-disk': {'type': 'integer'},
12274 'spaces': {'items': {'type': 'string'},
12275 'type': 'array'},
12276 'tags': {'items': {'type': 'string'},
12277 'type': 'array'},
12278 'virt-type': {'type': 'string'}},
12279 'type': 'object'},
12280 'caveat': {'additionalProperties': False,
12281 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
12282 'location': {'$ref': '#/definitions/packet'},
12283 'verificationId': {'$ref': '#/definitions/packet'}},
12284 'required': ['location',
12285 'caveatId',
12286 'verificationId'],
12287 'type': 'object'},
12288 'packet': {'additionalProperties': False,
12289 'properties': {'headerLen': {'type': 'integer'},
12290 'start': {'type': 'integer'},
12291 'totalLen': {'type': 'integer'}},
12292 'required': ['start', 'totalLen', 'headerLen'],
12293 'type': 'object'}},
12294 'properties': {'AddMachines': {'properties': {'Params': {'$ref': '#/definitions/AddMachines'},
12295 'Result': {'$ref': '#/definitions/AddMachinesResults'}},
12296 'type': 'object'}},
12297 'type': 'object'}
12298
12299
12300 @ReturnMapping(AddMachinesResults)
12301 async def AddMachines(self, machineparams):
12302 '''
12303 machineparams : typing.Sequence[~AddMachineParams]
12304 Returns -> typing.Sequence[~AddMachinesResult]
12305 '''
12306 # map input types to rpc msg
12307 params = dict()
12308 msg = dict(Type='MachineManager', Request='AddMachines', Version=2, Params=params)
12309 params['MachineParams'] = machineparams
12310 reply = await self.rpc(msg)
12311 return reply
12312
12313
12314 class MachinerFacade(Type):
12315 name = 'Machiner'
12316 version = 1
12317 schema = {'definitions': {'APIHostPortsResult': {'additionalProperties': False,
12318 'properties': {'Servers': {'items': {'items': {'$ref': '#/definitions/HostPort'},
12319 'type': 'array'},
12320 'type': 'array'}},
12321 'required': ['Servers'],
12322 'type': 'object'},
12323 'Address': {'additionalProperties': False,
12324 'properties': {'Scope': {'type': 'string'},
12325 'SpaceName': {'type': 'string'},
12326 'Type': {'type': 'string'},
12327 'Value': {'type': 'string'}},
12328 'required': ['Value', 'Type', 'Scope'],
12329 'type': 'object'},
12330 'BytesResult': {'additionalProperties': False,
12331 'properties': {'Result': {'items': {'type': 'integer'},
12332 'type': 'array'}},
12333 'required': ['Result'],
12334 'type': 'object'},
12335 'Entities': {'additionalProperties': False,
12336 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
12337 'type': 'array'}},
12338 'required': ['Entities'],
12339 'type': 'object'},
12340 'Entity': {'additionalProperties': False,
12341 'properties': {'Tag': {'type': 'string'}},
12342 'required': ['Tag'],
12343 'type': 'object'},
12344 'EntityStatusArgs': {'additionalProperties': False,
12345 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
12346 'type': 'object'}},
12347 'type': 'object'},
12348 'Info': {'type': 'string'},
12349 'Status': {'type': 'string'},
12350 'Tag': {'type': 'string'}},
12351 'required': ['Tag',
12352 'Status',
12353 'Info',
12354 'Data'],
12355 'type': 'object'},
12356 'Error': {'additionalProperties': False,
12357 'properties': {'Code': {'type': 'string'},
12358 'Info': {'$ref': '#/definitions/ErrorInfo'},
12359 'Message': {'type': 'string'}},
12360 'required': ['Message', 'Code'],
12361 'type': 'object'},
12362 'ErrorInfo': {'additionalProperties': False,
12363 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
12364 'MacaroonPath': {'type': 'string'}},
12365 'type': 'object'},
12366 'ErrorResult': {'additionalProperties': False,
12367 'properties': {'Error': {'$ref': '#/definitions/Error'}},
12368 'required': ['Error'],
12369 'type': 'object'},
12370 'ErrorResults': {'additionalProperties': False,
12371 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
12372 'type': 'array'}},
12373 'required': ['Results'],
12374 'type': 'object'},
12375 'HostPort': {'additionalProperties': False,
12376 'properties': {'Address': {'$ref': '#/definitions/Address'},
12377 'Port': {'type': 'integer'}},
12378 'required': ['Address', 'Port'],
12379 'type': 'object'},
12380 'JobsResult': {'additionalProperties': False,
12381 'properties': {'Error': {'$ref': '#/definitions/Error'},
12382 'Jobs': {'items': {'type': 'string'},
12383 'type': 'array'}},
12384 'required': ['Jobs', 'Error'],
12385 'type': 'object'},
12386 'JobsResults': {'additionalProperties': False,
12387 'properties': {'Results': {'items': {'$ref': '#/definitions/JobsResult'},
12388 'type': 'array'}},
12389 'required': ['Results'],
12390 'type': 'object'},
12391 'LifeResult': {'additionalProperties': False,
12392 'properties': {'Error': {'$ref': '#/definitions/Error'},
12393 'Life': {'type': 'string'}},
12394 'required': ['Life', 'Error'],
12395 'type': 'object'},
12396 'LifeResults': {'additionalProperties': False,
12397 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
12398 'type': 'array'}},
12399 'required': ['Results'],
12400 'type': 'object'},
12401 'Macaroon': {'additionalProperties': False,
12402 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
12403 'type': 'array'},
12404 'data': {'items': {'type': 'integer'},
12405 'type': 'array'},
12406 'id': {'$ref': '#/definitions/packet'},
12407 'location': {'$ref': '#/definitions/packet'},
12408 'sig': {'items': {'type': 'integer'},
12409 'type': 'array'}},
12410 'required': ['data',
12411 'location',
12412 'id',
12413 'caveats',
12414 'sig'],
12415 'type': 'object'},
12416 'MachineAddresses': {'additionalProperties': False,
12417 'properties': {'Addresses': {'items': {'$ref': '#/definitions/Address'},
12418 'type': 'array'},
12419 'Tag': {'type': 'string'}},
12420 'required': ['Tag', 'Addresses'],
12421 'type': 'object'},
12422 'NetworkConfig': {'additionalProperties': False,
12423 'properties': {'Address': {'type': 'string'},
12424 'CIDR': {'type': 'string'},
12425 'ConfigType': {'type': 'string'},
12426 'DNSSearchDomains': {'items': {'type': 'string'},
12427 'type': 'array'},
12428 'DNSServers': {'items': {'type': 'string'},
12429 'type': 'array'},
12430 'DeviceIndex': {'type': 'integer'},
12431 'Disabled': {'type': 'boolean'},
12432 'GatewayAddress': {'type': 'string'},
12433 'InterfaceName': {'type': 'string'},
12434 'InterfaceType': {'type': 'string'},
12435 'MACAddress': {'type': 'string'},
12436 'MTU': {'type': 'integer'},
12437 'NoAutoStart': {'type': 'boolean'},
12438 'ParentInterfaceName': {'type': 'string'},
12439 'ProviderAddressId': {'type': 'string'},
12440 'ProviderId': {'type': 'string'},
12441 'ProviderSpaceId': {'type': 'string'},
12442 'ProviderSubnetId': {'type': 'string'},
12443 'ProviderVLANId': {'type': 'string'},
12444 'VLANTag': {'type': 'integer'}},
12445 'required': ['DeviceIndex',
12446 'MACAddress',
12447 'CIDR',
12448 'MTU',
12449 'ProviderId',
12450 'ProviderSubnetId',
12451 'ProviderSpaceId',
12452 'ProviderAddressId',
12453 'ProviderVLANId',
12454 'VLANTag',
12455 'InterfaceName',
12456 'ParentInterfaceName',
12457 'InterfaceType',
12458 'Disabled'],
12459 'type': 'object'},
12460 'NotifyWatchResult': {'additionalProperties': False,
12461 'properties': {'Error': {'$ref': '#/definitions/Error'},
12462 'NotifyWatcherId': {'type': 'string'}},
12463 'required': ['NotifyWatcherId', 'Error'],
12464 'type': 'object'},
12465 'NotifyWatchResults': {'additionalProperties': False,
12466 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
12467 'type': 'array'}},
12468 'required': ['Results'],
12469 'type': 'object'},
12470 'SetMachineNetworkConfig': {'additionalProperties': False,
12471 'properties': {'Config': {'items': {'$ref': '#/definitions/NetworkConfig'},
12472 'type': 'array'},
12473 'Tag': {'type': 'string'}},
12474 'required': ['Tag', 'Config'],
12475 'type': 'object'},
12476 'SetMachinesAddresses': {'additionalProperties': False,
12477 'properties': {'MachineAddresses': {'items': {'$ref': '#/definitions/MachineAddresses'},
12478 'type': 'array'}},
12479 'required': ['MachineAddresses'],
12480 'type': 'object'},
12481 'SetStatus': {'additionalProperties': False,
12482 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
12483 'type': 'array'}},
12484 'required': ['Entities'],
12485 'type': 'object'},
12486 'StringResult': {'additionalProperties': False,
12487 'properties': {'Error': {'$ref': '#/definitions/Error'},
12488 'Result': {'type': 'string'}},
12489 'required': ['Error', 'Result'],
12490 'type': 'object'},
12491 'StringsResult': {'additionalProperties': False,
12492 'properties': {'Error': {'$ref': '#/definitions/Error'},
12493 'Result': {'items': {'type': 'string'},
12494 'type': 'array'}},
12495 'required': ['Error', 'Result'],
12496 'type': 'object'},
12497 'caveat': {'additionalProperties': False,
12498 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
12499 'location': {'$ref': '#/definitions/packet'},
12500 'verificationId': {'$ref': '#/definitions/packet'}},
12501 'required': ['location',
12502 'caveatId',
12503 'verificationId'],
12504 'type': 'object'},
12505 'packet': {'additionalProperties': False,
12506 'properties': {'headerLen': {'type': 'integer'},
12507 'start': {'type': 'integer'},
12508 'totalLen': {'type': 'integer'}},
12509 'required': ['start', 'totalLen', 'headerLen'],
12510 'type': 'object'}},
12511 'properties': {'APIAddresses': {'properties': {'Result': {'$ref': '#/definitions/StringsResult'}},
12512 'type': 'object'},
12513 'APIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/APIHostPortsResult'}},
12514 'type': 'object'},
12515 'CACert': {'properties': {'Result': {'$ref': '#/definitions/BytesResult'}},
12516 'type': 'object'},
12517 'EnsureDead': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12518 'Result': {'$ref': '#/definitions/ErrorResults'}},
12519 'type': 'object'},
12520 'Jobs': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12521 'Result': {'$ref': '#/definitions/JobsResults'}},
12522 'type': 'object'},
12523 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12524 'Result': {'$ref': '#/definitions/LifeResults'}},
12525 'type': 'object'},
12526 'ModelUUID': {'properties': {'Result': {'$ref': '#/definitions/StringResult'}},
12527 'type': 'object'},
12528 'SetMachineAddresses': {'properties': {'Params': {'$ref': '#/definitions/SetMachinesAddresses'},
12529 'Result': {'$ref': '#/definitions/ErrorResults'}},
12530 'type': 'object'},
12531 'SetObservedNetworkConfig': {'properties': {'Params': {'$ref': '#/definitions/SetMachineNetworkConfig'}},
12532 'type': 'object'},
12533 'SetProviderNetworkConfig': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12534 'Result': {'$ref': '#/definitions/ErrorResults'}},
12535 'type': 'object'},
12536 'SetStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
12537 'Result': {'$ref': '#/definitions/ErrorResults'}},
12538 'type': 'object'},
12539 'UpdateStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
12540 'Result': {'$ref': '#/definitions/ErrorResults'}},
12541 'type': 'object'},
12542 'Watch': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12543 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
12544 'type': 'object'},
12545 'WatchAPIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
12546 'type': 'object'}},
12547 'type': 'object'}
12548
12549
12550 @ReturnMapping(StringsResult)
12551 async def APIAddresses(self):
12552 '''
12553
12554 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[str]]
12555 '''
12556 # map input types to rpc msg
12557 params = dict()
12558 msg = dict(Type='Machiner', Request='APIAddresses', Version=1, Params=params)
12559
12560 reply = await self.rpc(msg)
12561 return reply
12562
12563
12564
12565 @ReturnMapping(APIHostPortsResult)
12566 async def APIHostPorts(self):
12567 '''
12568
12569 Returns -> typing.Sequence[~HostPort]
12570 '''
12571 # map input types to rpc msg
12572 params = dict()
12573 msg = dict(Type='Machiner', Request='APIHostPorts', Version=1, Params=params)
12574
12575 reply = await self.rpc(msg)
12576 return reply
12577
12578
12579
12580 @ReturnMapping(BytesResult)
12581 async def CACert(self):
12582 '''
12583
12584 Returns -> typing.Sequence[int]
12585 '''
12586 # map input types to rpc msg
12587 params = dict()
12588 msg = dict(Type='Machiner', Request='CACert', Version=1, Params=params)
12589
12590 reply = await self.rpc(msg)
12591 return reply
12592
12593
12594
12595 @ReturnMapping(ErrorResults)
12596 async def EnsureDead(self, entities):
12597 '''
12598 entities : typing.Sequence[~Entity]
12599 Returns -> typing.Sequence[~ErrorResult]
12600 '''
12601 # map input types to rpc msg
12602 params = dict()
12603 msg = dict(Type='Machiner', Request='EnsureDead', Version=1, Params=params)
12604 params['Entities'] = entities
12605 reply = await self.rpc(msg)
12606 return reply
12607
12608
12609
12610 @ReturnMapping(JobsResults)
12611 async def Jobs(self, entities):
12612 '''
12613 entities : typing.Sequence[~Entity]
12614 Returns -> typing.Sequence[~JobsResult]
12615 '''
12616 # map input types to rpc msg
12617 params = dict()
12618 msg = dict(Type='Machiner', Request='Jobs', Version=1, Params=params)
12619 params['Entities'] = entities
12620 reply = await self.rpc(msg)
12621 return reply
12622
12623
12624
12625 @ReturnMapping(LifeResults)
12626 async def Life(self, entities):
12627 '''
12628 entities : typing.Sequence[~Entity]
12629 Returns -> typing.Sequence[~LifeResult]
12630 '''
12631 # map input types to rpc msg
12632 params = dict()
12633 msg = dict(Type='Machiner', Request='Life', Version=1, Params=params)
12634 params['Entities'] = entities
12635 reply = await self.rpc(msg)
12636 return reply
12637
12638
12639
12640 @ReturnMapping(StringResult)
12641 async def ModelUUID(self):
12642 '''
12643
12644 Returns -> typing.Union[_ForwardRef('Error'), str]
12645 '''
12646 # map input types to rpc msg
12647 params = dict()
12648 msg = dict(Type='Machiner', Request='ModelUUID', Version=1, Params=params)
12649
12650 reply = await self.rpc(msg)
12651 return reply
12652
12653
12654
12655 @ReturnMapping(ErrorResults)
12656 async def SetMachineAddresses(self, machineaddresses):
12657 '''
12658 machineaddresses : typing.Sequence[~MachineAddresses]
12659 Returns -> typing.Sequence[~ErrorResult]
12660 '''
12661 # map input types to rpc msg
12662 params = dict()
12663 msg = dict(Type='Machiner', Request='SetMachineAddresses', Version=1, Params=params)
12664 params['MachineAddresses'] = machineaddresses
12665 reply = await self.rpc(msg)
12666 return reply
12667
12668
12669
12670 @ReturnMapping(None)
12671 async def SetObservedNetworkConfig(self, config, tag):
12672 '''
12673 config : typing.Sequence[~NetworkConfig]
12674 tag : str
12675 Returns -> None
12676 '''
12677 # map input types to rpc msg
12678 params = dict()
12679 msg = dict(Type='Machiner', Request='SetObservedNetworkConfig', Version=1, Params=params)
12680 params['Config'] = config
12681 params['Tag'] = tag
12682 reply = await self.rpc(msg)
12683 return reply
12684
12685
12686
12687 @ReturnMapping(ErrorResults)
12688 async def SetProviderNetworkConfig(self, entities):
12689 '''
12690 entities : typing.Sequence[~Entity]
12691 Returns -> typing.Sequence[~ErrorResult]
12692 '''
12693 # map input types to rpc msg
12694 params = dict()
12695 msg = dict(Type='Machiner', Request='SetProviderNetworkConfig', Version=1, Params=params)
12696 params['Entities'] = entities
12697 reply = await self.rpc(msg)
12698 return reply
12699
12700
12701
12702 @ReturnMapping(ErrorResults)
12703 async def SetStatus(self, entities):
12704 '''
12705 entities : typing.Sequence[~EntityStatusArgs]
12706 Returns -> typing.Sequence[~ErrorResult]
12707 '''
12708 # map input types to rpc msg
12709 params = dict()
12710 msg = dict(Type='Machiner', Request='SetStatus', Version=1, Params=params)
12711 params['Entities'] = entities
12712 reply = await self.rpc(msg)
12713 return reply
12714
12715
12716
12717 @ReturnMapping(ErrorResults)
12718 async def UpdateStatus(self, entities):
12719 '''
12720 entities : typing.Sequence[~EntityStatusArgs]
12721 Returns -> typing.Sequence[~ErrorResult]
12722 '''
12723 # map input types to rpc msg
12724 params = dict()
12725 msg = dict(Type='Machiner', Request='UpdateStatus', Version=1, Params=params)
12726 params['Entities'] = entities
12727 reply = await self.rpc(msg)
12728 return reply
12729
12730
12731
12732 @ReturnMapping(NotifyWatchResults)
12733 async def Watch(self, entities):
12734 '''
12735 entities : typing.Sequence[~Entity]
12736 Returns -> typing.Sequence[~NotifyWatchResult]
12737 '''
12738 # map input types to rpc msg
12739 params = dict()
12740 msg = dict(Type='Machiner', Request='Watch', Version=1, Params=params)
12741 params['Entities'] = entities
12742 reply = await self.rpc(msg)
12743 return reply
12744
12745
12746
12747 @ReturnMapping(NotifyWatchResult)
12748 async def WatchAPIHostPorts(self):
12749 '''
12750
12751 Returns -> typing.Union[_ForwardRef('Error'), str]
12752 '''
12753 # map input types to rpc msg
12754 params = dict()
12755 msg = dict(Type='Machiner', Request='WatchAPIHostPorts', Version=1, Params=params)
12756
12757 reply = await self.rpc(msg)
12758 return reply
12759
12760
12761 class MeterStatusFacade(Type):
12762 name = 'MeterStatus'
12763 version = 1
12764 schema = {'definitions': {'Entities': {'additionalProperties': False,
12765 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
12766 'type': 'array'}},
12767 'required': ['Entities'],
12768 'type': 'object'},
12769 'Entity': {'additionalProperties': False,
12770 'properties': {'Tag': {'type': 'string'}},
12771 'required': ['Tag'],
12772 'type': 'object'},
12773 'Error': {'additionalProperties': False,
12774 'properties': {'Code': {'type': 'string'},
12775 'Info': {'$ref': '#/definitions/ErrorInfo'},
12776 'Message': {'type': 'string'}},
12777 'required': ['Message', 'Code'],
12778 'type': 'object'},
12779 'ErrorInfo': {'additionalProperties': False,
12780 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
12781 'MacaroonPath': {'type': 'string'}},
12782 'type': 'object'},
12783 'Macaroon': {'additionalProperties': False,
12784 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
12785 'type': 'array'},
12786 'data': {'items': {'type': 'integer'},
12787 'type': 'array'},
12788 'id': {'$ref': '#/definitions/packet'},
12789 'location': {'$ref': '#/definitions/packet'},
12790 'sig': {'items': {'type': 'integer'},
12791 'type': 'array'}},
12792 'required': ['data',
12793 'location',
12794 'id',
12795 'caveats',
12796 'sig'],
12797 'type': 'object'},
12798 'MeterStatusResult': {'additionalProperties': False,
12799 'properties': {'Code': {'type': 'string'},
12800 'Error': {'$ref': '#/definitions/Error'},
12801 'Info': {'type': 'string'}},
12802 'required': ['Code', 'Info', 'Error'],
12803 'type': 'object'},
12804 'MeterStatusResults': {'additionalProperties': False,
12805 'properties': {'Results': {'items': {'$ref': '#/definitions/MeterStatusResult'},
12806 'type': 'array'}},
12807 'required': ['Results'],
12808 'type': 'object'},
12809 'NotifyWatchResult': {'additionalProperties': False,
12810 'properties': {'Error': {'$ref': '#/definitions/Error'},
12811 'NotifyWatcherId': {'type': 'string'}},
12812 'required': ['NotifyWatcherId', 'Error'],
12813 'type': 'object'},
12814 'NotifyWatchResults': {'additionalProperties': False,
12815 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
12816 'type': 'array'}},
12817 'required': ['Results'],
12818 'type': 'object'},
12819 'caveat': {'additionalProperties': False,
12820 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
12821 'location': {'$ref': '#/definitions/packet'},
12822 'verificationId': {'$ref': '#/definitions/packet'}},
12823 'required': ['location',
12824 'caveatId',
12825 'verificationId'],
12826 'type': 'object'},
12827 'packet': {'additionalProperties': False,
12828 'properties': {'headerLen': {'type': 'integer'},
12829 'start': {'type': 'integer'},
12830 'totalLen': {'type': 'integer'}},
12831 'required': ['start', 'totalLen', 'headerLen'],
12832 'type': 'object'}},
12833 'properties': {'GetMeterStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12834 'Result': {'$ref': '#/definitions/MeterStatusResults'}},
12835 'type': 'object'},
12836 'WatchMeterStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
12837 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
12838 'type': 'object'}},
12839 'type': 'object'}
12840
12841
12842 @ReturnMapping(MeterStatusResults)
12843 async def GetMeterStatus(self, entities):
12844 '''
12845 entities : typing.Sequence[~Entity]
12846 Returns -> typing.Sequence[~MeterStatusResult]
12847 '''
12848 # map input types to rpc msg
12849 params = dict()
12850 msg = dict(Type='MeterStatus', Request='GetMeterStatus', Version=1, Params=params)
12851 params['Entities'] = entities
12852 reply = await self.rpc(msg)
12853 return reply
12854
12855
12856
12857 @ReturnMapping(NotifyWatchResults)
12858 async def WatchMeterStatus(self, entities):
12859 '''
12860 entities : typing.Sequence[~Entity]
12861 Returns -> typing.Sequence[~NotifyWatchResult]
12862 '''
12863 # map input types to rpc msg
12864 params = dict()
12865 msg = dict(Type='MeterStatus', Request='WatchMeterStatus', Version=1, Params=params)
12866 params['Entities'] = entities
12867 reply = await self.rpc(msg)
12868 return reply
12869
12870
12871 class MetricsAdderFacade(Type):
12872 name = 'MetricsAdder'
12873 version = 2
12874 schema = {'definitions': {'Error': {'additionalProperties': False,
12875 'properties': {'Code': {'type': 'string'},
12876 'Info': {'$ref': '#/definitions/ErrorInfo'},
12877 'Message': {'type': 'string'}},
12878 'required': ['Message', 'Code'],
12879 'type': 'object'},
12880 'ErrorInfo': {'additionalProperties': False,
12881 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
12882 'MacaroonPath': {'type': 'string'}},
12883 'type': 'object'},
12884 'ErrorResult': {'additionalProperties': False,
12885 'properties': {'Error': {'$ref': '#/definitions/Error'}},
12886 'required': ['Error'],
12887 'type': 'object'},
12888 'ErrorResults': {'additionalProperties': False,
12889 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
12890 'type': 'array'}},
12891 'required': ['Results'],
12892 'type': 'object'},
12893 'Macaroon': {'additionalProperties': False,
12894 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
12895 'type': 'array'},
12896 'data': {'items': {'type': 'integer'},
12897 'type': 'array'},
12898 'id': {'$ref': '#/definitions/packet'},
12899 'location': {'$ref': '#/definitions/packet'},
12900 'sig': {'items': {'type': 'integer'},
12901 'type': 'array'}},
12902 'required': ['data',
12903 'location',
12904 'id',
12905 'caveats',
12906 'sig'],
12907 'type': 'object'},
12908 'Metric': {'additionalProperties': False,
12909 'properties': {'Key': {'type': 'string'},
12910 'Time': {'format': 'date-time',
12911 'type': 'string'},
12912 'Value': {'type': 'string'}},
12913 'required': ['Key', 'Value', 'Time'],
12914 'type': 'object'},
12915 'MetricBatch': {'additionalProperties': False,
12916 'properties': {'CharmURL': {'type': 'string'},
12917 'Created': {'format': 'date-time',
12918 'type': 'string'},
12919 'Metrics': {'items': {'$ref': '#/definitions/Metric'},
12920 'type': 'array'},
12921 'UUID': {'type': 'string'}},
12922 'required': ['UUID',
12923 'CharmURL',
12924 'Created',
12925 'Metrics'],
12926 'type': 'object'},
12927 'MetricBatchParam': {'additionalProperties': False,
12928 'properties': {'Batch': {'$ref': '#/definitions/MetricBatch'},
12929 'Tag': {'type': 'string'}},
12930 'required': ['Tag', 'Batch'],
12931 'type': 'object'},
12932 'MetricBatchParams': {'additionalProperties': False,
12933 'properties': {'Batches': {'items': {'$ref': '#/definitions/MetricBatchParam'},
12934 'type': 'array'}},
12935 'required': ['Batches'],
12936 'type': 'object'},
12937 'caveat': {'additionalProperties': False,
12938 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
12939 'location': {'$ref': '#/definitions/packet'},
12940 'verificationId': {'$ref': '#/definitions/packet'}},
12941 'required': ['location',
12942 'caveatId',
12943 'verificationId'],
12944 'type': 'object'},
12945 'packet': {'additionalProperties': False,
12946 'properties': {'headerLen': {'type': 'integer'},
12947 'start': {'type': 'integer'},
12948 'totalLen': {'type': 'integer'}},
12949 'required': ['start', 'totalLen', 'headerLen'],
12950 'type': 'object'}},
12951 'properties': {'AddMetricBatches': {'properties': {'Params': {'$ref': '#/definitions/MetricBatchParams'},
12952 'Result': {'$ref': '#/definitions/ErrorResults'}},
12953 'type': 'object'}},
12954 'type': 'object'}
12955
12956
12957 @ReturnMapping(ErrorResults)
12958 async def AddMetricBatches(self, batches):
12959 '''
12960 batches : typing.Sequence[~MetricBatchParam]
12961 Returns -> typing.Sequence[~ErrorResult]
12962 '''
12963 # map input types to rpc msg
12964 params = dict()
12965 msg = dict(Type='MetricsAdder', Request='AddMetricBatches', Version=2, Params=params)
12966 params['Batches'] = batches
12967 reply = await self.rpc(msg)
12968 return reply
12969
12970
12971 class MetricsDebugFacade(Type):
12972 name = 'MetricsDebug'
12973 version = 2
12974 schema = {'definitions': {'Entities': {'additionalProperties': False,
12975 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
12976 'type': 'array'}},
12977 'required': ['Entities'],
12978 'type': 'object'},
12979 'Entity': {'additionalProperties': False,
12980 'properties': {'Tag': {'type': 'string'}},
12981 'required': ['Tag'],
12982 'type': 'object'},
12983 'EntityMetrics': {'additionalProperties': False,
12984 'properties': {'error': {'$ref': '#/definitions/Error'},
12985 'metrics': {'items': {'$ref': '#/definitions/MetricResult'},
12986 'type': 'array'}},
12987 'type': 'object'},
12988 'Error': {'additionalProperties': False,
12989 'properties': {'Code': {'type': 'string'},
12990 'Info': {'$ref': '#/definitions/ErrorInfo'},
12991 'Message': {'type': 'string'}},
12992 'required': ['Message', 'Code'],
12993 'type': 'object'},
12994 'ErrorInfo': {'additionalProperties': False,
12995 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
12996 'MacaroonPath': {'type': 'string'}},
12997 'type': 'object'},
12998 'ErrorResult': {'additionalProperties': False,
12999 'properties': {'Error': {'$ref': '#/definitions/Error'}},
13000 'required': ['Error'],
13001 'type': 'object'},
13002 'ErrorResults': {'additionalProperties': False,
13003 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
13004 'type': 'array'}},
13005 'required': ['Results'],
13006 'type': 'object'},
13007 'Macaroon': {'additionalProperties': False,
13008 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
13009 'type': 'array'},
13010 'data': {'items': {'type': 'integer'},
13011 'type': 'array'},
13012 'id': {'$ref': '#/definitions/packet'},
13013 'location': {'$ref': '#/definitions/packet'},
13014 'sig': {'items': {'type': 'integer'},
13015 'type': 'array'}},
13016 'required': ['data',
13017 'location',
13018 'id',
13019 'caveats',
13020 'sig'],
13021 'type': 'object'},
13022 'MeterStatusParam': {'additionalProperties': False,
13023 'properties': {'code': {'type': 'string'},
13024 'info': {'type': 'string'},
13025 'tag': {'type': 'string'}},
13026 'required': ['tag', 'code', 'info'],
13027 'type': 'object'},
13028 'MeterStatusParams': {'additionalProperties': False,
13029 'properties': {'statues': {'items': {'$ref': '#/definitions/MeterStatusParam'},
13030 'type': 'array'}},
13031 'required': ['statues'],
13032 'type': 'object'},
13033 'MetricResult': {'additionalProperties': False,
13034 'properties': {'key': {'type': 'string'},
13035 'time': {'format': 'date-time',
13036 'type': 'string'},
13037 'value': {'type': 'string'}},
13038 'required': ['time', 'key', 'value'],
13039 'type': 'object'},
13040 'MetricResults': {'additionalProperties': False,
13041 'properties': {'results': {'items': {'$ref': '#/definitions/EntityMetrics'},
13042 'type': 'array'}},
13043 'required': ['results'],
13044 'type': 'object'},
13045 'caveat': {'additionalProperties': False,
13046 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
13047 'location': {'$ref': '#/definitions/packet'},
13048 'verificationId': {'$ref': '#/definitions/packet'}},
13049 'required': ['location',
13050 'caveatId',
13051 'verificationId'],
13052 'type': 'object'},
13053 'packet': {'additionalProperties': False,
13054 'properties': {'headerLen': {'type': 'integer'},
13055 'start': {'type': 'integer'},
13056 'totalLen': {'type': 'integer'}},
13057 'required': ['start', 'totalLen', 'headerLen'],
13058 'type': 'object'}},
13059 'properties': {'GetMetrics': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
13060 'Result': {'$ref': '#/definitions/MetricResults'}},
13061 'type': 'object'},
13062 'SetMeterStatus': {'properties': {'Params': {'$ref': '#/definitions/MeterStatusParams'},
13063 'Result': {'$ref': '#/definitions/ErrorResults'}},
13064 'type': 'object'}},
13065 'type': 'object'}
13066
13067
13068 @ReturnMapping(MetricResults)
13069 async def GetMetrics(self, entities):
13070 '''
13071 entities : typing.Sequence[~Entity]
13072 Returns -> typing.Sequence[~EntityMetrics]
13073 '''
13074 # map input types to rpc msg
13075 params = dict()
13076 msg = dict(Type='MetricsDebug', Request='GetMetrics', Version=2, Params=params)
13077 params['Entities'] = entities
13078 reply = await self.rpc(msg)
13079 return reply
13080
13081
13082
13083 @ReturnMapping(ErrorResults)
13084 async def SetMeterStatus(self, statues):
13085 '''
13086 statues : typing.Sequence[~MeterStatusParam]
13087 Returns -> typing.Sequence[~ErrorResult]
13088 '''
13089 # map input types to rpc msg
13090 params = dict()
13091 msg = dict(Type='MetricsDebug', Request='SetMeterStatus', Version=2, Params=params)
13092 params['statues'] = statues
13093 reply = await self.rpc(msg)
13094 return reply
13095
13096
13097 class MetricsManagerFacade(Type):
13098 name = 'MetricsManager'
13099 version = 1
13100 schema = {'definitions': {'Entities': {'additionalProperties': False,
13101 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
13102 'type': 'array'}},
13103 'required': ['Entities'],
13104 'type': 'object'},
13105 'Entity': {'additionalProperties': False,
13106 'properties': {'Tag': {'type': 'string'}},
13107 'required': ['Tag'],
13108 'type': 'object'},
13109 'Error': {'additionalProperties': False,
13110 'properties': {'Code': {'type': 'string'},
13111 'Info': {'$ref': '#/definitions/ErrorInfo'},
13112 'Message': {'type': 'string'}},
13113 'required': ['Message', 'Code'],
13114 'type': 'object'},
13115 'ErrorInfo': {'additionalProperties': False,
13116 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
13117 'MacaroonPath': {'type': 'string'}},
13118 'type': 'object'},
13119 'ErrorResult': {'additionalProperties': False,
13120 'properties': {'Error': {'$ref': '#/definitions/Error'}},
13121 'required': ['Error'],
13122 'type': 'object'},
13123 'ErrorResults': {'additionalProperties': False,
13124 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
13125 'type': 'array'}},
13126 'required': ['Results'],
13127 'type': 'object'},
13128 'Macaroon': {'additionalProperties': False,
13129 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
13130 'type': 'array'},
13131 'data': {'items': {'type': 'integer'},
13132 'type': 'array'},
13133 'id': {'$ref': '#/definitions/packet'},
13134 'location': {'$ref': '#/definitions/packet'},
13135 'sig': {'items': {'type': 'integer'},
13136 'type': 'array'}},
13137 'required': ['data',
13138 'location',
13139 'id',
13140 'caveats',
13141 'sig'],
13142 'type': 'object'},
13143 'caveat': {'additionalProperties': False,
13144 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
13145 'location': {'$ref': '#/definitions/packet'},
13146 'verificationId': {'$ref': '#/definitions/packet'}},
13147 'required': ['location',
13148 'caveatId',
13149 'verificationId'],
13150 'type': 'object'},
13151 'packet': {'additionalProperties': False,
13152 'properties': {'headerLen': {'type': 'integer'},
13153 'start': {'type': 'integer'},
13154 'totalLen': {'type': 'integer'}},
13155 'required': ['start', 'totalLen', 'headerLen'],
13156 'type': 'object'}},
13157 'properties': {'CleanupOldMetrics': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
13158 'Result': {'$ref': '#/definitions/ErrorResults'}},
13159 'type': 'object'},
13160 'SendMetrics': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
13161 'Result': {'$ref': '#/definitions/ErrorResults'}},
13162 'type': 'object'}},
13163 'type': 'object'}
13164
13165
13166 @ReturnMapping(ErrorResults)
13167 async def CleanupOldMetrics(self, entities):
13168 '''
13169 entities : typing.Sequence[~Entity]
13170 Returns -> typing.Sequence[~ErrorResult]
13171 '''
13172 # map input types to rpc msg
13173 params = dict()
13174 msg = dict(Type='MetricsManager', Request='CleanupOldMetrics', Version=1, Params=params)
13175 params['Entities'] = entities
13176 reply = await self.rpc(msg)
13177 return reply
13178
13179
13180
13181 @ReturnMapping(ErrorResults)
13182 async def SendMetrics(self, entities):
13183 '''
13184 entities : typing.Sequence[~Entity]
13185 Returns -> typing.Sequence[~ErrorResult]
13186 '''
13187 # map input types to rpc msg
13188 params = dict()
13189 msg = dict(Type='MetricsManager', Request='SendMetrics', Version=1, Params=params)
13190 params['Entities'] = entities
13191 reply = await self.rpc(msg)
13192 return reply
13193
13194
13195 class MigrationFlagFacade(Type):
13196 name = 'MigrationFlag'
13197 version = 1
13198 schema = {'definitions': {'Entities': {'additionalProperties': False,
13199 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
13200 'type': 'array'}},
13201 'required': ['Entities'],
13202 'type': 'object'},
13203 'Entity': {'additionalProperties': False,
13204 'properties': {'Tag': {'type': 'string'}},
13205 'required': ['Tag'],
13206 'type': 'object'},
13207 'Error': {'additionalProperties': False,
13208 'properties': {'Code': {'type': 'string'},
13209 'Info': {'$ref': '#/definitions/ErrorInfo'},
13210 'Message': {'type': 'string'}},
13211 'required': ['Message', 'Code'],
13212 'type': 'object'},
13213 'ErrorInfo': {'additionalProperties': False,
13214 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
13215 'MacaroonPath': {'type': 'string'}},
13216 'type': 'object'},
13217 'Macaroon': {'additionalProperties': False,
13218 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
13219 'type': 'array'},
13220 'data': {'items': {'type': 'integer'},
13221 'type': 'array'},
13222 'id': {'$ref': '#/definitions/packet'},
13223 'location': {'$ref': '#/definitions/packet'},
13224 'sig': {'items': {'type': 'integer'},
13225 'type': 'array'}},
13226 'required': ['data',
13227 'location',
13228 'id',
13229 'caveats',
13230 'sig'],
13231 'type': 'object'},
13232 'NotifyWatchResult': {'additionalProperties': False,
13233 'properties': {'Error': {'$ref': '#/definitions/Error'},
13234 'NotifyWatcherId': {'type': 'string'}},
13235 'required': ['NotifyWatcherId', 'Error'],
13236 'type': 'object'},
13237 'NotifyWatchResults': {'additionalProperties': False,
13238 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
13239 'type': 'array'}},
13240 'required': ['Results'],
13241 'type': 'object'},
13242 'PhaseResult': {'additionalProperties': False,
13243 'properties': {'Error': {'$ref': '#/definitions/Error'},
13244 'phase': {'type': 'string'}},
13245 'required': ['phase', 'Error'],
13246 'type': 'object'},
13247 'PhaseResults': {'additionalProperties': False,
13248 'properties': {'Results': {'items': {'$ref': '#/definitions/PhaseResult'},
13249 'type': 'array'}},
13250 'required': ['Results'],
13251 'type': 'object'},
13252 'caveat': {'additionalProperties': False,
13253 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
13254 'location': {'$ref': '#/definitions/packet'},
13255 'verificationId': {'$ref': '#/definitions/packet'}},
13256 'required': ['location',
13257 'caveatId',
13258 'verificationId'],
13259 'type': 'object'},
13260 'packet': {'additionalProperties': False,
13261 'properties': {'headerLen': {'type': 'integer'},
13262 'start': {'type': 'integer'},
13263 'totalLen': {'type': 'integer'}},
13264 'required': ['start', 'totalLen', 'headerLen'],
13265 'type': 'object'}},
13266 'properties': {'Phase': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
13267 'Result': {'$ref': '#/definitions/PhaseResults'}},
13268 'type': 'object'},
13269 'Watch': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
13270 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
13271 'type': 'object'}},
13272 'type': 'object'}
13273
13274
13275 @ReturnMapping(PhaseResults)
13276 async def Phase(self, entities):
13277 '''
13278 entities : typing.Sequence[~Entity]
13279 Returns -> typing.Sequence[~PhaseResult]
13280 '''
13281 # map input types to rpc msg
13282 params = dict()
13283 msg = dict(Type='MigrationFlag', Request='Phase', Version=1, Params=params)
13284 params['Entities'] = entities
13285 reply = await self.rpc(msg)
13286 return reply
13287
13288
13289
13290 @ReturnMapping(NotifyWatchResults)
13291 async def Watch(self, entities):
13292 '''
13293 entities : typing.Sequence[~Entity]
13294 Returns -> typing.Sequence[~NotifyWatchResult]
13295 '''
13296 # map input types to rpc msg
13297 params = dict()
13298 msg = dict(Type='MigrationFlag', Request='Watch', Version=1, Params=params)
13299 params['Entities'] = entities
13300 reply = await self.rpc(msg)
13301 return reply
13302
13303
13304 class MigrationMasterFacade(Type):
13305 name = 'MigrationMaster'
13306 version = 1
13307 schema = {'definitions': {'Error': {'additionalProperties': False,
13308 'properties': {'Code': {'type': 'string'},
13309 'Info': {'$ref': '#/definitions/ErrorInfo'},
13310 'Message': {'type': 'string'}},
13311 'required': ['Message', 'Code'],
13312 'type': 'object'},
13313 'ErrorInfo': {'additionalProperties': False,
13314 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
13315 'MacaroonPath': {'type': 'string'}},
13316 'type': 'object'},
13317 'FullMigrationStatus': {'additionalProperties': False,
13318 'properties': {'attempt': {'type': 'integer'},
13319 'phase': {'type': 'string'},
13320 'spec': {'$ref': '#/definitions/ModelMigrationSpec'}},
13321 'required': ['spec',
13322 'attempt',
13323 'phase'],
13324 'type': 'object'},
13325 'Macaroon': {'additionalProperties': False,
13326 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
13327 'type': 'array'},
13328 'data': {'items': {'type': 'integer'},
13329 'type': 'array'},
13330 'id': {'$ref': '#/definitions/packet'},
13331 'location': {'$ref': '#/definitions/packet'},
13332 'sig': {'items': {'type': 'integer'},
13333 'type': 'array'}},
13334 'required': ['data',
13335 'location',
13336 'id',
13337 'caveats',
13338 'sig'],
13339 'type': 'object'},
13340 'ModelMigrationSpec': {'additionalProperties': False,
13341 'properties': {'model-tag': {'type': 'string'},
13342 'target-info': {'$ref': '#/definitions/ModelMigrationTargetInfo'}},
13343 'required': ['model-tag',
13344 'target-info'],
13345 'type': 'object'},
13346 'ModelMigrationTargetInfo': {'additionalProperties': False,
13347 'properties': {'addrs': {'items': {'type': 'string'},
13348 'type': 'array'},
13349 'auth-tag': {'type': 'string'},
13350 'ca-cert': {'type': 'string'},
13351 'controller-tag': {'type': 'string'},
13352 'password': {'type': 'string'}},
13353 'required': ['controller-tag',
13354 'addrs',
13355 'ca-cert',
13356 'auth-tag',
13357 'password'],
13358 'type': 'object'},
13359 'NotifyWatchResult': {'additionalProperties': False,
13360 'properties': {'Error': {'$ref': '#/definitions/Error'},
13361 'NotifyWatcherId': {'type': 'string'}},
13362 'required': ['NotifyWatcherId', 'Error'],
13363 'type': 'object'},
13364 'SerializedModel': {'additionalProperties': False,
13365 'properties': {'bytes': {'items': {'type': 'integer'},
13366 'type': 'array'}},
13367 'required': ['bytes'],
13368 'type': 'object'},
13369 'SetMigrationPhaseArgs': {'additionalProperties': False,
13370 'properties': {'phase': {'type': 'string'}},
13371 'required': ['phase'],
13372 'type': 'object'},
13373 'caveat': {'additionalProperties': False,
13374 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
13375 'location': {'$ref': '#/definitions/packet'},
13376 'verificationId': {'$ref': '#/definitions/packet'}},
13377 'required': ['location',
13378 'caveatId',
13379 'verificationId'],
13380 'type': 'object'},
13381 'packet': {'additionalProperties': False,
13382 'properties': {'headerLen': {'type': 'integer'},
13383 'start': {'type': 'integer'},
13384 'totalLen': {'type': 'integer'}},
13385 'required': ['start', 'totalLen', 'headerLen'],
13386 'type': 'object'}},
13387 'properties': {'Export': {'properties': {'Result': {'$ref': '#/definitions/SerializedModel'}},
13388 'type': 'object'},
13389 'GetMigrationStatus': {'properties': {'Result': {'$ref': '#/definitions/FullMigrationStatus'}},
13390 'type': 'object'},
13391 'SetPhase': {'properties': {'Params': {'$ref': '#/definitions/SetMigrationPhaseArgs'}},
13392 'type': 'object'},
13393 'Watch': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
13394 'type': 'object'}},
13395 'type': 'object'}
13396
13397
13398 @ReturnMapping(SerializedModel)
13399 async def Export(self):
13400 '''
13401
13402 Returns -> typing.Sequence[int]
13403 '''
13404 # map input types to rpc msg
13405 params = dict()
13406 msg = dict(Type='MigrationMaster', Request='Export', Version=1, Params=params)
13407
13408 reply = await self.rpc(msg)
13409 return reply
13410
13411
13412
13413 @ReturnMapping(FullMigrationStatus)
13414 async def GetMigrationStatus(self):
13415 '''
13416
13417 Returns -> typing.Union[int, str, _ForwardRef('ModelMigrationSpec')]
13418 '''
13419 # map input types to rpc msg
13420 params = dict()
13421 msg = dict(Type='MigrationMaster', Request='GetMigrationStatus', Version=1, Params=params)
13422
13423 reply = await self.rpc(msg)
13424 return reply
13425
13426
13427
13428 @ReturnMapping(None)
13429 async def SetPhase(self, phase):
13430 '''
13431 phase : str
13432 Returns -> None
13433 '''
13434 # map input types to rpc msg
13435 params = dict()
13436 msg = dict(Type='MigrationMaster', Request='SetPhase', Version=1, Params=params)
13437 params['phase'] = phase
13438 reply = await self.rpc(msg)
13439 return reply
13440
13441
13442
13443 @ReturnMapping(NotifyWatchResult)
13444 async def Watch(self):
13445 '''
13446
13447 Returns -> typing.Union[_ForwardRef('Error'), str]
13448 '''
13449 # map input types to rpc msg
13450 params = dict()
13451 msg = dict(Type='MigrationMaster', Request='Watch', Version=1, Params=params)
13452
13453 reply = await self.rpc(msg)
13454 return reply
13455
13456
13457 class MigrationMinionFacade(Type):
13458 name = 'MigrationMinion'
13459 version = 1
13460 schema = {'definitions': {'Error': {'additionalProperties': False,
13461 'properties': {'Code': {'type': 'string'},
13462 'Info': {'$ref': '#/definitions/ErrorInfo'},
13463 'Message': {'type': 'string'}},
13464 'required': ['Message', 'Code'],
13465 'type': 'object'},
13466 'ErrorInfo': {'additionalProperties': False,
13467 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
13468 'MacaroonPath': {'type': 'string'}},
13469 'type': 'object'},
13470 'Macaroon': {'additionalProperties': False,
13471 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
13472 'type': 'array'},
13473 'data': {'items': {'type': 'integer'},
13474 'type': 'array'},
13475 'id': {'$ref': '#/definitions/packet'},
13476 'location': {'$ref': '#/definitions/packet'},
13477 'sig': {'items': {'type': 'integer'},
13478 'type': 'array'}},
13479 'required': ['data',
13480 'location',
13481 'id',
13482 'caveats',
13483 'sig'],
13484 'type': 'object'},
13485 'NotifyWatchResult': {'additionalProperties': False,
13486 'properties': {'Error': {'$ref': '#/definitions/Error'},
13487 'NotifyWatcherId': {'type': 'string'}},
13488 'required': ['NotifyWatcherId', 'Error'],
13489 'type': 'object'},
13490 'caveat': {'additionalProperties': False,
13491 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
13492 'location': {'$ref': '#/definitions/packet'},
13493 'verificationId': {'$ref': '#/definitions/packet'}},
13494 'required': ['location',
13495 'caveatId',
13496 'verificationId'],
13497 'type': 'object'},
13498 'packet': {'additionalProperties': False,
13499 'properties': {'headerLen': {'type': 'integer'},
13500 'start': {'type': 'integer'},
13501 'totalLen': {'type': 'integer'}},
13502 'required': ['start', 'totalLen', 'headerLen'],
13503 'type': 'object'}},
13504 'properties': {'Watch': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
13505 'type': 'object'}},
13506 'type': 'object'}
13507
13508
13509 @ReturnMapping(NotifyWatchResult)
13510 async def Watch(self):
13511 '''
13512
13513 Returns -> typing.Union[_ForwardRef('Error'), str]
13514 '''
13515 # map input types to rpc msg
13516 params = dict()
13517 msg = dict(Type='MigrationMinion', Request='Watch', Version=1, Params=params)
13518
13519 reply = await self.rpc(msg)
13520 return reply
13521
13522
13523 class MigrationStatusWatcherFacade(Type):
13524 name = 'MigrationStatusWatcher'
13525 version = 1
13526 schema = {'definitions': {'MigrationStatus': {'additionalProperties': False,
13527 'properties': {'attempt': {'type': 'integer'},
13528 'phase': {'type': 'string'},
13529 'source-api-addrs': {'items': {'type': 'string'},
13530 'type': 'array'},
13531 'source-ca-cert': {'type': 'string'},
13532 'target-api-addrs': {'items': {'type': 'string'},
13533 'type': 'array'},
13534 'target-ca-cert': {'type': 'string'}},
13535 'required': ['attempt',
13536 'phase',
13537 'source-api-addrs',
13538 'source-ca-cert',
13539 'target-api-addrs',
13540 'target-ca-cert'],
13541 'type': 'object'}},
13542 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/MigrationStatus'}},
13543 'type': 'object'},
13544 'Stop': {'type': 'object'}},
13545 'type': 'object'}
13546
13547
13548 @ReturnMapping(MigrationStatus)
13549 async def Next(self):
13550 '''
13551
13552 Returns -> typing.Union[int, typing.Sequence[str]]
13553 '''
13554 # map input types to rpc msg
13555 params = dict()
13556 msg = dict(Type='MigrationStatusWatcher', Request='Next', Version=1, Params=params)
13557
13558 reply = await self.rpc(msg)
13559 return reply
13560
13561
13562
13563 @ReturnMapping(None)
13564 async def Stop(self):
13565 '''
13566
13567 Returns -> None
13568 '''
13569 # map input types to rpc msg
13570 params = dict()
13571 msg = dict(Type='MigrationStatusWatcher', Request='Stop', Version=1, Params=params)
13572
13573 reply = await self.rpc(msg)
13574 return reply
13575
13576
13577 class MigrationTargetFacade(Type):
13578 name = 'MigrationTarget'
13579 version = 1
13580 schema = {'definitions': {'ModelArgs': {'additionalProperties': False,
13581 'properties': {'model-tag': {'type': 'string'}},
13582 'required': ['model-tag'],
13583 'type': 'object'},
13584 'SerializedModel': {'additionalProperties': False,
13585 'properties': {'bytes': {'items': {'type': 'integer'},
13586 'type': 'array'}},
13587 'required': ['bytes'],
13588 'type': 'object'}},
13589 'properties': {'Abort': {'properties': {'Params': {'$ref': '#/definitions/ModelArgs'}},
13590 'type': 'object'},
13591 'Activate': {'properties': {'Params': {'$ref': '#/definitions/ModelArgs'}},
13592 'type': 'object'},
13593 'Import': {'properties': {'Params': {'$ref': '#/definitions/SerializedModel'}},
13594 'type': 'object'}},
13595 'type': 'object'}
13596
13597
13598 @ReturnMapping(None)
13599 async def Abort(self, model_tag):
13600 '''
13601 model_tag : str
13602 Returns -> None
13603 '''
13604 # map input types to rpc msg
13605 params = dict()
13606 msg = dict(Type='MigrationTarget', Request='Abort', Version=1, Params=params)
13607 params['model-tag'] = model_tag
13608 reply = await self.rpc(msg)
13609 return reply
13610
13611
13612
13613 @ReturnMapping(None)
13614 async def Activate(self, model_tag):
13615 '''
13616 model_tag : str
13617 Returns -> None
13618 '''
13619 # map input types to rpc msg
13620 params = dict()
13621 msg = dict(Type='MigrationTarget', Request='Activate', Version=1, Params=params)
13622 params['model-tag'] = model_tag
13623 reply = await self.rpc(msg)
13624 return reply
13625
13626
13627
13628 @ReturnMapping(None)
13629 async def Import(self, bytes_):
13630 '''
13631 bytes_ : typing.Sequence[int]
13632 Returns -> None
13633 '''
13634 # map input types to rpc msg
13635 params = dict()
13636 msg = dict(Type='MigrationTarget', Request='Import', Version=1, Params=params)
13637 params['bytes'] = bytes_
13638 reply = await self.rpc(msg)
13639 return reply
13640
13641
13642 class ModelManagerFacade(Type):
13643 name = 'ModelManager'
13644 version = 2
13645 schema = {'definitions': {'Entities': {'additionalProperties': False,
13646 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
13647 'type': 'array'}},
13648 'required': ['Entities'],
13649 'type': 'object'},
13650 'Entity': {'additionalProperties': False,
13651 'properties': {'Tag': {'type': 'string'}},
13652 'required': ['Tag'],
13653 'type': 'object'},
13654 'EntityStatus': {'additionalProperties': False,
13655 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
13656 'type': 'object'}},
13657 'type': 'object'},
13658 'Info': {'type': 'string'},
13659 'Since': {'format': 'date-time',
13660 'type': 'string'},
13661 'Status': {'type': 'string'}},
13662 'required': ['Status',
13663 'Info',
13664 'Data',
13665 'Since'],
13666 'type': 'object'},
13667 'Error': {'additionalProperties': False,
13668 'properties': {'Code': {'type': 'string'},
13669 'Info': {'$ref': '#/definitions/ErrorInfo'},
13670 'Message': {'type': 'string'}},
13671 'required': ['Message', 'Code'],
13672 'type': 'object'},
13673 'ErrorInfo': {'additionalProperties': False,
13674 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
13675 'MacaroonPath': {'type': 'string'}},
13676 'type': 'object'},
13677 'ErrorResult': {'additionalProperties': False,
13678 'properties': {'Error': {'$ref': '#/definitions/Error'}},
13679 'required': ['Error'],
13680 'type': 'object'},
13681 'ErrorResults': {'additionalProperties': False,
13682 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
13683 'type': 'array'}},
13684 'required': ['Results'],
13685 'type': 'object'},
13686 'Macaroon': {'additionalProperties': False,
13687 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
13688 'type': 'array'},
13689 'data': {'items': {'type': 'integer'},
13690 'type': 'array'},
13691 'id': {'$ref': '#/definitions/packet'},
13692 'location': {'$ref': '#/definitions/packet'},
13693 'sig': {'items': {'type': 'integer'},
13694 'type': 'array'}},
13695 'required': ['data',
13696 'location',
13697 'id',
13698 'caveats',
13699 'sig'],
13700 'type': 'object'},
13701 'Model': {'additionalProperties': False,
13702 'properties': {'Name': {'type': 'string'},
13703 'OwnerTag': {'type': 'string'},
13704 'UUID': {'type': 'string'}},
13705 'required': ['Name', 'UUID', 'OwnerTag'],
13706 'type': 'object'},
13707 'ModelConfigResult': {'additionalProperties': False,
13708 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
13709 'type': 'object'}},
13710 'type': 'object'}},
13711 'required': ['Config'],
13712 'type': 'object'},
13713 'ModelCreateArgs': {'additionalProperties': False,
13714 'properties': {'Account': {'patternProperties': {'.*': {'additionalProperties': True,
13715 'type': 'object'}},
13716 'type': 'object'},
13717 'Config': {'patternProperties': {'.*': {'additionalProperties': True,
13718 'type': 'object'}},
13719 'type': 'object'},
13720 'OwnerTag': {'type': 'string'}},
13721 'required': ['OwnerTag',
13722 'Account',
13723 'Config'],
13724 'type': 'object'},
13725 'ModelInfo': {'additionalProperties': False,
13726 'properties': {'Cloud': {'type': 'string'},
13727 'DefaultSeries': {'type': 'string'},
13728 'Life': {'type': 'string'},
13729 'Name': {'type': 'string'},
13730 'OwnerTag': {'type': 'string'},
13731 'ProviderType': {'type': 'string'},
13732 'ServerUUID': {'type': 'string'},
13733 'Status': {'$ref': '#/definitions/EntityStatus'},
13734 'UUID': {'type': 'string'},
13735 'Users': {'items': {'$ref': '#/definitions/ModelUserInfo'},
13736 'type': 'array'}},
13737 'required': ['Name',
13738 'UUID',
13739 'ServerUUID',
13740 'ProviderType',
13741 'DefaultSeries',
13742 'Cloud',
13743 'OwnerTag',
13744 'Life',
13745 'Status',
13746 'Users'],
13747 'type': 'object'},
13748 'ModelInfoResult': {'additionalProperties': False,
13749 'properties': {'error': {'$ref': '#/definitions/Error'},
13750 'result': {'$ref': '#/definitions/ModelInfo'}},
13751 'type': 'object'},
13752 'ModelInfoResults': {'additionalProperties': False,
13753 'properties': {'results': {'items': {'$ref': '#/definitions/ModelInfoResult'},
13754 'type': 'array'}},
13755 'required': ['results'],
13756 'type': 'object'},
13757 'ModelSkeletonConfigArgs': {'additionalProperties': False,
13758 'properties': {'Provider': {'type': 'string'},
13759 'Region': {'type': 'string'}},
13760 'required': ['Provider', 'Region'],
13761 'type': 'object'},
13762 'ModelUserInfo': {'additionalProperties': False,
13763 'properties': {'access': {'type': 'string'},
13764 'displayname': {'type': 'string'},
13765 'lastconnection': {'format': 'date-time',
13766 'type': 'string'},
13767 'user': {'type': 'string'}},
13768 'required': ['user',
13769 'displayname',
13770 'lastconnection',
13771 'access'],
13772 'type': 'object'},
13773 'ModifyModelAccess': {'additionalProperties': False,
13774 'properties': {'access': {'type': 'string'},
13775 'action': {'type': 'string'},
13776 'model-tag': {'type': 'string'},
13777 'user-tag': {'type': 'string'}},
13778 'required': ['user-tag',
13779 'action',
13780 'access',
13781 'model-tag'],
13782 'type': 'object'},
13783 'ModifyModelAccessRequest': {'additionalProperties': False,
13784 'properties': {'changes': {'items': {'$ref': '#/definitions/ModifyModelAccess'},
13785 'type': 'array'}},
13786 'required': ['changes'],
13787 'type': 'object'},
13788 'UserModel': {'additionalProperties': False,
13789 'properties': {'LastConnection': {'format': 'date-time',
13790 'type': 'string'},
13791 'Model': {'$ref': '#/definitions/Model'}},
13792 'required': ['Model', 'LastConnection'],
13793 'type': 'object'},
13794 'UserModelList': {'additionalProperties': False,
13795 'properties': {'UserModels': {'items': {'$ref': '#/definitions/UserModel'},
13796 'type': 'array'}},
13797 'required': ['UserModels'],
13798 'type': 'object'},
13799 'caveat': {'additionalProperties': False,
13800 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
13801 'location': {'$ref': '#/definitions/packet'},
13802 'verificationId': {'$ref': '#/definitions/packet'}},
13803 'required': ['location',
13804 'caveatId',
13805 'verificationId'],
13806 'type': 'object'},
13807 'packet': {'additionalProperties': False,
13808 'properties': {'headerLen': {'type': 'integer'},
13809 'start': {'type': 'integer'},
13810 'totalLen': {'type': 'integer'}},
13811 'required': ['start', 'totalLen', 'headerLen'],
13812 'type': 'object'}},
13813 'properties': {'ConfigSkeleton': {'properties': {'Params': {'$ref': '#/definitions/ModelSkeletonConfigArgs'},
13814 'Result': {'$ref': '#/definitions/ModelConfigResult'}},
13815 'type': 'object'},
13816 'CreateModel': {'properties': {'Params': {'$ref': '#/definitions/ModelCreateArgs'},
13817 'Result': {'$ref': '#/definitions/Model'}},
13818 'type': 'object'},
13819 'ListModels': {'properties': {'Params': {'$ref': '#/definitions/Entity'},
13820 'Result': {'$ref': '#/definitions/UserModelList'}},
13821 'type': 'object'},
13822 'ModelInfo': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
13823 'Result': {'$ref': '#/definitions/ModelInfoResults'}},
13824 'type': 'object'},
13825 'ModifyModelAccess': {'properties': {'Params': {'$ref': '#/definitions/ModifyModelAccessRequest'},
13826 'Result': {'$ref': '#/definitions/ErrorResults'}},
13827 'type': 'object'}},
13828 'type': 'object'}
13829
13830
13831 @ReturnMapping(ModelConfigResult)
13832 async def ConfigSkeleton(self, provider, region):
13833 '''
13834 provider : str
13835 region : str
13836 Returns -> typing.Mapping[str, typing.Any]
13837 '''
13838 # map input types to rpc msg
13839 params = dict()
13840 msg = dict(Type='ModelManager', Request='ConfigSkeleton', Version=2, Params=params)
13841 params['Provider'] = provider
13842 params['Region'] = region
13843 reply = await self.rpc(msg)
13844 return reply
13845
13846
13847
13848 @ReturnMapping(Model)
13849 async def CreateModel(self, account, config, ownertag):
13850 '''
13851 account : typing.Mapping[str, typing.Any]
13852 config : typing.Mapping[str, typing.Any]
13853 ownertag : str
13854 Returns -> <class 'str'>
13855 '''
13856 # map input types to rpc msg
13857 params = dict()
13858 msg = dict(Type='ModelManager', Request='CreateModel', Version=2, Params=params)
13859 params['Account'] = account
13860 params['Config'] = config
13861 params['OwnerTag'] = ownertag
13862 reply = await self.rpc(msg)
13863 return reply
13864
13865
13866
13867 @ReturnMapping(UserModelList)
13868 async def ListModels(self, tag):
13869 '''
13870 tag : str
13871 Returns -> typing.Sequence[~UserModel]
13872 '''
13873 # map input types to rpc msg
13874 params = dict()
13875 msg = dict(Type='ModelManager', Request='ListModels', Version=2, Params=params)
13876 params['Tag'] = tag
13877 reply = await self.rpc(msg)
13878 return reply
13879
13880
13881
13882 @ReturnMapping(ModelInfoResults)
13883 async def ModelInfo(self, entities):
13884 '''
13885 entities : typing.Sequence[~Entity]
13886 Returns -> typing.Sequence[~ModelInfoResult]
13887 '''
13888 # map input types to rpc msg
13889 params = dict()
13890 msg = dict(Type='ModelManager', Request='ModelInfo', Version=2, Params=params)
13891 params['Entities'] = entities
13892 reply = await self.rpc(msg)
13893 return reply
13894
13895
13896
13897 @ReturnMapping(ErrorResults)
13898 async def ModifyModelAccess(self, changes):
13899 '''
13900 changes : typing.Sequence[~ModifyModelAccess]
13901 Returns -> typing.Sequence[~ErrorResult]
13902 '''
13903 # map input types to rpc msg
13904 params = dict()
13905 msg = dict(Type='ModelManager', Request='ModifyModelAccess', Version=2, Params=params)
13906 params['changes'] = changes
13907 reply = await self.rpc(msg)
13908 return reply
13909
13910
13911 class NotifyWatcherFacade(Type):
13912 name = 'NotifyWatcher'
13913 version = 1
13914 schema = {'properties': {'Next': {'type': 'object'}, 'Stop': {'type': 'object'}},
13915 'type': 'object'}
13916
13917
13918 @ReturnMapping(None)
13919 async def Next(self):
13920 '''
13921
13922 Returns -> None
13923 '''
13924 # map input types to rpc msg
13925 params = dict()
13926 msg = dict(Type='NotifyWatcher', Request='Next', Version=1, Params=params)
13927
13928 reply = await self.rpc(msg)
13929 return reply
13930
13931
13932
13933 @ReturnMapping(None)
13934 async def Stop(self):
13935 '''
13936
13937 Returns -> None
13938 '''
13939 # map input types to rpc msg
13940 params = dict()
13941 msg = dict(Type='NotifyWatcher', Request='Stop', Version=1, Params=params)
13942
13943 reply = await self.rpc(msg)
13944 return reply
13945
13946
13947 class PingerFacade(Type):
13948 name = 'Pinger'
13949 version = 1
13950 schema = {'properties': {'Ping': {'type': 'object'}, 'Stop': {'type': 'object'}},
13951 'type': 'object'}
13952
13953
13954 @ReturnMapping(None)
13955 async def Ping(self):
13956 '''
13957
13958 Returns -> None
13959 '''
13960 # map input types to rpc msg
13961 params = dict()
13962 msg = dict(Type='Pinger', Request='Ping', Version=1, Params=params)
13963
13964 reply = await self.rpc(msg)
13965 return reply
13966
13967
13968
13969 @ReturnMapping(None)
13970 async def Stop(self):
13971 '''
13972
13973 Returns -> None
13974 '''
13975 # map input types to rpc msg
13976 params = dict()
13977 msg = dict(Type='Pinger', Request='Stop', Version=1, Params=params)
13978
13979 reply = await self.rpc(msg)
13980 return reply
13981
13982
13983 class ProvisionerFacade(Type):
13984 name = 'Provisioner'
13985 version = 3
13986 schema = {'definitions': {'APIHostPortsResult': {'additionalProperties': False,
13987 'properties': {'Servers': {'items': {'items': {'$ref': '#/definitions/HostPort'},
13988 'type': 'array'},
13989 'type': 'array'}},
13990 'required': ['Servers'],
13991 'type': 'object'},
13992 'Address': {'additionalProperties': False,
13993 'properties': {'Scope': {'type': 'string'},
13994 'SpaceName': {'type': 'string'},
13995 'Type': {'type': 'string'},
13996 'Value': {'type': 'string'}},
13997 'required': ['Value', 'Type', 'Scope'],
13998 'type': 'object'},
13999 'Binary': {'additionalProperties': False,
14000 'properties': {'Arch': {'type': 'string'},
14001 'Number': {'$ref': '#/definitions/Number'},
14002 'Series': {'type': 'string'}},
14003 'required': ['Number', 'Series', 'Arch'],
14004 'type': 'object'},
14005 'BytesResult': {'additionalProperties': False,
14006 'properties': {'Result': {'items': {'type': 'integer'},
14007 'type': 'array'}},
14008 'required': ['Result'],
14009 'type': 'object'},
14010 'CloudImageMetadata': {'additionalProperties': False,
14011 'properties': {'arch': {'type': 'string'},
14012 'image_id': {'type': 'string'},
14013 'priority': {'type': 'integer'},
14014 'region': {'type': 'string'},
14015 'root_storage_size': {'type': 'integer'},
14016 'root_storage_type': {'type': 'string'},
14017 'series': {'type': 'string'},
14018 'source': {'type': 'string'},
14019 'stream': {'type': 'string'},
14020 'version': {'type': 'string'},
14021 'virt_type': {'type': 'string'}},
14022 'required': ['image_id',
14023 'region',
14024 'version',
14025 'series',
14026 'arch',
14027 'source',
14028 'priority'],
14029 'type': 'object'},
14030 'ConstraintsResult': {'additionalProperties': False,
14031 'properties': {'Constraints': {'$ref': '#/definitions/Value'},
14032 'Error': {'$ref': '#/definitions/Error'}},
14033 'required': ['Error', 'Constraints'],
14034 'type': 'object'},
14035 'ConstraintsResults': {'additionalProperties': False,
14036 'properties': {'Results': {'items': {'$ref': '#/definitions/ConstraintsResult'},
14037 'type': 'array'}},
14038 'required': ['Results'],
14039 'type': 'object'},
14040 'ContainerConfig': {'additionalProperties': False,
14041 'properties': {'AllowLXCLoopMounts': {'type': 'boolean'},
14042 'AptMirror': {'type': 'string'},
14043 'AptProxy': {'$ref': '#/definitions/Settings'},
14044 'AuthorizedKeys': {'type': 'string'},
14045 'ProviderType': {'type': 'string'},
14046 'Proxy': {'$ref': '#/definitions/Settings'},
14047 'SSLHostnameVerification': {'type': 'boolean'},
14048 'UpdateBehavior': {'$ref': '#/definitions/UpdateBehavior'}},
14049 'required': ['ProviderType',
14050 'AuthorizedKeys',
14051 'SSLHostnameVerification',
14052 'Proxy',
14053 'AptProxy',
14054 'AptMirror',
14055 'AllowLXCLoopMounts',
14056 'UpdateBehavior'],
14057 'type': 'object'},
14058 'ContainerManagerConfig': {'additionalProperties': False,
14059 'properties': {'ManagerConfig': {'patternProperties': {'.*': {'type': 'string'}},
14060 'type': 'object'}},
14061 'required': ['ManagerConfig'],
14062 'type': 'object'},
14063 'ContainerManagerConfigParams': {'additionalProperties': False,
14064 'properties': {'Type': {'type': 'string'}},
14065 'required': ['Type'],
14066 'type': 'object'},
14067 'DistributionGroupResult': {'additionalProperties': False,
14068 'properties': {'Error': {'$ref': '#/definitions/Error'},
14069 'Result': {'items': {'type': 'string'},
14070 'type': 'array'}},
14071 'required': ['Error', 'Result'],
14072 'type': 'object'},
14073 'DistributionGroupResults': {'additionalProperties': False,
14074 'properties': {'Results': {'items': {'$ref': '#/definitions/DistributionGroupResult'},
14075 'type': 'array'}},
14076 'required': ['Results'],
14077 'type': 'object'},
14078 'Entities': {'additionalProperties': False,
14079 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
14080 'type': 'array'}},
14081 'required': ['Entities'],
14082 'type': 'object'},
14083 'Entity': {'additionalProperties': False,
14084 'properties': {'Tag': {'type': 'string'}},
14085 'required': ['Tag'],
14086 'type': 'object'},
14087 'EntityPassword': {'additionalProperties': False,
14088 'properties': {'Password': {'type': 'string'},
14089 'Tag': {'type': 'string'}},
14090 'required': ['Tag', 'Password'],
14091 'type': 'object'},
14092 'EntityPasswords': {'additionalProperties': False,
14093 'properties': {'Changes': {'items': {'$ref': '#/definitions/EntityPassword'},
14094 'type': 'array'}},
14095 'required': ['Changes'],
14096 'type': 'object'},
14097 'EntityStatusArgs': {'additionalProperties': False,
14098 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
14099 'type': 'object'}},
14100 'type': 'object'},
14101 'Info': {'type': 'string'},
14102 'Status': {'type': 'string'},
14103 'Tag': {'type': 'string'}},
14104 'required': ['Tag',
14105 'Status',
14106 'Info',
14107 'Data'],
14108 'type': 'object'},
14109 'Error': {'additionalProperties': False,
14110 'properties': {'Code': {'type': 'string'},
14111 'Info': {'$ref': '#/definitions/ErrorInfo'},
14112 'Message': {'type': 'string'}},
14113 'required': ['Message', 'Code'],
14114 'type': 'object'},
14115 'ErrorInfo': {'additionalProperties': False,
14116 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
14117 'MacaroonPath': {'type': 'string'}},
14118 'type': 'object'},
14119 'ErrorResult': {'additionalProperties': False,
14120 'properties': {'Error': {'$ref': '#/definitions/Error'}},
14121 'required': ['Error'],
14122 'type': 'object'},
14123 'ErrorResults': {'additionalProperties': False,
14124 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
14125 'type': 'array'}},
14126 'required': ['Results'],
14127 'type': 'object'},
14128 'FindToolsParams': {'additionalProperties': False,
14129 'properties': {'Arch': {'type': 'string'},
14130 'MajorVersion': {'type': 'integer'},
14131 'MinorVersion': {'type': 'integer'},
14132 'Number': {'$ref': '#/definitions/Number'},
14133 'Series': {'type': 'string'}},
14134 'required': ['Number',
14135 'MajorVersion',
14136 'MinorVersion',
14137 'Arch',
14138 'Series'],
14139 'type': 'object'},
14140 'FindToolsResult': {'additionalProperties': False,
14141 'properties': {'Error': {'$ref': '#/definitions/Error'},
14142 'List': {'items': {'$ref': '#/definitions/Tools'},
14143 'type': 'array'}},
14144 'required': ['List', 'Error'],
14145 'type': 'object'},
14146 'HardwareCharacteristics': {'additionalProperties': False,
14147 'properties': {'Arch': {'type': 'string'},
14148 'AvailabilityZone': {'type': 'string'},
14149 'CpuCores': {'type': 'integer'},
14150 'CpuPower': {'type': 'integer'},
14151 'Mem': {'type': 'integer'},
14152 'RootDisk': {'type': 'integer'},
14153 'Tags': {'items': {'type': 'string'},
14154 'type': 'array'}},
14155 'type': 'object'},
14156 'HostPort': {'additionalProperties': False,
14157 'properties': {'Address': {'$ref': '#/definitions/Address'},
14158 'Port': {'type': 'integer'}},
14159 'required': ['Address', 'Port'],
14160 'type': 'object'},
14161 'InstanceInfo': {'additionalProperties': False,
14162 'properties': {'Characteristics': {'$ref': '#/definitions/HardwareCharacteristics'},
14163 'InstanceId': {'type': 'string'},
14164 'NetworkConfig': {'items': {'$ref': '#/definitions/NetworkConfig'},
14165 'type': 'array'},
14166 'Nonce': {'type': 'string'},
14167 'Tag': {'type': 'string'},
14168 'VolumeAttachments': {'patternProperties': {'.*': {'$ref': '#/definitions/VolumeAttachmentInfo'}},
14169 'type': 'object'},
14170 'Volumes': {'items': {'$ref': '#/definitions/Volume'},
14171 'type': 'array'}},
14172 'required': ['Tag',
14173 'InstanceId',
14174 'Nonce',
14175 'Characteristics',
14176 'Volumes',
14177 'VolumeAttachments',
14178 'NetworkConfig'],
14179 'type': 'object'},
14180 'InstancesInfo': {'additionalProperties': False,
14181 'properties': {'Machines': {'items': {'$ref': '#/definitions/InstanceInfo'},
14182 'type': 'array'}},
14183 'required': ['Machines'],
14184 'type': 'object'},
14185 'LifeResult': {'additionalProperties': False,
14186 'properties': {'Error': {'$ref': '#/definitions/Error'},
14187 'Life': {'type': 'string'}},
14188 'required': ['Life', 'Error'],
14189 'type': 'object'},
14190 'LifeResults': {'additionalProperties': False,
14191 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
14192 'type': 'array'}},
14193 'required': ['Results'],
14194 'type': 'object'},
14195 'Macaroon': {'additionalProperties': False,
14196 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
14197 'type': 'array'},
14198 'data': {'items': {'type': 'integer'},
14199 'type': 'array'},
14200 'id': {'$ref': '#/definitions/packet'},
14201 'location': {'$ref': '#/definitions/packet'},
14202 'sig': {'items': {'type': 'integer'},
14203 'type': 'array'}},
14204 'required': ['data',
14205 'location',
14206 'id',
14207 'caveats',
14208 'sig'],
14209 'type': 'object'},
14210 'MachineContainers': {'additionalProperties': False,
14211 'properties': {'ContainerTypes': {'items': {'type': 'string'},
14212 'type': 'array'},
14213 'MachineTag': {'type': 'string'}},
14214 'required': ['MachineTag',
14215 'ContainerTypes'],
14216 'type': 'object'},
14217 'MachineContainersParams': {'additionalProperties': False,
14218 'properties': {'Params': {'items': {'$ref': '#/definitions/MachineContainers'},
14219 'type': 'array'}},
14220 'required': ['Params'],
14221 'type': 'object'},
14222 'MachineNetworkConfigResult': {'additionalProperties': False,
14223 'properties': {'Error': {'$ref': '#/definitions/Error'},
14224 'Info': {'items': {'$ref': '#/definitions/NetworkConfig'},
14225 'type': 'array'}},
14226 'required': ['Error', 'Info'],
14227 'type': 'object'},
14228 'MachineNetworkConfigResults': {'additionalProperties': False,
14229 'properties': {'Results': {'items': {'$ref': '#/definitions/MachineNetworkConfigResult'},
14230 'type': 'array'}},
14231 'required': ['Results'],
14232 'type': 'object'},
14233 'ModelConfigResult': {'additionalProperties': False,
14234 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
14235 'type': 'object'}},
14236 'type': 'object'}},
14237 'required': ['Config'],
14238 'type': 'object'},
14239 'NetworkConfig': {'additionalProperties': False,
14240 'properties': {'Address': {'type': 'string'},
14241 'CIDR': {'type': 'string'},
14242 'ConfigType': {'type': 'string'},
14243 'DNSSearchDomains': {'items': {'type': 'string'},
14244 'type': 'array'},
14245 'DNSServers': {'items': {'type': 'string'},
14246 'type': 'array'},
14247 'DeviceIndex': {'type': 'integer'},
14248 'Disabled': {'type': 'boolean'},
14249 'GatewayAddress': {'type': 'string'},
14250 'InterfaceName': {'type': 'string'},
14251 'InterfaceType': {'type': 'string'},
14252 'MACAddress': {'type': 'string'},
14253 'MTU': {'type': 'integer'},
14254 'NoAutoStart': {'type': 'boolean'},
14255 'ParentInterfaceName': {'type': 'string'},
14256 'ProviderAddressId': {'type': 'string'},
14257 'ProviderId': {'type': 'string'},
14258 'ProviderSpaceId': {'type': 'string'},
14259 'ProviderSubnetId': {'type': 'string'},
14260 'ProviderVLANId': {'type': 'string'},
14261 'VLANTag': {'type': 'integer'}},
14262 'required': ['DeviceIndex',
14263 'MACAddress',
14264 'CIDR',
14265 'MTU',
14266 'ProviderId',
14267 'ProviderSubnetId',
14268 'ProviderSpaceId',
14269 'ProviderAddressId',
14270 'ProviderVLANId',
14271 'VLANTag',
14272 'InterfaceName',
14273 'ParentInterfaceName',
14274 'InterfaceType',
14275 'Disabled'],
14276 'type': 'object'},
14277 'NotifyWatchResult': {'additionalProperties': False,
14278 'properties': {'Error': {'$ref': '#/definitions/Error'},
14279 'NotifyWatcherId': {'type': 'string'}},
14280 'required': ['NotifyWatcherId', 'Error'],
14281 'type': 'object'},
14282 'Number': {'additionalProperties': False,
14283 'properties': {'Build': {'type': 'integer'},
14284 'Major': {'type': 'integer'},
14285 'Minor': {'type': 'integer'},
14286 'Patch': {'type': 'integer'},
14287 'Tag': {'type': 'string'}},
14288 'required': ['Major',
14289 'Minor',
14290 'Tag',
14291 'Patch',
14292 'Build'],
14293 'type': 'object'},
14294 'ProvisioningInfo': {'additionalProperties': False,
14295 'properties': {'Constraints': {'$ref': '#/definitions/Value'},
14296 'EndpointBindings': {'patternProperties': {'.*': {'type': 'string'}},
14297 'type': 'object'},
14298 'ImageMetadata': {'items': {'$ref': '#/definitions/CloudImageMetadata'},
14299 'type': 'array'},
14300 'Jobs': {'items': {'type': 'string'},
14301 'type': 'array'},
14302 'Placement': {'type': 'string'},
14303 'Series': {'type': 'string'},
14304 'SubnetsToZones': {'patternProperties': {'.*': {'items': {'type': 'string'},
14305 'type': 'array'}},
14306 'type': 'object'},
14307 'Tags': {'patternProperties': {'.*': {'type': 'string'}},
14308 'type': 'object'},
14309 'Volumes': {'items': {'$ref': '#/definitions/VolumeParams'},
14310 'type': 'array'}},
14311 'required': ['Constraints',
14312 'Series',
14313 'Placement',
14314 'Jobs',
14315 'Volumes',
14316 'Tags',
14317 'SubnetsToZones',
14318 'ImageMetadata',
14319 'EndpointBindings'],
14320 'type': 'object'},
14321 'ProvisioningInfoResult': {'additionalProperties': False,
14322 'properties': {'Error': {'$ref': '#/definitions/Error'},
14323 'Result': {'$ref': '#/definitions/ProvisioningInfo'}},
14324 'required': ['Error', 'Result'],
14325 'type': 'object'},
14326 'ProvisioningInfoResults': {'additionalProperties': False,
14327 'properties': {'Results': {'items': {'$ref': '#/definitions/ProvisioningInfoResult'},
14328 'type': 'array'}},
14329 'required': ['Results'],
14330 'type': 'object'},
14331 'SetStatus': {'additionalProperties': False,
14332 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
14333 'type': 'array'}},
14334 'required': ['Entities'],
14335 'type': 'object'},
14336 'Settings': {'additionalProperties': False,
14337 'properties': {'Ftp': {'type': 'string'},
14338 'Http': {'type': 'string'},
14339 'Https': {'type': 'string'},
14340 'NoProxy': {'type': 'string'}},
14341 'required': ['Http', 'Https', 'Ftp', 'NoProxy'],
14342 'type': 'object'},
14343 'StatusResult': {'additionalProperties': False,
14344 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
14345 'type': 'object'}},
14346 'type': 'object'},
14347 'Error': {'$ref': '#/definitions/Error'},
14348 'Id': {'type': 'string'},
14349 'Info': {'type': 'string'},
14350 'Life': {'type': 'string'},
14351 'Since': {'format': 'date-time',
14352 'type': 'string'},
14353 'Status': {'type': 'string'}},
14354 'required': ['Error',
14355 'Id',
14356 'Life',
14357 'Status',
14358 'Info',
14359 'Data',
14360 'Since'],
14361 'type': 'object'},
14362 'StatusResults': {'additionalProperties': False,
14363 'properties': {'Results': {'items': {'$ref': '#/definitions/StatusResult'},
14364 'type': 'array'}},
14365 'required': ['Results'],
14366 'type': 'object'},
14367 'StringResult': {'additionalProperties': False,
14368 'properties': {'Error': {'$ref': '#/definitions/Error'},
14369 'Result': {'type': 'string'}},
14370 'required': ['Error', 'Result'],
14371 'type': 'object'},
14372 'StringResults': {'additionalProperties': False,
14373 'properties': {'Results': {'items': {'$ref': '#/definitions/StringResult'},
14374 'type': 'array'}},
14375 'required': ['Results'],
14376 'type': 'object'},
14377 'StringsResult': {'additionalProperties': False,
14378 'properties': {'Error': {'$ref': '#/definitions/Error'},
14379 'Result': {'items': {'type': 'string'},
14380 'type': 'array'}},
14381 'required': ['Error', 'Result'],
14382 'type': 'object'},
14383 'StringsWatchResult': {'additionalProperties': False,
14384 'properties': {'Changes': {'items': {'type': 'string'},
14385 'type': 'array'},
14386 'Error': {'$ref': '#/definitions/Error'},
14387 'StringsWatcherId': {'type': 'string'}},
14388 'required': ['StringsWatcherId',
14389 'Changes',
14390 'Error'],
14391 'type': 'object'},
14392 'StringsWatchResults': {'additionalProperties': False,
14393 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsWatchResult'},
14394 'type': 'array'}},
14395 'required': ['Results'],
14396 'type': 'object'},
14397 'Tools': {'additionalProperties': False,
14398 'properties': {'sha256': {'type': 'string'},
14399 'size': {'type': 'integer'},
14400 'url': {'type': 'string'},
14401 'version': {'$ref': '#/definitions/Binary'}},
14402 'required': ['version', 'url', 'size'],
14403 'type': 'object'},
14404 'ToolsResult': {'additionalProperties': False,
14405 'properties': {'DisableSSLHostnameVerification': {'type': 'boolean'},
14406 'Error': {'$ref': '#/definitions/Error'},
14407 'ToolsList': {'items': {'$ref': '#/definitions/Tools'},
14408 'type': 'array'}},
14409 'required': ['ToolsList',
14410 'DisableSSLHostnameVerification',
14411 'Error'],
14412 'type': 'object'},
14413 'ToolsResults': {'additionalProperties': False,
14414 'properties': {'Results': {'items': {'$ref': '#/definitions/ToolsResult'},
14415 'type': 'array'}},
14416 'required': ['Results'],
14417 'type': 'object'},
14418 'UpdateBehavior': {'additionalProperties': False,
14419 'properties': {'EnableOSRefreshUpdate': {'type': 'boolean'},
14420 'EnableOSUpgrade': {'type': 'boolean'}},
14421 'required': ['EnableOSRefreshUpdate',
14422 'EnableOSUpgrade'],
14423 'type': 'object'},
14424 'Value': {'additionalProperties': False,
14425 'properties': {'arch': {'type': 'string'},
14426 'container': {'type': 'string'},
14427 'cpu-cores': {'type': 'integer'},
14428 'cpu-power': {'type': 'integer'},
14429 'instance-type': {'type': 'string'},
14430 'mem': {'type': 'integer'},
14431 'root-disk': {'type': 'integer'},
14432 'spaces': {'items': {'type': 'string'},
14433 'type': 'array'},
14434 'tags': {'items': {'type': 'string'},
14435 'type': 'array'},
14436 'virt-type': {'type': 'string'}},
14437 'type': 'object'},
14438 'Volume': {'additionalProperties': False,
14439 'properties': {'info': {'$ref': '#/definitions/VolumeInfo'},
14440 'volumetag': {'type': 'string'}},
14441 'required': ['volumetag', 'info'],
14442 'type': 'object'},
14443 'VolumeAttachmentInfo': {'additionalProperties': False,
14444 'properties': {'busaddress': {'type': 'string'},
14445 'devicelink': {'type': 'string'},
14446 'devicename': {'type': 'string'},
14447 'read-only': {'type': 'boolean'}},
14448 'type': 'object'},
14449 'VolumeAttachmentParams': {'additionalProperties': False,
14450 'properties': {'instanceid': {'type': 'string'},
14451 'machinetag': {'type': 'string'},
14452 'provider': {'type': 'string'},
14453 'read-only': {'type': 'boolean'},
14454 'volumeid': {'type': 'string'},
14455 'volumetag': {'type': 'string'}},
14456 'required': ['volumetag',
14457 'machinetag',
14458 'provider'],
14459 'type': 'object'},
14460 'VolumeInfo': {'additionalProperties': False,
14461 'properties': {'hardwareid': {'type': 'string'},
14462 'persistent': {'type': 'boolean'},
14463 'size': {'type': 'integer'},
14464 'volumeid': {'type': 'string'}},
14465 'required': ['volumeid', 'size', 'persistent'],
14466 'type': 'object'},
14467 'VolumeParams': {'additionalProperties': False,
14468 'properties': {'attachment': {'$ref': '#/definitions/VolumeAttachmentParams'},
14469 'attributes': {'patternProperties': {'.*': {'additionalProperties': True,
14470 'type': 'object'}},
14471 'type': 'object'},
14472 'provider': {'type': 'string'},
14473 'size': {'type': 'integer'},
14474 'tags': {'patternProperties': {'.*': {'type': 'string'}},
14475 'type': 'object'},
14476 'volumetag': {'type': 'string'}},
14477 'required': ['volumetag', 'size', 'provider'],
14478 'type': 'object'},
14479 'WatchContainer': {'additionalProperties': False,
14480 'properties': {'ContainerType': {'type': 'string'},
14481 'MachineTag': {'type': 'string'}},
14482 'required': ['MachineTag', 'ContainerType'],
14483 'type': 'object'},
14484 'WatchContainers': {'additionalProperties': False,
14485 'properties': {'Params': {'items': {'$ref': '#/definitions/WatchContainer'},
14486 'type': 'array'}},
14487 'required': ['Params'],
14488 'type': 'object'},
14489 'caveat': {'additionalProperties': False,
14490 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
14491 'location': {'$ref': '#/definitions/packet'},
14492 'verificationId': {'$ref': '#/definitions/packet'}},
14493 'required': ['location',
14494 'caveatId',
14495 'verificationId'],
14496 'type': 'object'},
14497 'packet': {'additionalProperties': False,
14498 'properties': {'headerLen': {'type': 'integer'},
14499 'start': {'type': 'integer'},
14500 'totalLen': {'type': 'integer'}},
14501 'required': ['start', 'totalLen', 'headerLen'],
14502 'type': 'object'}},
14503 'properties': {'APIAddresses': {'properties': {'Result': {'$ref': '#/definitions/StringsResult'}},
14504 'type': 'object'},
14505 'APIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/APIHostPortsResult'}},
14506 'type': 'object'},
14507 'CACert': {'properties': {'Result': {'$ref': '#/definitions/BytesResult'}},
14508 'type': 'object'},
14509 'Constraints': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14510 'Result': {'$ref': '#/definitions/ConstraintsResults'}},
14511 'type': 'object'},
14512 'ContainerConfig': {'properties': {'Result': {'$ref': '#/definitions/ContainerConfig'}},
14513 'type': 'object'},
14514 'ContainerManagerConfig': {'properties': {'Params': {'$ref': '#/definitions/ContainerManagerConfigParams'},
14515 'Result': {'$ref': '#/definitions/ContainerManagerConfig'}},
14516 'type': 'object'},
14517 'DistributionGroup': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14518 'Result': {'$ref': '#/definitions/DistributionGroupResults'}},
14519 'type': 'object'},
14520 'EnsureDead': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14521 'Result': {'$ref': '#/definitions/ErrorResults'}},
14522 'type': 'object'},
14523 'FindTools': {'properties': {'Params': {'$ref': '#/definitions/FindToolsParams'},
14524 'Result': {'$ref': '#/definitions/FindToolsResult'}},
14525 'type': 'object'},
14526 'GetContainerInterfaceInfo': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14527 'Result': {'$ref': '#/definitions/MachineNetworkConfigResults'}},
14528 'type': 'object'},
14529 'InstanceId': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14530 'Result': {'$ref': '#/definitions/StringResults'}},
14531 'type': 'object'},
14532 'InstanceStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14533 'Result': {'$ref': '#/definitions/StatusResults'}},
14534 'type': 'object'},
14535 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14536 'Result': {'$ref': '#/definitions/LifeResults'}},
14537 'type': 'object'},
14538 'MachinesWithTransientErrors': {'properties': {'Result': {'$ref': '#/definitions/StatusResults'}},
14539 'type': 'object'},
14540 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
14541 'type': 'object'},
14542 'ModelUUID': {'properties': {'Result': {'$ref': '#/definitions/StringResult'}},
14543 'type': 'object'},
14544 'PrepareContainerInterfaceInfo': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14545 'Result': {'$ref': '#/definitions/MachineNetworkConfigResults'}},
14546 'type': 'object'},
14547 'ProvisioningInfo': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14548 'Result': {'$ref': '#/definitions/ProvisioningInfoResults'}},
14549 'type': 'object'},
14550 'ReleaseContainerAddresses': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14551 'Result': {'$ref': '#/definitions/ErrorResults'}},
14552 'type': 'object'},
14553 'Remove': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14554 'Result': {'$ref': '#/definitions/ErrorResults'}},
14555 'type': 'object'},
14556 'Series': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14557 'Result': {'$ref': '#/definitions/StringResults'}},
14558 'type': 'object'},
14559 'SetInstanceInfo': {'properties': {'Params': {'$ref': '#/definitions/InstancesInfo'},
14560 'Result': {'$ref': '#/definitions/ErrorResults'}},
14561 'type': 'object'},
14562 'SetInstanceStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
14563 'Result': {'$ref': '#/definitions/ErrorResults'}},
14564 'type': 'object'},
14565 'SetPasswords': {'properties': {'Params': {'$ref': '#/definitions/EntityPasswords'},
14566 'Result': {'$ref': '#/definitions/ErrorResults'}},
14567 'type': 'object'},
14568 'SetStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
14569 'Result': {'$ref': '#/definitions/ErrorResults'}},
14570 'type': 'object'},
14571 'SetSupportedContainers': {'properties': {'Params': {'$ref': '#/definitions/MachineContainersParams'},
14572 'Result': {'$ref': '#/definitions/ErrorResults'}},
14573 'type': 'object'},
14574 'StateAddresses': {'properties': {'Result': {'$ref': '#/definitions/StringsResult'}},
14575 'type': 'object'},
14576 'Status': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14577 'Result': {'$ref': '#/definitions/StatusResults'}},
14578 'type': 'object'},
14579 'Tools': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
14580 'Result': {'$ref': '#/definitions/ToolsResults'}},
14581 'type': 'object'},
14582 'UpdateStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
14583 'Result': {'$ref': '#/definitions/ErrorResults'}},
14584 'type': 'object'},
14585 'WatchAPIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
14586 'type': 'object'},
14587 'WatchAllContainers': {'properties': {'Params': {'$ref': '#/definitions/WatchContainers'},
14588 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
14589 'type': 'object'},
14590 'WatchContainers': {'properties': {'Params': {'$ref': '#/definitions/WatchContainers'},
14591 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
14592 'type': 'object'},
14593 'WatchForModelConfigChanges': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
14594 'type': 'object'},
14595 'WatchMachineErrorRetry': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
14596 'type': 'object'},
14597 'WatchModelMachines': {'properties': {'Result': {'$ref': '#/definitions/StringsWatchResult'}},
14598 'type': 'object'}},
14599 'type': 'object'}
14600
14601
14602 @ReturnMapping(StringsResult)
14603 async def APIAddresses(self):
14604 '''
14605
14606 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[str]]
14607 '''
14608 # map input types to rpc msg
14609 params = dict()
14610 msg = dict(Type='Provisioner', Request='APIAddresses', Version=3, Params=params)
14611
14612 reply = await self.rpc(msg)
14613 return reply
14614
14615
14616
14617 @ReturnMapping(APIHostPortsResult)
14618 async def APIHostPorts(self):
14619 '''
14620
14621 Returns -> typing.Sequence[~HostPort]
14622 '''
14623 # map input types to rpc msg
14624 params = dict()
14625 msg = dict(Type='Provisioner', Request='APIHostPorts', Version=3, Params=params)
14626
14627 reply = await self.rpc(msg)
14628 return reply
14629
14630
14631
14632 @ReturnMapping(BytesResult)
14633 async def CACert(self):
14634 '''
14635
14636 Returns -> typing.Sequence[int]
14637 '''
14638 # map input types to rpc msg
14639 params = dict()
14640 msg = dict(Type='Provisioner', Request='CACert', Version=3, Params=params)
14641
14642 reply = await self.rpc(msg)
14643 return reply
14644
14645
14646
14647 @ReturnMapping(ConstraintsResults)
14648 async def Constraints(self, entities):
14649 '''
14650 entities : typing.Sequence[~Entity]
14651 Returns -> typing.Sequence[~ConstraintsResult]
14652 '''
14653 # map input types to rpc msg
14654 params = dict()
14655 msg = dict(Type='Provisioner', Request='Constraints', Version=3, Params=params)
14656 params['Entities'] = entities
14657 reply = await self.rpc(msg)
14658 return reply
14659
14660
14661
14662 @ReturnMapping(ContainerConfig)
14663 async def ContainerConfig(self):
14664 '''
14665
14666 Returns -> typing.Union[bool, str, _ForwardRef('Settings'), _ForwardRef('Settings'), _ForwardRef('UpdateBehavior')]
14667 '''
14668 # map input types to rpc msg
14669 params = dict()
14670 msg = dict(Type='Provisioner', Request='ContainerConfig', Version=3, Params=params)
14671
14672 reply = await self.rpc(msg)
14673 return reply
14674
14675
14676
14677 @ReturnMapping(ContainerManagerConfig)
14678 async def ContainerManagerConfig(self, type_):
14679 '''
14680 type_ : str
14681 Returns -> typing.Mapping[str, str]
14682 '''
14683 # map input types to rpc msg
14684 params = dict()
14685 msg = dict(Type='Provisioner', Request='ContainerManagerConfig', Version=3, Params=params)
14686 params['Type'] = type_
14687 reply = await self.rpc(msg)
14688 return reply
14689
14690
14691
14692 @ReturnMapping(DistributionGroupResults)
14693 async def DistributionGroup(self, entities):
14694 '''
14695 entities : typing.Sequence[~Entity]
14696 Returns -> typing.Sequence[~DistributionGroupResult]
14697 '''
14698 # map input types to rpc msg
14699 params = dict()
14700 msg = dict(Type='Provisioner', Request='DistributionGroup', Version=3, Params=params)
14701 params['Entities'] = entities
14702 reply = await self.rpc(msg)
14703 return reply
14704
14705
14706
14707 @ReturnMapping(ErrorResults)
14708 async def EnsureDead(self, entities):
14709 '''
14710 entities : typing.Sequence[~Entity]
14711 Returns -> typing.Sequence[~ErrorResult]
14712 '''
14713 # map input types to rpc msg
14714 params = dict()
14715 msg = dict(Type='Provisioner', Request='EnsureDead', Version=3, Params=params)
14716 params['Entities'] = entities
14717 reply = await self.rpc(msg)
14718 return reply
14719
14720
14721
14722 @ReturnMapping(FindToolsResult)
14723 async def FindTools(self, arch, majorversion, minorversion, number, series):
14724 '''
14725 arch : str
14726 majorversion : int
14727 minorversion : int
14728 number : Number
14729 series : str
14730 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[~Tools]]
14731 '''
14732 # map input types to rpc msg
14733 params = dict()
14734 msg = dict(Type='Provisioner', Request='FindTools', Version=3, Params=params)
14735 params['Arch'] = arch
14736 params['MajorVersion'] = majorversion
14737 params['MinorVersion'] = minorversion
14738 params['Number'] = number
14739 params['Series'] = series
14740 reply = await self.rpc(msg)
14741 return reply
14742
14743
14744
14745 @ReturnMapping(MachineNetworkConfigResults)
14746 async def GetContainerInterfaceInfo(self, entities):
14747 '''
14748 entities : typing.Sequence[~Entity]
14749 Returns -> typing.Sequence[~MachineNetworkConfigResult]
14750 '''
14751 # map input types to rpc msg
14752 params = dict()
14753 msg = dict(Type='Provisioner', Request='GetContainerInterfaceInfo', Version=3, Params=params)
14754 params['Entities'] = entities
14755 reply = await self.rpc(msg)
14756 return reply
14757
14758
14759
14760 @ReturnMapping(StringResults)
14761 async def InstanceId(self, entities):
14762 '''
14763 entities : typing.Sequence[~Entity]
14764 Returns -> typing.Sequence[~StringResult]
14765 '''
14766 # map input types to rpc msg
14767 params = dict()
14768 msg = dict(Type='Provisioner', Request='InstanceId', Version=3, Params=params)
14769 params['Entities'] = entities
14770 reply = await self.rpc(msg)
14771 return reply
14772
14773
14774
14775 @ReturnMapping(StatusResults)
14776 async def InstanceStatus(self, entities):
14777 '''
14778 entities : typing.Sequence[~Entity]
14779 Returns -> typing.Sequence[~StatusResult]
14780 '''
14781 # map input types to rpc msg
14782 params = dict()
14783 msg = dict(Type='Provisioner', Request='InstanceStatus', Version=3, Params=params)
14784 params['Entities'] = entities
14785 reply = await self.rpc(msg)
14786 return reply
14787
14788
14789
14790 @ReturnMapping(LifeResults)
14791 async def Life(self, entities):
14792 '''
14793 entities : typing.Sequence[~Entity]
14794 Returns -> typing.Sequence[~LifeResult]
14795 '''
14796 # map input types to rpc msg
14797 params = dict()
14798 msg = dict(Type='Provisioner', Request='Life', Version=3, Params=params)
14799 params['Entities'] = entities
14800 reply = await self.rpc(msg)
14801 return reply
14802
14803
14804
14805 @ReturnMapping(StatusResults)
14806 async def MachinesWithTransientErrors(self):
14807 '''
14808
14809 Returns -> typing.Sequence[~StatusResult]
14810 '''
14811 # map input types to rpc msg
14812 params = dict()
14813 msg = dict(Type='Provisioner', Request='MachinesWithTransientErrors', Version=3, Params=params)
14814
14815 reply = await self.rpc(msg)
14816 return reply
14817
14818
14819
14820 @ReturnMapping(ModelConfigResult)
14821 async def ModelConfig(self):
14822 '''
14823
14824 Returns -> typing.Mapping[str, typing.Any]
14825 '''
14826 # map input types to rpc msg
14827 params = dict()
14828 msg = dict(Type='Provisioner', Request='ModelConfig', Version=3, Params=params)
14829
14830 reply = await self.rpc(msg)
14831 return reply
14832
14833
14834
14835 @ReturnMapping(StringResult)
14836 async def ModelUUID(self):
14837 '''
14838
14839 Returns -> typing.Union[_ForwardRef('Error'), str]
14840 '''
14841 # map input types to rpc msg
14842 params = dict()
14843 msg = dict(Type='Provisioner', Request='ModelUUID', Version=3, Params=params)
14844
14845 reply = await self.rpc(msg)
14846 return reply
14847
14848
14849
14850 @ReturnMapping(MachineNetworkConfigResults)
14851 async def PrepareContainerInterfaceInfo(self, entities):
14852 '''
14853 entities : typing.Sequence[~Entity]
14854 Returns -> typing.Sequence[~MachineNetworkConfigResult]
14855 '''
14856 # map input types to rpc msg
14857 params = dict()
14858 msg = dict(Type='Provisioner', Request='PrepareContainerInterfaceInfo', Version=3, Params=params)
14859 params['Entities'] = entities
14860 reply = await self.rpc(msg)
14861 return reply
14862
14863
14864
14865 @ReturnMapping(ProvisioningInfoResults)
14866 async def ProvisioningInfo(self, entities):
14867 '''
14868 entities : typing.Sequence[~Entity]
14869 Returns -> typing.Sequence[~ProvisioningInfoResult]
14870 '''
14871 # map input types to rpc msg
14872 params = dict()
14873 msg = dict(Type='Provisioner', Request='ProvisioningInfo', Version=3, Params=params)
14874 params['Entities'] = entities
14875 reply = await self.rpc(msg)
14876 return reply
14877
14878
14879
14880 @ReturnMapping(ErrorResults)
14881 async def ReleaseContainerAddresses(self, entities):
14882 '''
14883 entities : typing.Sequence[~Entity]
14884 Returns -> typing.Sequence[~ErrorResult]
14885 '''
14886 # map input types to rpc msg
14887 params = dict()
14888 msg = dict(Type='Provisioner', Request='ReleaseContainerAddresses', Version=3, Params=params)
14889 params['Entities'] = entities
14890 reply = await self.rpc(msg)
14891 return reply
14892
14893
14894
14895 @ReturnMapping(ErrorResults)
14896 async def Remove(self, entities):
14897 '''
14898 entities : typing.Sequence[~Entity]
14899 Returns -> typing.Sequence[~ErrorResult]
14900 '''
14901 # map input types to rpc msg
14902 params = dict()
14903 msg = dict(Type='Provisioner', Request='Remove', Version=3, Params=params)
14904 params['Entities'] = entities
14905 reply = await self.rpc(msg)
14906 return reply
14907
14908
14909
14910 @ReturnMapping(StringResults)
14911 async def Series(self, entities):
14912 '''
14913 entities : typing.Sequence[~Entity]
14914 Returns -> typing.Sequence[~StringResult]
14915 '''
14916 # map input types to rpc msg
14917 params = dict()
14918 msg = dict(Type='Provisioner', Request='Series', Version=3, Params=params)
14919 params['Entities'] = entities
14920 reply = await self.rpc(msg)
14921 return reply
14922
14923
14924
14925 @ReturnMapping(ErrorResults)
14926 async def SetInstanceInfo(self, machines):
14927 '''
14928 machines : typing.Sequence[~InstanceInfo]
14929 Returns -> typing.Sequence[~ErrorResult]
14930 '''
14931 # map input types to rpc msg
14932 params = dict()
14933 msg = dict(Type='Provisioner', Request='SetInstanceInfo', Version=3, Params=params)
14934 params['Machines'] = machines
14935 reply = await self.rpc(msg)
14936 return reply
14937
14938
14939
14940 @ReturnMapping(ErrorResults)
14941 async def SetInstanceStatus(self, entities):
14942 '''
14943 entities : typing.Sequence[~EntityStatusArgs]
14944 Returns -> typing.Sequence[~ErrorResult]
14945 '''
14946 # map input types to rpc msg
14947 params = dict()
14948 msg = dict(Type='Provisioner', Request='SetInstanceStatus', Version=3, Params=params)
14949 params['Entities'] = entities
14950 reply = await self.rpc(msg)
14951 return reply
14952
14953
14954
14955 @ReturnMapping(ErrorResults)
14956 async def SetPasswords(self, changes):
14957 '''
14958 changes : typing.Sequence[~EntityPassword]
14959 Returns -> typing.Sequence[~ErrorResult]
14960 '''
14961 # map input types to rpc msg
14962 params = dict()
14963 msg = dict(Type='Provisioner', Request='SetPasswords', Version=3, Params=params)
14964 params['Changes'] = changes
14965 reply = await self.rpc(msg)
14966 return reply
14967
14968
14969
14970 @ReturnMapping(ErrorResults)
14971 async def SetStatus(self, entities):
14972 '''
14973 entities : typing.Sequence[~EntityStatusArgs]
14974 Returns -> typing.Sequence[~ErrorResult]
14975 '''
14976 # map input types to rpc msg
14977 params = dict()
14978 msg = dict(Type='Provisioner', Request='SetStatus', Version=3, Params=params)
14979 params['Entities'] = entities
14980 reply = await self.rpc(msg)
14981 return reply
14982
14983
14984
14985 @ReturnMapping(ErrorResults)
14986 async def SetSupportedContainers(self, params):
14987 '''
14988 params : typing.Sequence[~MachineContainers]
14989 Returns -> typing.Sequence[~ErrorResult]
14990 '''
14991 # map input types to rpc msg
14992 params = dict()
14993 msg = dict(Type='Provisioner', Request='SetSupportedContainers', Version=3, Params=params)
14994 params['Params'] = params
14995 reply = await self.rpc(msg)
14996 return reply
14997
14998
14999
15000 @ReturnMapping(StringsResult)
15001 async def StateAddresses(self):
15002 '''
15003
15004 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[str]]
15005 '''
15006 # map input types to rpc msg
15007 params = dict()
15008 msg = dict(Type='Provisioner', Request='StateAddresses', Version=3, Params=params)
15009
15010 reply = await self.rpc(msg)
15011 return reply
15012
15013
15014
15015 @ReturnMapping(StatusResults)
15016 async def Status(self, entities):
15017 '''
15018 entities : typing.Sequence[~Entity]
15019 Returns -> typing.Sequence[~StatusResult]
15020 '''
15021 # map input types to rpc msg
15022 params = dict()
15023 msg = dict(Type='Provisioner', Request='Status', Version=3, Params=params)
15024 params['Entities'] = entities
15025 reply = await self.rpc(msg)
15026 return reply
15027
15028
15029
15030 @ReturnMapping(ToolsResults)
15031 async def Tools(self, entities):
15032 '''
15033 entities : typing.Sequence[~Entity]
15034 Returns -> typing.Sequence[~ToolsResult]
15035 '''
15036 # map input types to rpc msg
15037 params = dict()
15038 msg = dict(Type='Provisioner', Request='Tools', Version=3, Params=params)
15039 params['Entities'] = entities
15040 reply = await self.rpc(msg)
15041 return reply
15042
15043
15044
15045 @ReturnMapping(ErrorResults)
15046 async def UpdateStatus(self, entities):
15047 '''
15048 entities : typing.Sequence[~EntityStatusArgs]
15049 Returns -> typing.Sequence[~ErrorResult]
15050 '''
15051 # map input types to rpc msg
15052 params = dict()
15053 msg = dict(Type='Provisioner', Request='UpdateStatus', Version=3, Params=params)
15054 params['Entities'] = entities
15055 reply = await self.rpc(msg)
15056 return reply
15057
15058
15059
15060 @ReturnMapping(NotifyWatchResult)
15061 async def WatchAPIHostPorts(self):
15062 '''
15063
15064 Returns -> typing.Union[_ForwardRef('Error'), str]
15065 '''
15066 # map input types to rpc msg
15067 params = dict()
15068 msg = dict(Type='Provisioner', Request='WatchAPIHostPorts', Version=3, Params=params)
15069
15070 reply = await self.rpc(msg)
15071 return reply
15072
15073
15074
15075 @ReturnMapping(StringsWatchResults)
15076 async def WatchAllContainers(self, params):
15077 '''
15078 params : typing.Sequence[~WatchContainer]
15079 Returns -> typing.Sequence[~StringsWatchResult]
15080 '''
15081 # map input types to rpc msg
15082 params = dict()
15083 msg = dict(Type='Provisioner', Request='WatchAllContainers', Version=3, Params=params)
15084 params['Params'] = params
15085 reply = await self.rpc(msg)
15086 return reply
15087
15088
15089
15090 @ReturnMapping(StringsWatchResults)
15091 async def WatchContainers(self, params):
15092 '''
15093 params : typing.Sequence[~WatchContainer]
15094 Returns -> typing.Sequence[~StringsWatchResult]
15095 '''
15096 # map input types to rpc msg
15097 params = dict()
15098 msg = dict(Type='Provisioner', Request='WatchContainers', Version=3, Params=params)
15099 params['Params'] = params
15100 reply = await self.rpc(msg)
15101 return reply
15102
15103
15104
15105 @ReturnMapping(NotifyWatchResult)
15106 async def WatchForModelConfigChanges(self):
15107 '''
15108
15109 Returns -> typing.Union[_ForwardRef('Error'), str]
15110 '''
15111 # map input types to rpc msg
15112 params = dict()
15113 msg = dict(Type='Provisioner', Request='WatchForModelConfigChanges', Version=3, Params=params)
15114
15115 reply = await self.rpc(msg)
15116 return reply
15117
15118
15119
15120 @ReturnMapping(NotifyWatchResult)
15121 async def WatchMachineErrorRetry(self):
15122 '''
15123
15124 Returns -> typing.Union[_ForwardRef('Error'), str]
15125 '''
15126 # map input types to rpc msg
15127 params = dict()
15128 msg = dict(Type='Provisioner', Request='WatchMachineErrorRetry', Version=3, Params=params)
15129
15130 reply = await self.rpc(msg)
15131 return reply
15132
15133
15134
15135 @ReturnMapping(StringsWatchResult)
15136 async def WatchModelMachines(self):
15137 '''
15138
15139 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
15140 '''
15141 # map input types to rpc msg
15142 params = dict()
15143 msg = dict(Type='Provisioner', Request='WatchModelMachines', Version=3, Params=params)
15144
15145 reply = await self.rpc(msg)
15146 return reply
15147
15148
15149 class ProxyUpdaterFacade(Type):
15150 name = 'ProxyUpdater'
15151 version = 1
15152 schema = {'definitions': {'Entities': {'additionalProperties': False,
15153 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
15154 'type': 'array'}},
15155 'required': ['Entities'],
15156 'type': 'object'},
15157 'Entity': {'additionalProperties': False,
15158 'properties': {'Tag': {'type': 'string'}},
15159 'required': ['Tag'],
15160 'type': 'object'},
15161 'Error': {'additionalProperties': False,
15162 'properties': {'Code': {'type': 'string'},
15163 'Info': {'$ref': '#/definitions/ErrorInfo'},
15164 'Message': {'type': 'string'}},
15165 'required': ['Message', 'Code'],
15166 'type': 'object'},
15167 'ErrorInfo': {'additionalProperties': False,
15168 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15169 'MacaroonPath': {'type': 'string'}},
15170 'type': 'object'},
15171 'Macaroon': {'additionalProperties': False,
15172 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15173 'type': 'array'},
15174 'data': {'items': {'type': 'integer'},
15175 'type': 'array'},
15176 'id': {'$ref': '#/definitions/packet'},
15177 'location': {'$ref': '#/definitions/packet'},
15178 'sig': {'items': {'type': 'integer'},
15179 'type': 'array'}},
15180 'required': ['data',
15181 'location',
15182 'id',
15183 'caveats',
15184 'sig'],
15185 'type': 'object'},
15186 'NotifyWatchResult': {'additionalProperties': False,
15187 'properties': {'Error': {'$ref': '#/definitions/Error'},
15188 'NotifyWatcherId': {'type': 'string'}},
15189 'required': ['NotifyWatcherId', 'Error'],
15190 'type': 'object'},
15191 'NotifyWatchResults': {'additionalProperties': False,
15192 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
15193 'type': 'array'}},
15194 'required': ['Results'],
15195 'type': 'object'},
15196 'ProxyConfig': {'additionalProperties': False,
15197 'properties': {'FTP': {'type': 'string'},
15198 'HTTP': {'type': 'string'},
15199 'HTTPS': {'type': 'string'},
15200 'NoProxy': {'type': 'string'}},
15201 'required': ['HTTP',
15202 'HTTPS',
15203 'FTP',
15204 'NoProxy'],
15205 'type': 'object'},
15206 'ProxyConfigResult': {'additionalProperties': False,
15207 'properties': {'APTProxySettings': {'$ref': '#/definitions/ProxyConfig'},
15208 'Error': {'$ref': '#/definitions/Error'},
15209 'ProxySettings': {'$ref': '#/definitions/ProxyConfig'}},
15210 'required': ['ProxySettings',
15211 'APTProxySettings'],
15212 'type': 'object'},
15213 'ProxyConfigResults': {'additionalProperties': False,
15214 'properties': {'Results': {'items': {'$ref': '#/definitions/ProxyConfigResult'},
15215 'type': 'array'}},
15216 'required': ['Results'],
15217 'type': 'object'},
15218 'caveat': {'additionalProperties': False,
15219 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15220 'location': {'$ref': '#/definitions/packet'},
15221 'verificationId': {'$ref': '#/definitions/packet'}},
15222 'required': ['location',
15223 'caveatId',
15224 'verificationId'],
15225 'type': 'object'},
15226 'packet': {'additionalProperties': False,
15227 'properties': {'headerLen': {'type': 'integer'},
15228 'start': {'type': 'integer'},
15229 'totalLen': {'type': 'integer'}},
15230 'required': ['start', 'totalLen', 'headerLen'],
15231 'type': 'object'}},
15232 'properties': {'ProxyConfig': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15233 'Result': {'$ref': '#/definitions/ProxyConfigResults'}},
15234 'type': 'object'},
15235 'WatchForProxyConfigAndAPIHostPortChanges': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15236 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
15237 'type': 'object'}},
15238 'type': 'object'}
15239
15240
15241 @ReturnMapping(ProxyConfigResults)
15242 async def ProxyConfig(self, entities):
15243 '''
15244 entities : typing.Sequence[~Entity]
15245 Returns -> typing.Sequence[~ProxyConfigResult]
15246 '''
15247 # map input types to rpc msg
15248 params = dict()
15249 msg = dict(Type='ProxyUpdater', Request='ProxyConfig', Version=1, Params=params)
15250 params['Entities'] = entities
15251 reply = await self.rpc(msg)
15252 return reply
15253
15254
15255
15256 @ReturnMapping(NotifyWatchResults)
15257 async def WatchForProxyConfigAndAPIHostPortChanges(self, entities):
15258 '''
15259 entities : typing.Sequence[~Entity]
15260 Returns -> typing.Sequence[~NotifyWatchResult]
15261 '''
15262 # map input types to rpc msg
15263 params = dict()
15264 msg = dict(Type='ProxyUpdater', Request='WatchForProxyConfigAndAPIHostPortChanges', Version=1, Params=params)
15265 params['Entities'] = entities
15266 reply = await self.rpc(msg)
15267 return reply
15268
15269
15270 class RebootFacade(Type):
15271 name = 'Reboot'
15272 version = 2
15273 schema = {'definitions': {'Entities': {'additionalProperties': False,
15274 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
15275 'type': 'array'}},
15276 'required': ['Entities'],
15277 'type': 'object'},
15278 'Entity': {'additionalProperties': False,
15279 'properties': {'Tag': {'type': 'string'}},
15280 'required': ['Tag'],
15281 'type': 'object'},
15282 'Error': {'additionalProperties': False,
15283 'properties': {'Code': {'type': 'string'},
15284 'Info': {'$ref': '#/definitions/ErrorInfo'},
15285 'Message': {'type': 'string'}},
15286 'required': ['Message', 'Code'],
15287 'type': 'object'},
15288 'ErrorInfo': {'additionalProperties': False,
15289 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15290 'MacaroonPath': {'type': 'string'}},
15291 'type': 'object'},
15292 'ErrorResult': {'additionalProperties': False,
15293 'properties': {'Error': {'$ref': '#/definitions/Error'}},
15294 'required': ['Error'],
15295 'type': 'object'},
15296 'ErrorResults': {'additionalProperties': False,
15297 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
15298 'type': 'array'}},
15299 'required': ['Results'],
15300 'type': 'object'},
15301 'Macaroon': {'additionalProperties': False,
15302 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15303 'type': 'array'},
15304 'data': {'items': {'type': 'integer'},
15305 'type': 'array'},
15306 'id': {'$ref': '#/definitions/packet'},
15307 'location': {'$ref': '#/definitions/packet'},
15308 'sig': {'items': {'type': 'integer'},
15309 'type': 'array'}},
15310 'required': ['data',
15311 'location',
15312 'id',
15313 'caveats',
15314 'sig'],
15315 'type': 'object'},
15316 'NotifyWatchResult': {'additionalProperties': False,
15317 'properties': {'Error': {'$ref': '#/definitions/Error'},
15318 'NotifyWatcherId': {'type': 'string'}},
15319 'required': ['NotifyWatcherId', 'Error'],
15320 'type': 'object'},
15321 'RebootActionResult': {'additionalProperties': False,
15322 'properties': {'error': {'$ref': '#/definitions/Error'},
15323 'result': {'type': 'string'}},
15324 'type': 'object'},
15325 'RebootActionResults': {'additionalProperties': False,
15326 'properties': {'results': {'items': {'$ref': '#/definitions/RebootActionResult'},
15327 'type': 'array'}},
15328 'type': 'object'},
15329 'caveat': {'additionalProperties': False,
15330 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15331 'location': {'$ref': '#/definitions/packet'},
15332 'verificationId': {'$ref': '#/definitions/packet'}},
15333 'required': ['location',
15334 'caveatId',
15335 'verificationId'],
15336 'type': 'object'},
15337 'packet': {'additionalProperties': False,
15338 'properties': {'headerLen': {'type': 'integer'},
15339 'start': {'type': 'integer'},
15340 'totalLen': {'type': 'integer'}},
15341 'required': ['start', 'totalLen', 'headerLen'],
15342 'type': 'object'}},
15343 'properties': {'ClearReboot': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15344 'Result': {'$ref': '#/definitions/ErrorResults'}},
15345 'type': 'object'},
15346 'GetRebootAction': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15347 'Result': {'$ref': '#/definitions/RebootActionResults'}},
15348 'type': 'object'},
15349 'RequestReboot': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15350 'Result': {'$ref': '#/definitions/ErrorResults'}},
15351 'type': 'object'},
15352 'WatchForRebootEvent': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
15353 'type': 'object'}},
15354 'type': 'object'}
15355
15356
15357 @ReturnMapping(ErrorResults)
15358 async def ClearReboot(self, entities):
15359 '''
15360 entities : typing.Sequence[~Entity]
15361 Returns -> typing.Sequence[~ErrorResult]
15362 '''
15363 # map input types to rpc msg
15364 params = dict()
15365 msg = dict(Type='Reboot', Request='ClearReboot', Version=2, Params=params)
15366 params['Entities'] = entities
15367 reply = await self.rpc(msg)
15368 return reply
15369
15370
15371
15372 @ReturnMapping(RebootActionResults)
15373 async def GetRebootAction(self, entities):
15374 '''
15375 entities : typing.Sequence[~Entity]
15376 Returns -> typing.Sequence[~RebootActionResult]
15377 '''
15378 # map input types to rpc msg
15379 params = dict()
15380 msg = dict(Type='Reboot', Request='GetRebootAction', Version=2, Params=params)
15381 params['Entities'] = entities
15382 reply = await self.rpc(msg)
15383 return reply
15384
15385
15386
15387 @ReturnMapping(ErrorResults)
15388 async def RequestReboot(self, entities):
15389 '''
15390 entities : typing.Sequence[~Entity]
15391 Returns -> typing.Sequence[~ErrorResult]
15392 '''
15393 # map input types to rpc msg
15394 params = dict()
15395 msg = dict(Type='Reboot', Request='RequestReboot', Version=2, Params=params)
15396 params['Entities'] = entities
15397 reply = await self.rpc(msg)
15398 return reply
15399
15400
15401
15402 @ReturnMapping(NotifyWatchResult)
15403 async def WatchForRebootEvent(self):
15404 '''
15405
15406 Returns -> typing.Union[_ForwardRef('Error'), str]
15407 '''
15408 # map input types to rpc msg
15409 params = dict()
15410 msg = dict(Type='Reboot', Request='WatchForRebootEvent', Version=2, Params=params)
15411
15412 reply = await self.rpc(msg)
15413 return reply
15414
15415
15416 class RelationUnitsWatcherFacade(Type):
15417 name = 'RelationUnitsWatcher'
15418 version = 1
15419 schema = {'definitions': {'Error': {'additionalProperties': False,
15420 'properties': {'Code': {'type': 'string'},
15421 'Info': {'$ref': '#/definitions/ErrorInfo'},
15422 'Message': {'type': 'string'}},
15423 'required': ['Message', 'Code'],
15424 'type': 'object'},
15425 'ErrorInfo': {'additionalProperties': False,
15426 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15427 'MacaroonPath': {'type': 'string'}},
15428 'type': 'object'},
15429 'Macaroon': {'additionalProperties': False,
15430 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15431 'type': 'array'},
15432 'data': {'items': {'type': 'integer'},
15433 'type': 'array'},
15434 'id': {'$ref': '#/definitions/packet'},
15435 'location': {'$ref': '#/definitions/packet'},
15436 'sig': {'items': {'type': 'integer'},
15437 'type': 'array'}},
15438 'required': ['data',
15439 'location',
15440 'id',
15441 'caveats',
15442 'sig'],
15443 'type': 'object'},
15444 'RelationUnitsChange': {'additionalProperties': False,
15445 'properties': {'Changed': {'patternProperties': {'.*': {'$ref': '#/definitions/UnitSettings'}},
15446 'type': 'object'},
15447 'Departed': {'items': {'type': 'string'},
15448 'type': 'array'}},
15449 'required': ['Changed', 'Departed'],
15450 'type': 'object'},
15451 'RelationUnitsWatchResult': {'additionalProperties': False,
15452 'properties': {'Changes': {'$ref': '#/definitions/RelationUnitsChange'},
15453 'Error': {'$ref': '#/definitions/Error'},
15454 'RelationUnitsWatcherId': {'type': 'string'}},
15455 'required': ['RelationUnitsWatcherId',
15456 'Changes',
15457 'Error'],
15458 'type': 'object'},
15459 'UnitSettings': {'additionalProperties': False,
15460 'properties': {'Version': {'type': 'integer'}},
15461 'required': ['Version'],
15462 'type': 'object'},
15463 'caveat': {'additionalProperties': False,
15464 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15465 'location': {'$ref': '#/definitions/packet'},
15466 'verificationId': {'$ref': '#/definitions/packet'}},
15467 'required': ['location',
15468 'caveatId',
15469 'verificationId'],
15470 'type': 'object'},
15471 'packet': {'additionalProperties': False,
15472 'properties': {'headerLen': {'type': 'integer'},
15473 'start': {'type': 'integer'},
15474 'totalLen': {'type': 'integer'}},
15475 'required': ['start', 'totalLen', 'headerLen'],
15476 'type': 'object'}},
15477 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/RelationUnitsWatchResult'}},
15478 'type': 'object'},
15479 'Stop': {'type': 'object'}},
15480 'type': 'object'}
15481
15482
15483 @ReturnMapping(RelationUnitsWatchResult)
15484 async def Next(self):
15485 '''
15486
15487 Returns -> typing.Union[_ForwardRef('RelationUnitsChange'), _ForwardRef('Error'), str]
15488 '''
15489 # map input types to rpc msg
15490 params = dict()
15491 msg = dict(Type='RelationUnitsWatcher', Request='Next', Version=1, Params=params)
15492
15493 reply = await self.rpc(msg)
15494 return reply
15495
15496
15497
15498 @ReturnMapping(None)
15499 async def Stop(self):
15500 '''
15501
15502 Returns -> None
15503 '''
15504 # map input types to rpc msg
15505 params = dict()
15506 msg = dict(Type='RelationUnitsWatcher', Request='Stop', Version=1, Params=params)
15507
15508 reply = await self.rpc(msg)
15509 return reply
15510
15511
15512 class ResumerFacade(Type):
15513 name = 'Resumer'
15514 version = 2
15515 schema = {'properties': {'ResumeTransactions': {'type': 'object'}}, 'type': 'object'}
15516
15517
15518 @ReturnMapping(None)
15519 async def ResumeTransactions(self):
15520 '''
15521
15522 Returns -> None
15523 '''
15524 # map input types to rpc msg
15525 params = dict()
15526 msg = dict(Type='Resumer', Request='ResumeTransactions', Version=2, Params=params)
15527
15528 reply = await self.rpc(msg)
15529 return reply
15530
15531
15532 class RetryStrategyFacade(Type):
15533 name = 'RetryStrategy'
15534 version = 1
15535 schema = {'definitions': {'Entities': {'additionalProperties': False,
15536 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
15537 'type': 'array'}},
15538 'required': ['Entities'],
15539 'type': 'object'},
15540 'Entity': {'additionalProperties': False,
15541 'properties': {'Tag': {'type': 'string'}},
15542 'required': ['Tag'],
15543 'type': 'object'},
15544 'Error': {'additionalProperties': False,
15545 'properties': {'Code': {'type': 'string'},
15546 'Info': {'$ref': '#/definitions/ErrorInfo'},
15547 'Message': {'type': 'string'}},
15548 'required': ['Message', 'Code'],
15549 'type': 'object'},
15550 'ErrorInfo': {'additionalProperties': False,
15551 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15552 'MacaroonPath': {'type': 'string'}},
15553 'type': 'object'},
15554 'Macaroon': {'additionalProperties': False,
15555 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15556 'type': 'array'},
15557 'data': {'items': {'type': 'integer'},
15558 'type': 'array'},
15559 'id': {'$ref': '#/definitions/packet'},
15560 'location': {'$ref': '#/definitions/packet'},
15561 'sig': {'items': {'type': 'integer'},
15562 'type': 'array'}},
15563 'required': ['data',
15564 'location',
15565 'id',
15566 'caveats',
15567 'sig'],
15568 'type': 'object'},
15569 'NotifyWatchResult': {'additionalProperties': False,
15570 'properties': {'Error': {'$ref': '#/definitions/Error'},
15571 'NotifyWatcherId': {'type': 'string'}},
15572 'required': ['NotifyWatcherId', 'Error'],
15573 'type': 'object'},
15574 'NotifyWatchResults': {'additionalProperties': False,
15575 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
15576 'type': 'array'}},
15577 'required': ['Results'],
15578 'type': 'object'},
15579 'RetryStrategy': {'additionalProperties': False,
15580 'properties': {'JitterRetryTime': {'type': 'boolean'},
15581 'MaxRetryTime': {'type': 'integer'},
15582 'MinRetryTime': {'type': 'integer'},
15583 'RetryTimeFactor': {'type': 'integer'},
15584 'ShouldRetry': {'type': 'boolean'}},
15585 'required': ['ShouldRetry',
15586 'MinRetryTime',
15587 'MaxRetryTime',
15588 'JitterRetryTime',
15589 'RetryTimeFactor'],
15590 'type': 'object'},
15591 'RetryStrategyResult': {'additionalProperties': False,
15592 'properties': {'Error': {'$ref': '#/definitions/Error'},
15593 'Result': {'$ref': '#/definitions/RetryStrategy'}},
15594 'required': ['Error', 'Result'],
15595 'type': 'object'},
15596 'RetryStrategyResults': {'additionalProperties': False,
15597 'properties': {'Results': {'items': {'$ref': '#/definitions/RetryStrategyResult'},
15598 'type': 'array'}},
15599 'required': ['Results'],
15600 'type': 'object'},
15601 'caveat': {'additionalProperties': False,
15602 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15603 'location': {'$ref': '#/definitions/packet'},
15604 'verificationId': {'$ref': '#/definitions/packet'}},
15605 'required': ['location',
15606 'caveatId',
15607 'verificationId'],
15608 'type': 'object'},
15609 'packet': {'additionalProperties': False,
15610 'properties': {'headerLen': {'type': 'integer'},
15611 'start': {'type': 'integer'},
15612 'totalLen': {'type': 'integer'}},
15613 'required': ['start', 'totalLen', 'headerLen'],
15614 'type': 'object'}},
15615 'properties': {'RetryStrategy': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15616 'Result': {'$ref': '#/definitions/RetryStrategyResults'}},
15617 'type': 'object'},
15618 'WatchRetryStrategy': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15619 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
15620 'type': 'object'}},
15621 'type': 'object'}
15622
15623
15624 @ReturnMapping(RetryStrategyResults)
15625 async def RetryStrategy(self, entities):
15626 '''
15627 entities : typing.Sequence[~Entity]
15628 Returns -> typing.Sequence[~RetryStrategyResult]
15629 '''
15630 # map input types to rpc msg
15631 params = dict()
15632 msg = dict(Type='RetryStrategy', Request='RetryStrategy', Version=1, Params=params)
15633 params['Entities'] = entities
15634 reply = await self.rpc(msg)
15635 return reply
15636
15637
15638
15639 @ReturnMapping(NotifyWatchResults)
15640 async def WatchRetryStrategy(self, entities):
15641 '''
15642 entities : typing.Sequence[~Entity]
15643 Returns -> typing.Sequence[~NotifyWatchResult]
15644 '''
15645 # map input types to rpc msg
15646 params = dict()
15647 msg = dict(Type='RetryStrategy', Request='WatchRetryStrategy', Version=1, Params=params)
15648 params['Entities'] = entities
15649 reply = await self.rpc(msg)
15650 return reply
15651
15652
15653 class SSHClientFacade(Type):
15654 name = 'SSHClient'
15655 version = 1
15656 schema = {'definitions': {'Entities': {'additionalProperties': False,
15657 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
15658 'type': 'array'}},
15659 'required': ['Entities'],
15660 'type': 'object'},
15661 'Entity': {'additionalProperties': False,
15662 'properties': {'Tag': {'type': 'string'}},
15663 'required': ['Tag'],
15664 'type': 'object'},
15665 'Error': {'additionalProperties': False,
15666 'properties': {'Code': {'type': 'string'},
15667 'Info': {'$ref': '#/definitions/ErrorInfo'},
15668 'Message': {'type': 'string'}},
15669 'required': ['Message', 'Code'],
15670 'type': 'object'},
15671 'ErrorInfo': {'additionalProperties': False,
15672 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15673 'MacaroonPath': {'type': 'string'}},
15674 'type': 'object'},
15675 'Macaroon': {'additionalProperties': False,
15676 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15677 'type': 'array'},
15678 'data': {'items': {'type': 'integer'},
15679 'type': 'array'},
15680 'id': {'$ref': '#/definitions/packet'},
15681 'location': {'$ref': '#/definitions/packet'},
15682 'sig': {'items': {'type': 'integer'},
15683 'type': 'array'}},
15684 'required': ['data',
15685 'location',
15686 'id',
15687 'caveats',
15688 'sig'],
15689 'type': 'object'},
15690 'SSHAddressResult': {'additionalProperties': False,
15691 'properties': {'address': {'type': 'string'},
15692 'error': {'$ref': '#/definitions/Error'}},
15693 'type': 'object'},
15694 'SSHAddressResults': {'additionalProperties': False,
15695 'properties': {'results': {'items': {'$ref': '#/definitions/SSHAddressResult'},
15696 'type': 'array'}},
15697 'required': ['results'],
15698 'type': 'object'},
15699 'SSHProxyResult': {'additionalProperties': False,
15700 'properties': {'use-proxy': {'type': 'boolean'}},
15701 'required': ['use-proxy'],
15702 'type': 'object'},
15703 'SSHPublicKeysResult': {'additionalProperties': False,
15704 'properties': {'error': {'$ref': '#/definitions/Error'},
15705 'public-keys': {'items': {'type': 'string'},
15706 'type': 'array'}},
15707 'type': 'object'},
15708 'SSHPublicKeysResults': {'additionalProperties': False,
15709 'properties': {'results': {'items': {'$ref': '#/definitions/SSHPublicKeysResult'},
15710 'type': 'array'}},
15711 'required': ['results'],
15712 'type': 'object'},
15713 'caveat': {'additionalProperties': False,
15714 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15715 'location': {'$ref': '#/definitions/packet'},
15716 'verificationId': {'$ref': '#/definitions/packet'}},
15717 'required': ['location',
15718 'caveatId',
15719 'verificationId'],
15720 'type': 'object'},
15721 'packet': {'additionalProperties': False,
15722 'properties': {'headerLen': {'type': 'integer'},
15723 'start': {'type': 'integer'},
15724 'totalLen': {'type': 'integer'}},
15725 'required': ['start', 'totalLen', 'headerLen'],
15726 'type': 'object'}},
15727 'properties': {'PrivateAddress': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15728 'Result': {'$ref': '#/definitions/SSHAddressResults'}},
15729 'type': 'object'},
15730 'Proxy': {'properties': {'Result': {'$ref': '#/definitions/SSHProxyResult'}},
15731 'type': 'object'},
15732 'PublicAddress': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15733 'Result': {'$ref': '#/definitions/SSHAddressResults'}},
15734 'type': 'object'},
15735 'PublicKeys': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15736 'Result': {'$ref': '#/definitions/SSHPublicKeysResults'}},
15737 'type': 'object'}},
15738 'type': 'object'}
15739
15740
15741 @ReturnMapping(SSHAddressResults)
15742 async def PrivateAddress(self, entities):
15743 '''
15744 entities : typing.Sequence[~Entity]
15745 Returns -> typing.Sequence[~SSHAddressResult]
15746 '''
15747 # map input types to rpc msg
15748 params = dict()
15749 msg = dict(Type='SSHClient', Request='PrivateAddress', Version=1, Params=params)
15750 params['Entities'] = entities
15751 reply = await self.rpc(msg)
15752 return reply
15753
15754
15755
15756 @ReturnMapping(SSHProxyResult)
15757 async def Proxy(self):
15758 '''
15759
15760 Returns -> bool
15761 '''
15762 # map input types to rpc msg
15763 params = dict()
15764 msg = dict(Type='SSHClient', Request='Proxy', Version=1, Params=params)
15765
15766 reply = await self.rpc(msg)
15767 return reply
15768
15769
15770
15771 @ReturnMapping(SSHAddressResults)
15772 async def PublicAddress(self, entities):
15773 '''
15774 entities : typing.Sequence[~Entity]
15775 Returns -> typing.Sequence[~SSHAddressResult]
15776 '''
15777 # map input types to rpc msg
15778 params = dict()
15779 msg = dict(Type='SSHClient', Request='PublicAddress', Version=1, Params=params)
15780 params['Entities'] = entities
15781 reply = await self.rpc(msg)
15782 return reply
15783
15784
15785
15786 @ReturnMapping(SSHPublicKeysResults)
15787 async def PublicKeys(self, entities):
15788 '''
15789 entities : typing.Sequence[~Entity]
15790 Returns -> typing.Sequence[~SSHPublicKeysResult]
15791 '''
15792 # map input types to rpc msg
15793 params = dict()
15794 msg = dict(Type='SSHClient', Request='PublicKeys', Version=1, Params=params)
15795 params['Entities'] = entities
15796 reply = await self.rpc(msg)
15797 return reply
15798
15799
15800 class SingularFacade(Type):
15801 name = 'Singular'
15802 version = 1
15803 schema = {'definitions': {'Entities': {'additionalProperties': False,
15804 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
15805 'type': 'array'}},
15806 'required': ['Entities'],
15807 'type': 'object'},
15808 'Entity': {'additionalProperties': False,
15809 'properties': {'Tag': {'type': 'string'}},
15810 'required': ['Tag'],
15811 'type': 'object'},
15812 'Error': {'additionalProperties': False,
15813 'properties': {'Code': {'type': 'string'},
15814 'Info': {'$ref': '#/definitions/ErrorInfo'},
15815 'Message': {'type': 'string'}},
15816 'required': ['Message', 'Code'],
15817 'type': 'object'},
15818 'ErrorInfo': {'additionalProperties': False,
15819 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15820 'MacaroonPath': {'type': 'string'}},
15821 'type': 'object'},
15822 'ErrorResult': {'additionalProperties': False,
15823 'properties': {'Error': {'$ref': '#/definitions/Error'}},
15824 'required': ['Error'],
15825 'type': 'object'},
15826 'ErrorResults': {'additionalProperties': False,
15827 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
15828 'type': 'array'}},
15829 'required': ['Results'],
15830 'type': 'object'},
15831 'Macaroon': {'additionalProperties': False,
15832 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15833 'type': 'array'},
15834 'data': {'items': {'type': 'integer'},
15835 'type': 'array'},
15836 'id': {'$ref': '#/definitions/packet'},
15837 'location': {'$ref': '#/definitions/packet'},
15838 'sig': {'items': {'type': 'integer'},
15839 'type': 'array'}},
15840 'required': ['data',
15841 'location',
15842 'id',
15843 'caveats',
15844 'sig'],
15845 'type': 'object'},
15846 'SingularClaim': {'additionalProperties': False,
15847 'properties': {'ControllerTag': {'type': 'string'},
15848 'Duration': {'type': 'integer'},
15849 'ModelTag': {'type': 'string'}},
15850 'required': ['ModelTag',
15851 'ControllerTag',
15852 'Duration'],
15853 'type': 'object'},
15854 'SingularClaims': {'additionalProperties': False,
15855 'properties': {'Claims': {'items': {'$ref': '#/definitions/SingularClaim'},
15856 'type': 'array'}},
15857 'required': ['Claims'],
15858 'type': 'object'},
15859 'caveat': {'additionalProperties': False,
15860 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15861 'location': {'$ref': '#/definitions/packet'},
15862 'verificationId': {'$ref': '#/definitions/packet'}},
15863 'required': ['location',
15864 'caveatId',
15865 'verificationId'],
15866 'type': 'object'},
15867 'packet': {'additionalProperties': False,
15868 'properties': {'headerLen': {'type': 'integer'},
15869 'start': {'type': 'integer'},
15870 'totalLen': {'type': 'integer'}},
15871 'required': ['start', 'totalLen', 'headerLen'],
15872 'type': 'object'}},
15873 'properties': {'Claim': {'properties': {'Params': {'$ref': '#/definitions/SingularClaims'},
15874 'Result': {'$ref': '#/definitions/ErrorResults'}},
15875 'type': 'object'},
15876 'Wait': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
15877 'Result': {'$ref': '#/definitions/ErrorResults'}},
15878 'type': 'object'}},
15879 'type': 'object'}
15880
15881
15882 @ReturnMapping(ErrorResults)
15883 async def Claim(self, claims):
15884 '''
15885 claims : typing.Sequence[~SingularClaim]
15886 Returns -> typing.Sequence[~ErrorResult]
15887 '''
15888 # map input types to rpc msg
15889 params = dict()
15890 msg = dict(Type='Singular', Request='Claim', Version=1, Params=params)
15891 params['Claims'] = claims
15892 reply = await self.rpc(msg)
15893 return reply
15894
15895
15896
15897 @ReturnMapping(ErrorResults)
15898 async def Wait(self, entities):
15899 '''
15900 entities : typing.Sequence[~Entity]
15901 Returns -> typing.Sequence[~ErrorResult]
15902 '''
15903 # map input types to rpc msg
15904 params = dict()
15905 msg = dict(Type='Singular', Request='Wait', Version=1, Params=params)
15906 params['Entities'] = entities
15907 reply = await self.rpc(msg)
15908 return reply
15909
15910
15911 class SpacesFacade(Type):
15912 name = 'Spaces'
15913 version = 2
15914 schema = {'definitions': {'CreateSpaceParams': {'additionalProperties': False,
15915 'properties': {'ProviderId': {'type': 'string'},
15916 'Public': {'type': 'boolean'},
15917 'SpaceTag': {'type': 'string'},
15918 'SubnetTags': {'items': {'type': 'string'},
15919 'type': 'array'}},
15920 'required': ['SubnetTags',
15921 'SpaceTag',
15922 'Public'],
15923 'type': 'object'},
15924 'CreateSpacesParams': {'additionalProperties': False,
15925 'properties': {'Spaces': {'items': {'$ref': '#/definitions/CreateSpaceParams'},
15926 'type': 'array'}},
15927 'required': ['Spaces'],
15928 'type': 'object'},
15929 'Error': {'additionalProperties': False,
15930 'properties': {'Code': {'type': 'string'},
15931 'Info': {'$ref': '#/definitions/ErrorInfo'},
15932 'Message': {'type': 'string'}},
15933 'required': ['Message', 'Code'],
15934 'type': 'object'},
15935 'ErrorInfo': {'additionalProperties': False,
15936 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
15937 'MacaroonPath': {'type': 'string'}},
15938 'type': 'object'},
15939 'ErrorResult': {'additionalProperties': False,
15940 'properties': {'Error': {'$ref': '#/definitions/Error'}},
15941 'required': ['Error'],
15942 'type': 'object'},
15943 'ErrorResults': {'additionalProperties': False,
15944 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
15945 'type': 'array'}},
15946 'required': ['Results'],
15947 'type': 'object'},
15948 'ListSpacesResults': {'additionalProperties': False,
15949 'properties': {'Results': {'items': {'$ref': '#/definitions/Space'},
15950 'type': 'array'}},
15951 'required': ['Results'],
15952 'type': 'object'},
15953 'Macaroon': {'additionalProperties': False,
15954 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
15955 'type': 'array'},
15956 'data': {'items': {'type': 'integer'},
15957 'type': 'array'},
15958 'id': {'$ref': '#/definitions/packet'},
15959 'location': {'$ref': '#/definitions/packet'},
15960 'sig': {'items': {'type': 'integer'},
15961 'type': 'array'}},
15962 'required': ['data',
15963 'location',
15964 'id',
15965 'caveats',
15966 'sig'],
15967 'type': 'object'},
15968 'Space': {'additionalProperties': False,
15969 'properties': {'Error': {'$ref': '#/definitions/Error'},
15970 'Name': {'type': 'string'},
15971 'Subnets': {'items': {'$ref': '#/definitions/Subnet'},
15972 'type': 'array'}},
15973 'required': ['Name', 'Subnets'],
15974 'type': 'object'},
15975 'Subnet': {'additionalProperties': False,
15976 'properties': {'CIDR': {'type': 'string'},
15977 'Life': {'type': 'string'},
15978 'ProviderId': {'type': 'string'},
15979 'SpaceTag': {'type': 'string'},
15980 'StaticRangeHighIP': {'items': {'type': 'integer'},
15981 'type': 'array'},
15982 'StaticRangeLowIP': {'items': {'type': 'integer'},
15983 'type': 'array'},
15984 'Status': {'type': 'string'},
15985 'VLANTag': {'type': 'integer'},
15986 'Zones': {'items': {'type': 'string'},
15987 'type': 'array'}},
15988 'required': ['CIDR',
15989 'VLANTag',
15990 'Life',
15991 'SpaceTag',
15992 'Zones'],
15993 'type': 'object'},
15994 'caveat': {'additionalProperties': False,
15995 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
15996 'location': {'$ref': '#/definitions/packet'},
15997 'verificationId': {'$ref': '#/definitions/packet'}},
15998 'required': ['location',
15999 'caveatId',
16000 'verificationId'],
16001 'type': 'object'},
16002 'packet': {'additionalProperties': False,
16003 'properties': {'headerLen': {'type': 'integer'},
16004 'start': {'type': 'integer'},
16005 'totalLen': {'type': 'integer'}},
16006 'required': ['start', 'totalLen', 'headerLen'],
16007 'type': 'object'}},
16008 'properties': {'CreateSpaces': {'properties': {'Params': {'$ref': '#/definitions/CreateSpacesParams'},
16009 'Result': {'$ref': '#/definitions/ErrorResults'}},
16010 'type': 'object'},
16011 'ListSpaces': {'properties': {'Result': {'$ref': '#/definitions/ListSpacesResults'}},
16012 'type': 'object'}},
16013 'type': 'object'}
16014
16015
16016 @ReturnMapping(ErrorResults)
16017 async def CreateSpaces(self, spaces):
16018 '''
16019 spaces : typing.Sequence[~CreateSpaceParams]
16020 Returns -> typing.Sequence[~ErrorResult]
16021 '''
16022 # map input types to rpc msg
16023 params = dict()
16024 msg = dict(Type='Spaces', Request='CreateSpaces', Version=2, Params=params)
16025 params['Spaces'] = spaces
16026 reply = await self.rpc(msg)
16027 return reply
16028
16029
16030
16031 @ReturnMapping(ListSpacesResults)
16032 async def ListSpaces(self):
16033 '''
16034
16035 Returns -> typing.Sequence[~Space]
16036 '''
16037 # map input types to rpc msg
16038 params = dict()
16039 msg = dict(Type='Spaces', Request='ListSpaces', Version=2, Params=params)
16040
16041 reply = await self.rpc(msg)
16042 return reply
16043
16044
16045 class StatusHistoryFacade(Type):
16046 name = 'StatusHistory'
16047 version = 2
16048 schema = {'definitions': {'StatusHistoryPruneArgs': {'additionalProperties': False,
16049 'properties': {'MaxHistoryMB': {'type': 'integer'},
16050 'MaxHistoryTime': {'type': 'integer'}},
16051 'required': ['MaxHistoryTime',
16052 'MaxHistoryMB'],
16053 'type': 'object'}},
16054 'properties': {'Prune': {'properties': {'Params': {'$ref': '#/definitions/StatusHistoryPruneArgs'}},
16055 'type': 'object'}},
16056 'type': 'object'}
16057
16058
16059 @ReturnMapping(None)
16060 async def Prune(self, maxhistorymb, maxhistorytime):
16061 '''
16062 maxhistorymb : int
16063 maxhistorytime : int
16064 Returns -> None
16065 '''
16066 # map input types to rpc msg
16067 params = dict()
16068 msg = dict(Type='StatusHistory', Request='Prune', Version=2, Params=params)
16069 params['MaxHistoryMB'] = maxhistorymb
16070 params['MaxHistoryTime'] = maxhistorytime
16071 reply = await self.rpc(msg)
16072 return reply
16073
16074
16075 class StorageFacade(Type):
16076 name = 'Storage'
16077 version = 2
16078 schema = {'definitions': {'Entities': {'additionalProperties': False,
16079 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
16080 'type': 'array'}},
16081 'required': ['Entities'],
16082 'type': 'object'},
16083 'Entity': {'additionalProperties': False,
16084 'properties': {'Tag': {'type': 'string'}},
16085 'required': ['Tag'],
16086 'type': 'object'},
16087 'EntityStatus': {'additionalProperties': False,
16088 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
16089 'type': 'object'}},
16090 'type': 'object'},
16091 'Info': {'type': 'string'},
16092 'Since': {'format': 'date-time',
16093 'type': 'string'},
16094 'Status': {'type': 'string'}},
16095 'required': ['Status',
16096 'Info',
16097 'Data',
16098 'Since'],
16099 'type': 'object'},
16100 'Error': {'additionalProperties': False,
16101 'properties': {'Code': {'type': 'string'},
16102 'Info': {'$ref': '#/definitions/ErrorInfo'},
16103 'Message': {'type': 'string'}},
16104 'required': ['Message', 'Code'],
16105 'type': 'object'},
16106 'ErrorInfo': {'additionalProperties': False,
16107 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
16108 'MacaroonPath': {'type': 'string'}},
16109 'type': 'object'},
16110 'ErrorResult': {'additionalProperties': False,
16111 'properties': {'Error': {'$ref': '#/definitions/Error'}},
16112 'required': ['Error'],
16113 'type': 'object'},
16114 'ErrorResults': {'additionalProperties': False,
16115 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
16116 'type': 'array'}},
16117 'required': ['Results'],
16118 'type': 'object'},
16119 'FilesystemAttachmentInfo': {'additionalProperties': False,
16120 'properties': {'mountpoint': {'type': 'string'},
16121 'read-only': {'type': 'boolean'}},
16122 'type': 'object'},
16123 'FilesystemDetails': {'additionalProperties': False,
16124 'properties': {'filesystemtag': {'type': 'string'},
16125 'info': {'$ref': '#/definitions/FilesystemInfo'},
16126 'machineattachments': {'patternProperties': {'.*': {'$ref': '#/definitions/FilesystemAttachmentInfo'}},
16127 'type': 'object'},
16128 'status': {'$ref': '#/definitions/EntityStatus'},
16129 'storage': {'$ref': '#/definitions/StorageDetails'},
16130 'volumetag': {'type': 'string'}},
16131 'required': ['filesystemtag',
16132 'info',
16133 'status'],
16134 'type': 'object'},
16135 'FilesystemDetailsListResult': {'additionalProperties': False,
16136 'properties': {'error': {'$ref': '#/definitions/Error'},
16137 'result': {'items': {'$ref': '#/definitions/FilesystemDetails'},
16138 'type': 'array'}},
16139 'type': 'object'},
16140 'FilesystemDetailsListResults': {'additionalProperties': False,
16141 'properties': {'results': {'items': {'$ref': '#/definitions/FilesystemDetailsListResult'},
16142 'type': 'array'}},
16143 'type': 'object'},
16144 'FilesystemFilter': {'additionalProperties': False,
16145 'properties': {'machines': {'items': {'type': 'string'},
16146 'type': 'array'}},
16147 'type': 'object'},
16148 'FilesystemFilters': {'additionalProperties': False,
16149 'properties': {'filters': {'items': {'$ref': '#/definitions/FilesystemFilter'},
16150 'type': 'array'}},
16151 'type': 'object'},
16152 'FilesystemInfo': {'additionalProperties': False,
16153 'properties': {'filesystemid': {'type': 'string'},
16154 'size': {'type': 'integer'}},
16155 'required': ['filesystemid', 'size'],
16156 'type': 'object'},
16157 'Macaroon': {'additionalProperties': False,
16158 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
16159 'type': 'array'},
16160 'data': {'items': {'type': 'integer'},
16161 'type': 'array'},
16162 'id': {'$ref': '#/definitions/packet'},
16163 'location': {'$ref': '#/definitions/packet'},
16164 'sig': {'items': {'type': 'integer'},
16165 'type': 'array'}},
16166 'required': ['data',
16167 'location',
16168 'id',
16169 'caveats',
16170 'sig'],
16171 'type': 'object'},
16172 'StorageAddParams': {'additionalProperties': False,
16173 'properties': {'StorageName': {'type': 'string'},
16174 'storage': {'$ref': '#/definitions/StorageConstraints'},
16175 'unit': {'type': 'string'}},
16176 'required': ['unit',
16177 'StorageName',
16178 'storage'],
16179 'type': 'object'},
16180 'StorageAttachmentDetails': {'additionalProperties': False,
16181 'properties': {'location': {'type': 'string'},
16182 'machinetag': {'type': 'string'},
16183 'storagetag': {'type': 'string'},
16184 'unittag': {'type': 'string'}},
16185 'required': ['storagetag',
16186 'unittag',
16187 'machinetag'],
16188 'type': 'object'},
16189 'StorageConstraints': {'additionalProperties': False,
16190 'properties': {'Count': {'type': 'integer'},
16191 'Pool': {'type': 'string'},
16192 'Size': {'type': 'integer'}},
16193 'required': ['Pool', 'Size', 'Count'],
16194 'type': 'object'},
16195 'StorageDetails': {'additionalProperties': False,
16196 'properties': {'Persistent': {'type': 'boolean'},
16197 'attachments': {'patternProperties': {'.*': {'$ref': '#/definitions/StorageAttachmentDetails'}},
16198 'type': 'object'},
16199 'kind': {'type': 'integer'},
16200 'ownertag': {'type': 'string'},
16201 'status': {'$ref': '#/definitions/EntityStatus'},
16202 'storagetag': {'type': 'string'}},
16203 'required': ['storagetag',
16204 'ownertag',
16205 'kind',
16206 'status',
16207 'Persistent'],
16208 'type': 'object'},
16209 'StorageDetailsListResult': {'additionalProperties': False,
16210 'properties': {'error': {'$ref': '#/definitions/Error'},
16211 'result': {'items': {'$ref': '#/definitions/StorageDetails'},
16212 'type': 'array'}},
16213 'type': 'object'},
16214 'StorageDetailsListResults': {'additionalProperties': False,
16215 'properties': {'results': {'items': {'$ref': '#/definitions/StorageDetailsListResult'},
16216 'type': 'array'}},
16217 'type': 'object'},
16218 'StorageDetailsResult': {'additionalProperties': False,
16219 'properties': {'error': {'$ref': '#/definitions/Error'},
16220 'result': {'$ref': '#/definitions/StorageDetails'}},
16221 'type': 'object'},
16222 'StorageDetailsResults': {'additionalProperties': False,
16223 'properties': {'results': {'items': {'$ref': '#/definitions/StorageDetailsResult'},
16224 'type': 'array'}},
16225 'type': 'object'},
16226 'StorageFilter': {'additionalProperties': False,
16227 'type': 'object'},
16228 'StorageFilters': {'additionalProperties': False,
16229 'properties': {'filters': {'items': {'$ref': '#/definitions/StorageFilter'},
16230 'type': 'array'}},
16231 'type': 'object'},
16232 'StoragePool': {'additionalProperties': False,
16233 'properties': {'attrs': {'patternProperties': {'.*': {'additionalProperties': True,
16234 'type': 'object'}},
16235 'type': 'object'},
16236 'name': {'type': 'string'},
16237 'provider': {'type': 'string'}},
16238 'required': ['name', 'provider', 'attrs'],
16239 'type': 'object'},
16240 'StoragePoolFilter': {'additionalProperties': False,
16241 'properties': {'names': {'items': {'type': 'string'},
16242 'type': 'array'},
16243 'providers': {'items': {'type': 'string'},
16244 'type': 'array'}},
16245 'type': 'object'},
16246 'StoragePoolFilters': {'additionalProperties': False,
16247 'properties': {'filters': {'items': {'$ref': '#/definitions/StoragePoolFilter'},
16248 'type': 'array'}},
16249 'type': 'object'},
16250 'StoragePoolsResult': {'additionalProperties': False,
16251 'properties': {'error': {'$ref': '#/definitions/Error'},
16252 'storagepools': {'items': {'$ref': '#/definitions/StoragePool'},
16253 'type': 'array'}},
16254 'type': 'object'},
16255 'StoragePoolsResults': {'additionalProperties': False,
16256 'properties': {'results': {'items': {'$ref': '#/definitions/StoragePoolsResult'},
16257 'type': 'array'}},
16258 'type': 'object'},
16259 'StoragesAddParams': {'additionalProperties': False,
16260 'properties': {'storages': {'items': {'$ref': '#/definitions/StorageAddParams'},
16261 'type': 'array'}},
16262 'required': ['storages'],
16263 'type': 'object'},
16264 'VolumeAttachmentInfo': {'additionalProperties': False,
16265 'properties': {'busaddress': {'type': 'string'},
16266 'devicelink': {'type': 'string'},
16267 'devicename': {'type': 'string'},
16268 'read-only': {'type': 'boolean'}},
16269 'type': 'object'},
16270 'VolumeDetails': {'additionalProperties': False,
16271 'properties': {'info': {'$ref': '#/definitions/VolumeInfo'},
16272 'machineattachments': {'patternProperties': {'.*': {'$ref': '#/definitions/VolumeAttachmentInfo'}},
16273 'type': 'object'},
16274 'status': {'$ref': '#/definitions/EntityStatus'},
16275 'storage': {'$ref': '#/definitions/StorageDetails'},
16276 'volumetag': {'type': 'string'}},
16277 'required': ['volumetag', 'info', 'status'],
16278 'type': 'object'},
16279 'VolumeDetailsListResult': {'additionalProperties': False,
16280 'properties': {'error': {'$ref': '#/definitions/Error'},
16281 'result': {'items': {'$ref': '#/definitions/VolumeDetails'},
16282 'type': 'array'}},
16283 'type': 'object'},
16284 'VolumeDetailsListResults': {'additionalProperties': False,
16285 'properties': {'results': {'items': {'$ref': '#/definitions/VolumeDetailsListResult'},
16286 'type': 'array'}},
16287 'type': 'object'},
16288 'VolumeFilter': {'additionalProperties': False,
16289 'properties': {'machines': {'items': {'type': 'string'},
16290 'type': 'array'}},
16291 'type': 'object'},
16292 'VolumeFilters': {'additionalProperties': False,
16293 'properties': {'filters': {'items': {'$ref': '#/definitions/VolumeFilter'},
16294 'type': 'array'}},
16295 'type': 'object'},
16296 'VolumeInfo': {'additionalProperties': False,
16297 'properties': {'hardwareid': {'type': 'string'},
16298 'persistent': {'type': 'boolean'},
16299 'size': {'type': 'integer'},
16300 'volumeid': {'type': 'string'}},
16301 'required': ['volumeid', 'size', 'persistent'],
16302 'type': 'object'},
16303 'caveat': {'additionalProperties': False,
16304 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
16305 'location': {'$ref': '#/definitions/packet'},
16306 'verificationId': {'$ref': '#/definitions/packet'}},
16307 'required': ['location',
16308 'caveatId',
16309 'verificationId'],
16310 'type': 'object'},
16311 'packet': {'additionalProperties': False,
16312 'properties': {'headerLen': {'type': 'integer'},
16313 'start': {'type': 'integer'},
16314 'totalLen': {'type': 'integer'}},
16315 'required': ['start', 'totalLen', 'headerLen'],
16316 'type': 'object'}},
16317 'properties': {'AddToUnit': {'properties': {'Params': {'$ref': '#/definitions/StoragesAddParams'},
16318 'Result': {'$ref': '#/definitions/ErrorResults'}},
16319 'type': 'object'},
16320 'CreatePool': {'properties': {'Params': {'$ref': '#/definitions/StoragePool'}},
16321 'type': 'object'},
16322 'ListFilesystems': {'properties': {'Params': {'$ref': '#/definitions/FilesystemFilters'},
16323 'Result': {'$ref': '#/definitions/FilesystemDetailsListResults'}},
16324 'type': 'object'},
16325 'ListPools': {'properties': {'Params': {'$ref': '#/definitions/StoragePoolFilters'},
16326 'Result': {'$ref': '#/definitions/StoragePoolsResults'}},
16327 'type': 'object'},
16328 'ListStorageDetails': {'properties': {'Params': {'$ref': '#/definitions/StorageFilters'},
16329 'Result': {'$ref': '#/definitions/StorageDetailsListResults'}},
16330 'type': 'object'},
16331 'ListVolumes': {'properties': {'Params': {'$ref': '#/definitions/VolumeFilters'},
16332 'Result': {'$ref': '#/definitions/VolumeDetailsListResults'}},
16333 'type': 'object'},
16334 'StorageDetails': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16335 'Result': {'$ref': '#/definitions/StorageDetailsResults'}},
16336 'type': 'object'}},
16337 'type': 'object'}
16338
16339
16340 @ReturnMapping(ErrorResults)
16341 async def AddToUnit(self, storages):
16342 '''
16343 storages : typing.Sequence[~StorageAddParams]
16344 Returns -> typing.Sequence[~ErrorResult]
16345 '''
16346 # map input types to rpc msg
16347 params = dict()
16348 msg = dict(Type='Storage', Request='AddToUnit', Version=2, Params=params)
16349 params['storages'] = storages
16350 reply = await self.rpc(msg)
16351 return reply
16352
16353
16354
16355 @ReturnMapping(None)
16356 async def CreatePool(self, attrs, name, provider):
16357 '''
16358 attrs : typing.Mapping[str, typing.Any]
16359 name : str
16360 provider : str
16361 Returns -> None
16362 '''
16363 # map input types to rpc msg
16364 params = dict()
16365 msg = dict(Type='Storage', Request='CreatePool', Version=2, Params=params)
16366 params['attrs'] = attrs
16367 params['name'] = name
16368 params['provider'] = provider
16369 reply = await self.rpc(msg)
16370 return reply
16371
16372
16373
16374 @ReturnMapping(FilesystemDetailsListResults)
16375 async def ListFilesystems(self, filters):
16376 '''
16377 filters : typing.Sequence[~FilesystemFilter]
16378 Returns -> typing.Sequence[~FilesystemDetailsListResult]
16379 '''
16380 # map input types to rpc msg
16381 params = dict()
16382 msg = dict(Type='Storage', Request='ListFilesystems', Version=2, Params=params)
16383 params['filters'] = filters
16384 reply = await self.rpc(msg)
16385 return reply
16386
16387
16388
16389 @ReturnMapping(StoragePoolsResults)
16390 async def ListPools(self, filters):
16391 '''
16392 filters : typing.Sequence[~StoragePoolFilter]
16393 Returns -> typing.Sequence[~StoragePoolsResult]
16394 '''
16395 # map input types to rpc msg
16396 params = dict()
16397 msg = dict(Type='Storage', Request='ListPools', Version=2, Params=params)
16398 params['filters'] = filters
16399 reply = await self.rpc(msg)
16400 return reply
16401
16402
16403
16404 @ReturnMapping(StorageDetailsListResults)
16405 async def ListStorageDetails(self, filters):
16406 '''
16407 filters : typing.Sequence[~StorageFilter]
16408 Returns -> typing.Sequence[~StorageDetailsListResult]
16409 '''
16410 # map input types to rpc msg
16411 params = dict()
16412 msg = dict(Type='Storage', Request='ListStorageDetails', Version=2, Params=params)
16413 params['filters'] = filters
16414 reply = await self.rpc(msg)
16415 return reply
16416
16417
16418
16419 @ReturnMapping(VolumeDetailsListResults)
16420 async def ListVolumes(self, filters):
16421 '''
16422 filters : typing.Sequence[~VolumeFilter]
16423 Returns -> typing.Sequence[~VolumeDetailsListResult]
16424 '''
16425 # map input types to rpc msg
16426 params = dict()
16427 msg = dict(Type='Storage', Request='ListVolumes', Version=2, Params=params)
16428 params['filters'] = filters
16429 reply = await self.rpc(msg)
16430 return reply
16431
16432
16433
16434 @ReturnMapping(StorageDetailsResults)
16435 async def StorageDetails(self, entities):
16436 '''
16437 entities : typing.Sequence[~Entity]
16438 Returns -> typing.Sequence[~StorageDetailsResult]
16439 '''
16440 # map input types to rpc msg
16441 params = dict()
16442 msg = dict(Type='Storage', Request='StorageDetails', Version=2, Params=params)
16443 params['Entities'] = entities
16444 reply = await self.rpc(msg)
16445 return reply
16446
16447
16448 class StorageProvisionerFacade(Type):
16449 name = 'StorageProvisioner'
16450 version = 2
16451 schema = {'definitions': {'BlockDevice': {'additionalProperties': False,
16452 'properties': {'BusAddress': {'type': 'string'},
16453 'DeviceLinks': {'items': {'type': 'string'},
16454 'type': 'array'},
16455 'DeviceName': {'type': 'string'},
16456 'FilesystemType': {'type': 'string'},
16457 'HardwareId': {'type': 'string'},
16458 'InUse': {'type': 'boolean'},
16459 'Label': {'type': 'string'},
16460 'MountPoint': {'type': 'string'},
16461 'Size': {'type': 'integer'},
16462 'UUID': {'type': 'string'}},
16463 'required': ['DeviceName',
16464 'DeviceLinks',
16465 'Label',
16466 'UUID',
16467 'HardwareId',
16468 'BusAddress',
16469 'Size',
16470 'FilesystemType',
16471 'InUse',
16472 'MountPoint'],
16473 'type': 'object'},
16474 'BlockDeviceResult': {'additionalProperties': False,
16475 'properties': {'error': {'$ref': '#/definitions/Error'},
16476 'result': {'$ref': '#/definitions/BlockDevice'}},
16477 'required': ['result'],
16478 'type': 'object'},
16479 'BlockDeviceResults': {'additionalProperties': False,
16480 'properties': {'results': {'items': {'$ref': '#/definitions/BlockDeviceResult'},
16481 'type': 'array'}},
16482 'type': 'object'},
16483 'Entities': {'additionalProperties': False,
16484 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
16485 'type': 'array'}},
16486 'required': ['Entities'],
16487 'type': 'object'},
16488 'Entity': {'additionalProperties': False,
16489 'properties': {'Tag': {'type': 'string'}},
16490 'required': ['Tag'],
16491 'type': 'object'},
16492 'EntityStatusArgs': {'additionalProperties': False,
16493 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
16494 'type': 'object'}},
16495 'type': 'object'},
16496 'Info': {'type': 'string'},
16497 'Status': {'type': 'string'},
16498 'Tag': {'type': 'string'}},
16499 'required': ['Tag',
16500 'Status',
16501 'Info',
16502 'Data'],
16503 'type': 'object'},
16504 'Error': {'additionalProperties': False,
16505 'properties': {'Code': {'type': 'string'},
16506 'Info': {'$ref': '#/definitions/ErrorInfo'},
16507 'Message': {'type': 'string'}},
16508 'required': ['Message', 'Code'],
16509 'type': 'object'},
16510 'ErrorInfo': {'additionalProperties': False,
16511 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
16512 'MacaroonPath': {'type': 'string'}},
16513 'type': 'object'},
16514 'ErrorResult': {'additionalProperties': False,
16515 'properties': {'Error': {'$ref': '#/definitions/Error'}},
16516 'required': ['Error'],
16517 'type': 'object'},
16518 'ErrorResults': {'additionalProperties': False,
16519 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
16520 'type': 'array'}},
16521 'required': ['Results'],
16522 'type': 'object'},
16523 'Filesystem': {'additionalProperties': False,
16524 'properties': {'filesystemtag': {'type': 'string'},
16525 'info': {'$ref': '#/definitions/FilesystemInfo'},
16526 'volumetag': {'type': 'string'}},
16527 'required': ['filesystemtag', 'info'],
16528 'type': 'object'},
16529 'FilesystemAttachment': {'additionalProperties': False,
16530 'properties': {'filesystemtag': {'type': 'string'},
16531 'info': {'$ref': '#/definitions/FilesystemAttachmentInfo'},
16532 'machinetag': {'type': 'string'}},
16533 'required': ['filesystemtag',
16534 'machinetag',
16535 'info'],
16536 'type': 'object'},
16537 'FilesystemAttachmentInfo': {'additionalProperties': False,
16538 'properties': {'mountpoint': {'type': 'string'},
16539 'read-only': {'type': 'boolean'}},
16540 'type': 'object'},
16541 'FilesystemAttachmentParams': {'additionalProperties': False,
16542 'properties': {'filesystemid': {'type': 'string'},
16543 'filesystemtag': {'type': 'string'},
16544 'instanceid': {'type': 'string'},
16545 'machinetag': {'type': 'string'},
16546 'mountpoint': {'type': 'string'},
16547 'provider': {'type': 'string'},
16548 'read-only': {'type': 'boolean'}},
16549 'required': ['filesystemtag',
16550 'machinetag',
16551 'provider'],
16552 'type': 'object'},
16553 'FilesystemAttachmentParamsResult': {'additionalProperties': False,
16554 'properties': {'error': {'$ref': '#/definitions/Error'},
16555 'result': {'$ref': '#/definitions/FilesystemAttachmentParams'}},
16556 'required': ['result'],
16557 'type': 'object'},
16558 'FilesystemAttachmentParamsResults': {'additionalProperties': False,
16559 'properties': {'results': {'items': {'$ref': '#/definitions/FilesystemAttachmentParamsResult'},
16560 'type': 'array'}},
16561 'type': 'object'},
16562 'FilesystemAttachmentResult': {'additionalProperties': False,
16563 'properties': {'error': {'$ref': '#/definitions/Error'},
16564 'result': {'$ref': '#/definitions/FilesystemAttachment'}},
16565 'required': ['result'],
16566 'type': 'object'},
16567 'FilesystemAttachmentResults': {'additionalProperties': False,
16568 'properties': {'results': {'items': {'$ref': '#/definitions/FilesystemAttachmentResult'},
16569 'type': 'array'}},
16570 'type': 'object'},
16571 'FilesystemAttachments': {'additionalProperties': False,
16572 'properties': {'filesystemattachments': {'items': {'$ref': '#/definitions/FilesystemAttachment'},
16573 'type': 'array'}},
16574 'required': ['filesystemattachments'],
16575 'type': 'object'},
16576 'FilesystemInfo': {'additionalProperties': False,
16577 'properties': {'filesystemid': {'type': 'string'},
16578 'size': {'type': 'integer'}},
16579 'required': ['filesystemid', 'size'],
16580 'type': 'object'},
16581 'FilesystemParams': {'additionalProperties': False,
16582 'properties': {'attachment': {'$ref': '#/definitions/FilesystemAttachmentParams'},
16583 'attributes': {'patternProperties': {'.*': {'additionalProperties': True,
16584 'type': 'object'}},
16585 'type': 'object'},
16586 'filesystemtag': {'type': 'string'},
16587 'provider': {'type': 'string'},
16588 'size': {'type': 'integer'},
16589 'tags': {'patternProperties': {'.*': {'type': 'string'}},
16590 'type': 'object'},
16591 'volumetag': {'type': 'string'}},
16592 'required': ['filesystemtag',
16593 'size',
16594 'provider'],
16595 'type': 'object'},
16596 'FilesystemParamsResult': {'additionalProperties': False,
16597 'properties': {'error': {'$ref': '#/definitions/Error'},
16598 'result': {'$ref': '#/definitions/FilesystemParams'}},
16599 'required': ['result'],
16600 'type': 'object'},
16601 'FilesystemParamsResults': {'additionalProperties': False,
16602 'properties': {'results': {'items': {'$ref': '#/definitions/FilesystemParamsResult'},
16603 'type': 'array'}},
16604 'type': 'object'},
16605 'FilesystemResult': {'additionalProperties': False,
16606 'properties': {'error': {'$ref': '#/definitions/Error'},
16607 'result': {'$ref': '#/definitions/Filesystem'}},
16608 'required': ['result'],
16609 'type': 'object'},
16610 'FilesystemResults': {'additionalProperties': False,
16611 'properties': {'results': {'items': {'$ref': '#/definitions/FilesystemResult'},
16612 'type': 'array'}},
16613 'type': 'object'},
16614 'Filesystems': {'additionalProperties': False,
16615 'properties': {'filesystems': {'items': {'$ref': '#/definitions/Filesystem'},
16616 'type': 'array'}},
16617 'required': ['filesystems'],
16618 'type': 'object'},
16619 'LifeResult': {'additionalProperties': False,
16620 'properties': {'Error': {'$ref': '#/definitions/Error'},
16621 'Life': {'type': 'string'}},
16622 'required': ['Life', 'Error'],
16623 'type': 'object'},
16624 'LifeResults': {'additionalProperties': False,
16625 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
16626 'type': 'array'}},
16627 'required': ['Results'],
16628 'type': 'object'},
16629 'Macaroon': {'additionalProperties': False,
16630 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
16631 'type': 'array'},
16632 'data': {'items': {'type': 'integer'},
16633 'type': 'array'},
16634 'id': {'$ref': '#/definitions/packet'},
16635 'location': {'$ref': '#/definitions/packet'},
16636 'sig': {'items': {'type': 'integer'},
16637 'type': 'array'}},
16638 'required': ['data',
16639 'location',
16640 'id',
16641 'caveats',
16642 'sig'],
16643 'type': 'object'},
16644 'MachineStorageId': {'additionalProperties': False,
16645 'properties': {'attachmenttag': {'type': 'string'},
16646 'machinetag': {'type': 'string'}},
16647 'required': ['machinetag',
16648 'attachmenttag'],
16649 'type': 'object'},
16650 'MachineStorageIds': {'additionalProperties': False,
16651 'properties': {'ids': {'items': {'$ref': '#/definitions/MachineStorageId'},
16652 'type': 'array'}},
16653 'required': ['ids'],
16654 'type': 'object'},
16655 'MachineStorageIdsWatchResult': {'additionalProperties': False,
16656 'properties': {'Changes': {'items': {'$ref': '#/definitions/MachineStorageId'},
16657 'type': 'array'},
16658 'Error': {'$ref': '#/definitions/Error'},
16659 'MachineStorageIdsWatcherId': {'type': 'string'}},
16660 'required': ['MachineStorageIdsWatcherId',
16661 'Changes',
16662 'Error'],
16663 'type': 'object'},
16664 'MachineStorageIdsWatchResults': {'additionalProperties': False,
16665 'properties': {'Results': {'items': {'$ref': '#/definitions/MachineStorageIdsWatchResult'},
16666 'type': 'array'}},
16667 'required': ['Results'],
16668 'type': 'object'},
16669 'ModelConfigResult': {'additionalProperties': False,
16670 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
16671 'type': 'object'}},
16672 'type': 'object'}},
16673 'required': ['Config'],
16674 'type': 'object'},
16675 'NotifyWatchResult': {'additionalProperties': False,
16676 'properties': {'Error': {'$ref': '#/definitions/Error'},
16677 'NotifyWatcherId': {'type': 'string'}},
16678 'required': ['NotifyWatcherId', 'Error'],
16679 'type': 'object'},
16680 'NotifyWatchResults': {'additionalProperties': False,
16681 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
16682 'type': 'array'}},
16683 'required': ['Results'],
16684 'type': 'object'},
16685 'SetStatus': {'additionalProperties': False,
16686 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
16687 'type': 'array'}},
16688 'required': ['Entities'],
16689 'type': 'object'},
16690 'StringResult': {'additionalProperties': False,
16691 'properties': {'Error': {'$ref': '#/definitions/Error'},
16692 'Result': {'type': 'string'}},
16693 'required': ['Error', 'Result'],
16694 'type': 'object'},
16695 'StringResults': {'additionalProperties': False,
16696 'properties': {'Results': {'items': {'$ref': '#/definitions/StringResult'},
16697 'type': 'array'}},
16698 'required': ['Results'],
16699 'type': 'object'},
16700 'StringsWatchResult': {'additionalProperties': False,
16701 'properties': {'Changes': {'items': {'type': 'string'},
16702 'type': 'array'},
16703 'Error': {'$ref': '#/definitions/Error'},
16704 'StringsWatcherId': {'type': 'string'}},
16705 'required': ['StringsWatcherId',
16706 'Changes',
16707 'Error'],
16708 'type': 'object'},
16709 'StringsWatchResults': {'additionalProperties': False,
16710 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsWatchResult'},
16711 'type': 'array'}},
16712 'required': ['Results'],
16713 'type': 'object'},
16714 'Volume': {'additionalProperties': False,
16715 'properties': {'info': {'$ref': '#/definitions/VolumeInfo'},
16716 'volumetag': {'type': 'string'}},
16717 'required': ['volumetag', 'info'],
16718 'type': 'object'},
16719 'VolumeAttachment': {'additionalProperties': False,
16720 'properties': {'info': {'$ref': '#/definitions/VolumeAttachmentInfo'},
16721 'machinetag': {'type': 'string'},
16722 'volumetag': {'type': 'string'}},
16723 'required': ['volumetag',
16724 'machinetag',
16725 'info'],
16726 'type': 'object'},
16727 'VolumeAttachmentInfo': {'additionalProperties': False,
16728 'properties': {'busaddress': {'type': 'string'},
16729 'devicelink': {'type': 'string'},
16730 'devicename': {'type': 'string'},
16731 'read-only': {'type': 'boolean'}},
16732 'type': 'object'},
16733 'VolumeAttachmentParams': {'additionalProperties': False,
16734 'properties': {'instanceid': {'type': 'string'},
16735 'machinetag': {'type': 'string'},
16736 'provider': {'type': 'string'},
16737 'read-only': {'type': 'boolean'},
16738 'volumeid': {'type': 'string'},
16739 'volumetag': {'type': 'string'}},
16740 'required': ['volumetag',
16741 'machinetag',
16742 'provider'],
16743 'type': 'object'},
16744 'VolumeAttachmentParamsResult': {'additionalProperties': False,
16745 'properties': {'error': {'$ref': '#/definitions/Error'},
16746 'result': {'$ref': '#/definitions/VolumeAttachmentParams'}},
16747 'required': ['result'],
16748 'type': 'object'},
16749 'VolumeAttachmentParamsResults': {'additionalProperties': False,
16750 'properties': {'results': {'items': {'$ref': '#/definitions/VolumeAttachmentParamsResult'},
16751 'type': 'array'}},
16752 'type': 'object'},
16753 'VolumeAttachmentResult': {'additionalProperties': False,
16754 'properties': {'error': {'$ref': '#/definitions/Error'},
16755 'result': {'$ref': '#/definitions/VolumeAttachment'}},
16756 'required': ['result'],
16757 'type': 'object'},
16758 'VolumeAttachmentResults': {'additionalProperties': False,
16759 'properties': {'results': {'items': {'$ref': '#/definitions/VolumeAttachmentResult'},
16760 'type': 'array'}},
16761 'type': 'object'},
16762 'VolumeAttachments': {'additionalProperties': False,
16763 'properties': {'volumeattachments': {'items': {'$ref': '#/definitions/VolumeAttachment'},
16764 'type': 'array'}},
16765 'required': ['volumeattachments'],
16766 'type': 'object'},
16767 'VolumeInfo': {'additionalProperties': False,
16768 'properties': {'hardwareid': {'type': 'string'},
16769 'persistent': {'type': 'boolean'},
16770 'size': {'type': 'integer'},
16771 'volumeid': {'type': 'string'}},
16772 'required': ['volumeid', 'size', 'persistent'],
16773 'type': 'object'},
16774 'VolumeParams': {'additionalProperties': False,
16775 'properties': {'attachment': {'$ref': '#/definitions/VolumeAttachmentParams'},
16776 'attributes': {'patternProperties': {'.*': {'additionalProperties': True,
16777 'type': 'object'}},
16778 'type': 'object'},
16779 'provider': {'type': 'string'},
16780 'size': {'type': 'integer'},
16781 'tags': {'patternProperties': {'.*': {'type': 'string'}},
16782 'type': 'object'},
16783 'volumetag': {'type': 'string'}},
16784 'required': ['volumetag', 'size', 'provider'],
16785 'type': 'object'},
16786 'VolumeParamsResult': {'additionalProperties': False,
16787 'properties': {'error': {'$ref': '#/definitions/Error'},
16788 'result': {'$ref': '#/definitions/VolumeParams'}},
16789 'required': ['result'],
16790 'type': 'object'},
16791 'VolumeParamsResults': {'additionalProperties': False,
16792 'properties': {'results': {'items': {'$ref': '#/definitions/VolumeParamsResult'},
16793 'type': 'array'}},
16794 'type': 'object'},
16795 'VolumeResult': {'additionalProperties': False,
16796 'properties': {'error': {'$ref': '#/definitions/Error'},
16797 'result': {'$ref': '#/definitions/Volume'}},
16798 'required': ['result'],
16799 'type': 'object'},
16800 'VolumeResults': {'additionalProperties': False,
16801 'properties': {'results': {'items': {'$ref': '#/definitions/VolumeResult'},
16802 'type': 'array'}},
16803 'type': 'object'},
16804 'Volumes': {'additionalProperties': False,
16805 'properties': {'volumes': {'items': {'$ref': '#/definitions/Volume'},
16806 'type': 'array'}},
16807 'required': ['volumes'],
16808 'type': 'object'},
16809 'caveat': {'additionalProperties': False,
16810 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
16811 'location': {'$ref': '#/definitions/packet'},
16812 'verificationId': {'$ref': '#/definitions/packet'}},
16813 'required': ['location',
16814 'caveatId',
16815 'verificationId'],
16816 'type': 'object'},
16817 'packet': {'additionalProperties': False,
16818 'properties': {'headerLen': {'type': 'integer'},
16819 'start': {'type': 'integer'},
16820 'totalLen': {'type': 'integer'}},
16821 'required': ['start', 'totalLen', 'headerLen'],
16822 'type': 'object'}},
16823 'properties': {'AttachmentLife': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16824 'Result': {'$ref': '#/definitions/LifeResults'}},
16825 'type': 'object'},
16826 'EnsureDead': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16827 'Result': {'$ref': '#/definitions/ErrorResults'}},
16828 'type': 'object'},
16829 'FilesystemAttachmentParams': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16830 'Result': {'$ref': '#/definitions/FilesystemAttachmentParamsResults'}},
16831 'type': 'object'},
16832 'FilesystemAttachments': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16833 'Result': {'$ref': '#/definitions/FilesystemAttachmentResults'}},
16834 'type': 'object'},
16835 'FilesystemParams': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16836 'Result': {'$ref': '#/definitions/FilesystemParamsResults'}},
16837 'type': 'object'},
16838 'Filesystems': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16839 'Result': {'$ref': '#/definitions/FilesystemResults'}},
16840 'type': 'object'},
16841 'InstanceId': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16842 'Result': {'$ref': '#/definitions/StringResults'}},
16843 'type': 'object'},
16844 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16845 'Result': {'$ref': '#/definitions/LifeResults'}},
16846 'type': 'object'},
16847 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
16848 'type': 'object'},
16849 'Remove': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16850 'Result': {'$ref': '#/definitions/ErrorResults'}},
16851 'type': 'object'},
16852 'RemoveAttachment': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16853 'Result': {'$ref': '#/definitions/ErrorResults'}},
16854 'type': 'object'},
16855 'SetFilesystemAttachmentInfo': {'properties': {'Params': {'$ref': '#/definitions/FilesystemAttachments'},
16856 'Result': {'$ref': '#/definitions/ErrorResults'}},
16857 'type': 'object'},
16858 'SetFilesystemInfo': {'properties': {'Params': {'$ref': '#/definitions/Filesystems'},
16859 'Result': {'$ref': '#/definitions/ErrorResults'}},
16860 'type': 'object'},
16861 'SetStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
16862 'Result': {'$ref': '#/definitions/ErrorResults'}},
16863 'type': 'object'},
16864 'SetVolumeAttachmentInfo': {'properties': {'Params': {'$ref': '#/definitions/VolumeAttachments'},
16865 'Result': {'$ref': '#/definitions/ErrorResults'}},
16866 'type': 'object'},
16867 'SetVolumeInfo': {'properties': {'Params': {'$ref': '#/definitions/Volumes'},
16868 'Result': {'$ref': '#/definitions/ErrorResults'}},
16869 'type': 'object'},
16870 'UpdateStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
16871 'Result': {'$ref': '#/definitions/ErrorResults'}},
16872 'type': 'object'},
16873 'VolumeAttachmentParams': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16874 'Result': {'$ref': '#/definitions/VolumeAttachmentParamsResults'}},
16875 'type': 'object'},
16876 'VolumeAttachments': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16877 'Result': {'$ref': '#/definitions/VolumeAttachmentResults'}},
16878 'type': 'object'},
16879 'VolumeBlockDevices': {'properties': {'Params': {'$ref': '#/definitions/MachineStorageIds'},
16880 'Result': {'$ref': '#/definitions/BlockDeviceResults'}},
16881 'type': 'object'},
16882 'VolumeParams': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16883 'Result': {'$ref': '#/definitions/VolumeParamsResults'}},
16884 'type': 'object'},
16885 'Volumes': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16886 'Result': {'$ref': '#/definitions/VolumeResults'}},
16887 'type': 'object'},
16888 'WatchBlockDevices': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16889 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
16890 'type': 'object'},
16891 'WatchFilesystemAttachments': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16892 'Result': {'$ref': '#/definitions/MachineStorageIdsWatchResults'}},
16893 'type': 'object'},
16894 'WatchFilesystems': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16895 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
16896 'type': 'object'},
16897 'WatchForModelConfigChanges': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
16898 'type': 'object'},
16899 'WatchMachines': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16900 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
16901 'type': 'object'},
16902 'WatchVolumeAttachments': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16903 'Result': {'$ref': '#/definitions/MachineStorageIdsWatchResults'}},
16904 'type': 'object'},
16905 'WatchVolumes': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
16906 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
16907 'type': 'object'}},
16908 'type': 'object'}
16909
16910
16911 @ReturnMapping(LifeResults)
16912 async def AttachmentLife(self, ids):
16913 '''
16914 ids : typing.Sequence[~MachineStorageId]
16915 Returns -> typing.Sequence[~LifeResult]
16916 '''
16917 # map input types to rpc msg
16918 params = dict()
16919 msg = dict(Type='StorageProvisioner', Request='AttachmentLife', Version=2, Params=params)
16920 params['ids'] = ids
16921 reply = await self.rpc(msg)
16922 return reply
16923
16924
16925
16926 @ReturnMapping(ErrorResults)
16927 async def EnsureDead(self, entities):
16928 '''
16929 entities : typing.Sequence[~Entity]
16930 Returns -> typing.Sequence[~ErrorResult]
16931 '''
16932 # map input types to rpc msg
16933 params = dict()
16934 msg = dict(Type='StorageProvisioner', Request='EnsureDead', Version=2, Params=params)
16935 params['Entities'] = entities
16936 reply = await self.rpc(msg)
16937 return reply
16938
16939
16940
16941 @ReturnMapping(FilesystemAttachmentParamsResults)
16942 async def FilesystemAttachmentParams(self, ids):
16943 '''
16944 ids : typing.Sequence[~MachineStorageId]
16945 Returns -> typing.Sequence[~FilesystemAttachmentParamsResult]
16946 '''
16947 # map input types to rpc msg
16948 params = dict()
16949 msg = dict(Type='StorageProvisioner', Request='FilesystemAttachmentParams', Version=2, Params=params)
16950 params['ids'] = ids
16951 reply = await self.rpc(msg)
16952 return reply
16953
16954
16955
16956 @ReturnMapping(FilesystemAttachmentResults)
16957 async def FilesystemAttachments(self, ids):
16958 '''
16959 ids : typing.Sequence[~MachineStorageId]
16960 Returns -> typing.Sequence[~FilesystemAttachmentResult]
16961 '''
16962 # map input types to rpc msg
16963 params = dict()
16964 msg = dict(Type='StorageProvisioner', Request='FilesystemAttachments', Version=2, Params=params)
16965 params['ids'] = ids
16966 reply = await self.rpc(msg)
16967 return reply
16968
16969
16970
16971 @ReturnMapping(FilesystemParamsResults)
16972 async def FilesystemParams(self, entities):
16973 '''
16974 entities : typing.Sequence[~Entity]
16975 Returns -> typing.Sequence[~FilesystemParamsResult]
16976 '''
16977 # map input types to rpc msg
16978 params = dict()
16979 msg = dict(Type='StorageProvisioner', Request='FilesystemParams', Version=2, Params=params)
16980 params['Entities'] = entities
16981 reply = await self.rpc(msg)
16982 return reply
16983
16984
16985
16986 @ReturnMapping(FilesystemResults)
16987 async def Filesystems(self, entities):
16988 '''
16989 entities : typing.Sequence[~Entity]
16990 Returns -> typing.Sequence[~FilesystemResult]
16991 '''
16992 # map input types to rpc msg
16993 params = dict()
16994 msg = dict(Type='StorageProvisioner', Request='Filesystems', Version=2, Params=params)
16995 params['Entities'] = entities
16996 reply = await self.rpc(msg)
16997 return reply
16998
16999
17000
17001 @ReturnMapping(StringResults)
17002 async def InstanceId(self, entities):
17003 '''
17004 entities : typing.Sequence[~Entity]
17005 Returns -> typing.Sequence[~StringResult]
17006 '''
17007 # map input types to rpc msg
17008 params = dict()
17009 msg = dict(Type='StorageProvisioner', Request='InstanceId', Version=2, Params=params)
17010 params['Entities'] = entities
17011 reply = await self.rpc(msg)
17012 return reply
17013
17014
17015
17016 @ReturnMapping(LifeResults)
17017 async def Life(self, entities):
17018 '''
17019 entities : typing.Sequence[~Entity]
17020 Returns -> typing.Sequence[~LifeResult]
17021 '''
17022 # map input types to rpc msg
17023 params = dict()
17024 msg = dict(Type='StorageProvisioner', Request='Life', Version=2, Params=params)
17025 params['Entities'] = entities
17026 reply = await self.rpc(msg)
17027 return reply
17028
17029
17030
17031 @ReturnMapping(ModelConfigResult)
17032 async def ModelConfig(self):
17033 '''
17034
17035 Returns -> typing.Mapping[str, typing.Any]
17036 '''
17037 # map input types to rpc msg
17038 params = dict()
17039 msg = dict(Type='StorageProvisioner', Request='ModelConfig', Version=2, Params=params)
17040
17041 reply = await self.rpc(msg)
17042 return reply
17043
17044
17045
17046 @ReturnMapping(ErrorResults)
17047 async def Remove(self, entities):
17048 '''
17049 entities : typing.Sequence[~Entity]
17050 Returns -> typing.Sequence[~ErrorResult]
17051 '''
17052 # map input types to rpc msg
17053 params = dict()
17054 msg = dict(Type='StorageProvisioner', Request='Remove', Version=2, Params=params)
17055 params['Entities'] = entities
17056 reply = await self.rpc(msg)
17057 return reply
17058
17059
17060
17061 @ReturnMapping(ErrorResults)
17062 async def RemoveAttachment(self, ids):
17063 '''
17064 ids : typing.Sequence[~MachineStorageId]
17065 Returns -> typing.Sequence[~ErrorResult]
17066 '''
17067 # map input types to rpc msg
17068 params = dict()
17069 msg = dict(Type='StorageProvisioner', Request='RemoveAttachment', Version=2, Params=params)
17070 params['ids'] = ids
17071 reply = await self.rpc(msg)
17072 return reply
17073
17074
17075
17076 @ReturnMapping(ErrorResults)
17077 async def SetFilesystemAttachmentInfo(self, filesystemattachments):
17078 '''
17079 filesystemattachments : typing.Sequence[~FilesystemAttachment]
17080 Returns -> typing.Sequence[~ErrorResult]
17081 '''
17082 # map input types to rpc msg
17083 params = dict()
17084 msg = dict(Type='StorageProvisioner', Request='SetFilesystemAttachmentInfo', Version=2, Params=params)
17085 params['filesystemattachments'] = filesystemattachments
17086 reply = await self.rpc(msg)
17087 return reply
17088
17089
17090
17091 @ReturnMapping(ErrorResults)
17092 async def SetFilesystemInfo(self, filesystems):
17093 '''
17094 filesystems : typing.Sequence[~Filesystem]
17095 Returns -> typing.Sequence[~ErrorResult]
17096 '''
17097 # map input types to rpc msg
17098 params = dict()
17099 msg = dict(Type='StorageProvisioner', Request='SetFilesystemInfo', Version=2, Params=params)
17100 params['filesystems'] = filesystems
17101 reply = await self.rpc(msg)
17102 return reply
17103
17104
17105
17106 @ReturnMapping(ErrorResults)
17107 async def SetStatus(self, entities):
17108 '''
17109 entities : typing.Sequence[~EntityStatusArgs]
17110 Returns -> typing.Sequence[~ErrorResult]
17111 '''
17112 # map input types to rpc msg
17113 params = dict()
17114 msg = dict(Type='StorageProvisioner', Request='SetStatus', Version=2, Params=params)
17115 params['Entities'] = entities
17116 reply = await self.rpc(msg)
17117 return reply
17118
17119
17120
17121 @ReturnMapping(ErrorResults)
17122 async def SetVolumeAttachmentInfo(self, volumeattachments):
17123 '''
17124 volumeattachments : typing.Sequence[~VolumeAttachment]
17125 Returns -> typing.Sequence[~ErrorResult]
17126 '''
17127 # map input types to rpc msg
17128 params = dict()
17129 msg = dict(Type='StorageProvisioner', Request='SetVolumeAttachmentInfo', Version=2, Params=params)
17130 params['volumeattachments'] = volumeattachments
17131 reply = await self.rpc(msg)
17132 return reply
17133
17134
17135
17136 @ReturnMapping(ErrorResults)
17137 async def SetVolumeInfo(self, volumes):
17138 '''
17139 volumes : typing.Sequence[~Volume]
17140 Returns -> typing.Sequence[~ErrorResult]
17141 '''
17142 # map input types to rpc msg
17143 params = dict()
17144 msg = dict(Type='StorageProvisioner', Request='SetVolumeInfo', Version=2, Params=params)
17145 params['volumes'] = volumes
17146 reply = await self.rpc(msg)
17147 return reply
17148
17149
17150
17151 @ReturnMapping(ErrorResults)
17152 async def UpdateStatus(self, entities):
17153 '''
17154 entities : typing.Sequence[~EntityStatusArgs]
17155 Returns -> typing.Sequence[~ErrorResult]
17156 '''
17157 # map input types to rpc msg
17158 params = dict()
17159 msg = dict(Type='StorageProvisioner', Request='UpdateStatus', Version=2, Params=params)
17160 params['Entities'] = entities
17161 reply = await self.rpc(msg)
17162 return reply
17163
17164
17165
17166 @ReturnMapping(VolumeAttachmentParamsResults)
17167 async def VolumeAttachmentParams(self, ids):
17168 '''
17169 ids : typing.Sequence[~MachineStorageId]
17170 Returns -> typing.Sequence[~VolumeAttachmentParamsResult]
17171 '''
17172 # map input types to rpc msg
17173 params = dict()
17174 msg = dict(Type='StorageProvisioner', Request='VolumeAttachmentParams', Version=2, Params=params)
17175 params['ids'] = ids
17176 reply = await self.rpc(msg)
17177 return reply
17178
17179
17180
17181 @ReturnMapping(VolumeAttachmentResults)
17182 async def VolumeAttachments(self, ids):
17183 '''
17184 ids : typing.Sequence[~MachineStorageId]
17185 Returns -> typing.Sequence[~VolumeAttachmentResult]
17186 '''
17187 # map input types to rpc msg
17188 params = dict()
17189 msg = dict(Type='StorageProvisioner', Request='VolumeAttachments', Version=2, Params=params)
17190 params['ids'] = ids
17191 reply = await self.rpc(msg)
17192 return reply
17193
17194
17195
17196 @ReturnMapping(BlockDeviceResults)
17197 async def VolumeBlockDevices(self, ids):
17198 '''
17199 ids : typing.Sequence[~MachineStorageId]
17200 Returns -> typing.Sequence[~BlockDeviceResult]
17201 '''
17202 # map input types to rpc msg
17203 params = dict()
17204 msg = dict(Type='StorageProvisioner', Request='VolumeBlockDevices', Version=2, Params=params)
17205 params['ids'] = ids
17206 reply = await self.rpc(msg)
17207 return reply
17208
17209
17210
17211 @ReturnMapping(VolumeParamsResults)
17212 async def VolumeParams(self, entities):
17213 '''
17214 entities : typing.Sequence[~Entity]
17215 Returns -> typing.Sequence[~VolumeParamsResult]
17216 '''
17217 # map input types to rpc msg
17218 params = dict()
17219 msg = dict(Type='StorageProvisioner', Request='VolumeParams', Version=2, Params=params)
17220 params['Entities'] = entities
17221 reply = await self.rpc(msg)
17222 return reply
17223
17224
17225
17226 @ReturnMapping(VolumeResults)
17227 async def Volumes(self, entities):
17228 '''
17229 entities : typing.Sequence[~Entity]
17230 Returns -> typing.Sequence[~VolumeResult]
17231 '''
17232 # map input types to rpc msg
17233 params = dict()
17234 msg = dict(Type='StorageProvisioner', Request='Volumes', Version=2, Params=params)
17235 params['Entities'] = entities
17236 reply = await self.rpc(msg)
17237 return reply
17238
17239
17240
17241 @ReturnMapping(NotifyWatchResults)
17242 async def WatchBlockDevices(self, entities):
17243 '''
17244 entities : typing.Sequence[~Entity]
17245 Returns -> typing.Sequence[~NotifyWatchResult]
17246 '''
17247 # map input types to rpc msg
17248 params = dict()
17249 msg = dict(Type='StorageProvisioner', Request='WatchBlockDevices', Version=2, Params=params)
17250 params['Entities'] = entities
17251 reply = await self.rpc(msg)
17252 return reply
17253
17254
17255
17256 @ReturnMapping(MachineStorageIdsWatchResults)
17257 async def WatchFilesystemAttachments(self, entities):
17258 '''
17259 entities : typing.Sequence[~Entity]
17260 Returns -> typing.Sequence[~MachineStorageIdsWatchResult]
17261 '''
17262 # map input types to rpc msg
17263 params = dict()
17264 msg = dict(Type='StorageProvisioner', Request='WatchFilesystemAttachments', Version=2, Params=params)
17265 params['Entities'] = entities
17266 reply = await self.rpc(msg)
17267 return reply
17268
17269
17270
17271 @ReturnMapping(StringsWatchResults)
17272 async def WatchFilesystems(self, entities):
17273 '''
17274 entities : typing.Sequence[~Entity]
17275 Returns -> typing.Sequence[~StringsWatchResult]
17276 '''
17277 # map input types to rpc msg
17278 params = dict()
17279 msg = dict(Type='StorageProvisioner', Request='WatchFilesystems', Version=2, Params=params)
17280 params['Entities'] = entities
17281 reply = await self.rpc(msg)
17282 return reply
17283
17284
17285
17286 @ReturnMapping(NotifyWatchResult)
17287 async def WatchForModelConfigChanges(self):
17288 '''
17289
17290 Returns -> typing.Union[_ForwardRef('Error'), str]
17291 '''
17292 # map input types to rpc msg
17293 params = dict()
17294 msg = dict(Type='StorageProvisioner', Request='WatchForModelConfigChanges', Version=2, Params=params)
17295
17296 reply = await self.rpc(msg)
17297 return reply
17298
17299
17300
17301 @ReturnMapping(NotifyWatchResults)
17302 async def WatchMachines(self, entities):
17303 '''
17304 entities : typing.Sequence[~Entity]
17305 Returns -> typing.Sequence[~NotifyWatchResult]
17306 '''
17307 # map input types to rpc msg
17308 params = dict()
17309 msg = dict(Type='StorageProvisioner', Request='WatchMachines', Version=2, Params=params)
17310 params['Entities'] = entities
17311 reply = await self.rpc(msg)
17312 return reply
17313
17314
17315
17316 @ReturnMapping(MachineStorageIdsWatchResults)
17317 async def WatchVolumeAttachments(self, entities):
17318 '''
17319 entities : typing.Sequence[~Entity]
17320 Returns -> typing.Sequence[~MachineStorageIdsWatchResult]
17321 '''
17322 # map input types to rpc msg
17323 params = dict()
17324 msg = dict(Type='StorageProvisioner', Request='WatchVolumeAttachments', Version=2, Params=params)
17325 params['Entities'] = entities
17326 reply = await self.rpc(msg)
17327 return reply
17328
17329
17330
17331 @ReturnMapping(StringsWatchResults)
17332 async def WatchVolumes(self, entities):
17333 '''
17334 entities : typing.Sequence[~Entity]
17335 Returns -> typing.Sequence[~StringsWatchResult]
17336 '''
17337 # map input types to rpc msg
17338 params = dict()
17339 msg = dict(Type='StorageProvisioner', Request='WatchVolumes', Version=2, Params=params)
17340 params['Entities'] = entities
17341 reply = await self.rpc(msg)
17342 return reply
17343
17344
17345 class StringsWatcherFacade(Type):
17346 name = 'StringsWatcher'
17347 version = 1
17348 schema = {'definitions': {'Error': {'additionalProperties': False,
17349 'properties': {'Code': {'type': 'string'},
17350 'Info': {'$ref': '#/definitions/ErrorInfo'},
17351 'Message': {'type': 'string'}},
17352 'required': ['Message', 'Code'],
17353 'type': 'object'},
17354 'ErrorInfo': {'additionalProperties': False,
17355 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
17356 'MacaroonPath': {'type': 'string'}},
17357 'type': 'object'},
17358 'Macaroon': {'additionalProperties': False,
17359 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
17360 'type': 'array'},
17361 'data': {'items': {'type': 'integer'},
17362 'type': 'array'},
17363 'id': {'$ref': '#/definitions/packet'},
17364 'location': {'$ref': '#/definitions/packet'},
17365 'sig': {'items': {'type': 'integer'},
17366 'type': 'array'}},
17367 'required': ['data',
17368 'location',
17369 'id',
17370 'caveats',
17371 'sig'],
17372 'type': 'object'},
17373 'StringsWatchResult': {'additionalProperties': False,
17374 'properties': {'Changes': {'items': {'type': 'string'},
17375 'type': 'array'},
17376 'Error': {'$ref': '#/definitions/Error'},
17377 'StringsWatcherId': {'type': 'string'}},
17378 'required': ['StringsWatcherId',
17379 'Changes',
17380 'Error'],
17381 'type': 'object'},
17382 'caveat': {'additionalProperties': False,
17383 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
17384 'location': {'$ref': '#/definitions/packet'},
17385 'verificationId': {'$ref': '#/definitions/packet'}},
17386 'required': ['location',
17387 'caveatId',
17388 'verificationId'],
17389 'type': 'object'},
17390 'packet': {'additionalProperties': False,
17391 'properties': {'headerLen': {'type': 'integer'},
17392 'start': {'type': 'integer'},
17393 'totalLen': {'type': 'integer'}},
17394 'required': ['start', 'totalLen', 'headerLen'],
17395 'type': 'object'}},
17396 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/StringsWatchResult'}},
17397 'type': 'object'},
17398 'Stop': {'type': 'object'}},
17399 'type': 'object'}
17400
17401
17402 @ReturnMapping(StringsWatchResult)
17403 async def Next(self):
17404 '''
17405
17406 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
17407 '''
17408 # map input types to rpc msg
17409 params = dict()
17410 msg = dict(Type='StringsWatcher', Request='Next', Version=1, Params=params)
17411
17412 reply = await self.rpc(msg)
17413 return reply
17414
17415
17416
17417 @ReturnMapping(None)
17418 async def Stop(self):
17419 '''
17420
17421 Returns -> None
17422 '''
17423 # map input types to rpc msg
17424 params = dict()
17425 msg = dict(Type='StringsWatcher', Request='Stop', Version=1, Params=params)
17426
17427 reply = await self.rpc(msg)
17428 return reply
17429
17430
17431 class SubnetsFacade(Type):
17432 name = 'Subnets'
17433 version = 2
17434 schema = {'definitions': {'AddSubnetParams': {'additionalProperties': False,
17435 'properties': {'SpaceTag': {'type': 'string'},
17436 'SubnetProviderId': {'type': 'string'},
17437 'SubnetTag': {'type': 'string'},
17438 'Zones': {'items': {'type': 'string'},
17439 'type': 'array'}},
17440 'required': ['SpaceTag'],
17441 'type': 'object'},
17442 'AddSubnetsParams': {'additionalProperties': False,
17443 'properties': {'Subnets': {'items': {'$ref': '#/definitions/AddSubnetParams'},
17444 'type': 'array'}},
17445 'required': ['Subnets'],
17446 'type': 'object'},
17447 'Error': {'additionalProperties': False,
17448 'properties': {'Code': {'type': 'string'},
17449 'Info': {'$ref': '#/definitions/ErrorInfo'},
17450 'Message': {'type': 'string'}},
17451 'required': ['Message', 'Code'],
17452 'type': 'object'},
17453 'ErrorInfo': {'additionalProperties': False,
17454 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
17455 'MacaroonPath': {'type': 'string'}},
17456 'type': 'object'},
17457 'ErrorResult': {'additionalProperties': False,
17458 'properties': {'Error': {'$ref': '#/definitions/Error'}},
17459 'required': ['Error'],
17460 'type': 'object'},
17461 'ErrorResults': {'additionalProperties': False,
17462 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
17463 'type': 'array'}},
17464 'required': ['Results'],
17465 'type': 'object'},
17466 'ListSubnetsResults': {'additionalProperties': False,
17467 'properties': {'Results': {'items': {'$ref': '#/definitions/Subnet'},
17468 'type': 'array'}},
17469 'required': ['Results'],
17470 'type': 'object'},
17471 'Macaroon': {'additionalProperties': False,
17472 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
17473 'type': 'array'},
17474 'data': {'items': {'type': 'integer'},
17475 'type': 'array'},
17476 'id': {'$ref': '#/definitions/packet'},
17477 'location': {'$ref': '#/definitions/packet'},
17478 'sig': {'items': {'type': 'integer'},
17479 'type': 'array'}},
17480 'required': ['data',
17481 'location',
17482 'id',
17483 'caveats',
17484 'sig'],
17485 'type': 'object'},
17486 'SpaceResult': {'additionalProperties': False,
17487 'properties': {'Error': {'$ref': '#/definitions/Error'},
17488 'Tag': {'type': 'string'}},
17489 'required': ['Error', 'Tag'],
17490 'type': 'object'},
17491 'SpaceResults': {'additionalProperties': False,
17492 'properties': {'Results': {'items': {'$ref': '#/definitions/SpaceResult'},
17493 'type': 'array'}},
17494 'required': ['Results'],
17495 'type': 'object'},
17496 'Subnet': {'additionalProperties': False,
17497 'properties': {'CIDR': {'type': 'string'},
17498 'Life': {'type': 'string'},
17499 'ProviderId': {'type': 'string'},
17500 'SpaceTag': {'type': 'string'},
17501 'StaticRangeHighIP': {'items': {'type': 'integer'},
17502 'type': 'array'},
17503 'StaticRangeLowIP': {'items': {'type': 'integer'},
17504 'type': 'array'},
17505 'Status': {'type': 'string'},
17506 'VLANTag': {'type': 'integer'},
17507 'Zones': {'items': {'type': 'string'},
17508 'type': 'array'}},
17509 'required': ['CIDR',
17510 'VLANTag',
17511 'Life',
17512 'SpaceTag',
17513 'Zones'],
17514 'type': 'object'},
17515 'SubnetsFilters': {'additionalProperties': False,
17516 'properties': {'SpaceTag': {'type': 'string'},
17517 'Zone': {'type': 'string'}},
17518 'type': 'object'},
17519 'ZoneResult': {'additionalProperties': False,
17520 'properties': {'Available': {'type': 'boolean'},
17521 'Error': {'$ref': '#/definitions/Error'},
17522 'Name': {'type': 'string'}},
17523 'required': ['Error', 'Name', 'Available'],
17524 'type': 'object'},
17525 'ZoneResults': {'additionalProperties': False,
17526 'properties': {'Results': {'items': {'$ref': '#/definitions/ZoneResult'},
17527 'type': 'array'}},
17528 'required': ['Results'],
17529 'type': 'object'},
17530 'caveat': {'additionalProperties': False,
17531 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
17532 'location': {'$ref': '#/definitions/packet'},
17533 'verificationId': {'$ref': '#/definitions/packet'}},
17534 'required': ['location',
17535 'caveatId',
17536 'verificationId'],
17537 'type': 'object'},
17538 'packet': {'additionalProperties': False,
17539 'properties': {'headerLen': {'type': 'integer'},
17540 'start': {'type': 'integer'},
17541 'totalLen': {'type': 'integer'}},
17542 'required': ['start', 'totalLen', 'headerLen'],
17543 'type': 'object'}},
17544 'properties': {'AddSubnets': {'properties': {'Params': {'$ref': '#/definitions/AddSubnetsParams'},
17545 'Result': {'$ref': '#/definitions/ErrorResults'}},
17546 'type': 'object'},
17547 'AllSpaces': {'properties': {'Result': {'$ref': '#/definitions/SpaceResults'}},
17548 'type': 'object'},
17549 'AllZones': {'properties': {'Result': {'$ref': '#/definitions/ZoneResults'}},
17550 'type': 'object'},
17551 'ListSubnets': {'properties': {'Params': {'$ref': '#/definitions/SubnetsFilters'},
17552 'Result': {'$ref': '#/definitions/ListSubnetsResults'}},
17553 'type': 'object'}},
17554 'type': 'object'}
17555
17556
17557 @ReturnMapping(ErrorResults)
17558 async def AddSubnets(self, subnets):
17559 '''
17560 subnets : typing.Sequence[~AddSubnetParams]
17561 Returns -> typing.Sequence[~ErrorResult]
17562 '''
17563 # map input types to rpc msg
17564 params = dict()
17565 msg = dict(Type='Subnets', Request='AddSubnets', Version=2, Params=params)
17566 params['Subnets'] = subnets
17567 reply = await self.rpc(msg)
17568 return reply
17569
17570
17571
17572 @ReturnMapping(SpaceResults)
17573 async def AllSpaces(self):
17574 '''
17575
17576 Returns -> typing.Sequence[~SpaceResult]
17577 '''
17578 # map input types to rpc msg
17579 params = dict()
17580 msg = dict(Type='Subnets', Request='AllSpaces', Version=2, Params=params)
17581
17582 reply = await self.rpc(msg)
17583 return reply
17584
17585
17586
17587 @ReturnMapping(ZoneResults)
17588 async def AllZones(self):
17589 '''
17590
17591 Returns -> typing.Sequence[~ZoneResult]
17592 '''
17593 # map input types to rpc msg
17594 params = dict()
17595 msg = dict(Type='Subnets', Request='AllZones', Version=2, Params=params)
17596
17597 reply = await self.rpc(msg)
17598 return reply
17599
17600
17601
17602 @ReturnMapping(ListSubnetsResults)
17603 async def ListSubnets(self, spacetag, zone):
17604 '''
17605 spacetag : str
17606 zone : str
17607 Returns -> typing.Sequence[~Subnet]
17608 '''
17609 # map input types to rpc msg
17610 params = dict()
17611 msg = dict(Type='Subnets', Request='ListSubnets', Version=2, Params=params)
17612 params['SpaceTag'] = spacetag
17613 params['Zone'] = zone
17614 reply = await self.rpc(msg)
17615 return reply
17616
17617
17618 class UndertakerFacade(Type):
17619 name = 'Undertaker'
17620 version = 1
17621 schema = {'definitions': {'EntityStatusArgs': {'additionalProperties': False,
17622 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
17623 'type': 'object'}},
17624 'type': 'object'},
17625 'Info': {'type': 'string'},
17626 'Status': {'type': 'string'},
17627 'Tag': {'type': 'string'}},
17628 'required': ['Tag',
17629 'Status',
17630 'Info',
17631 'Data'],
17632 'type': 'object'},
17633 'Error': {'additionalProperties': False,
17634 'properties': {'Code': {'type': 'string'},
17635 'Info': {'$ref': '#/definitions/ErrorInfo'},
17636 'Message': {'type': 'string'}},
17637 'required': ['Message', 'Code'],
17638 'type': 'object'},
17639 'ErrorInfo': {'additionalProperties': False,
17640 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
17641 'MacaroonPath': {'type': 'string'}},
17642 'type': 'object'},
17643 'ErrorResult': {'additionalProperties': False,
17644 'properties': {'Error': {'$ref': '#/definitions/Error'}},
17645 'required': ['Error'],
17646 'type': 'object'},
17647 'ErrorResults': {'additionalProperties': False,
17648 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
17649 'type': 'array'}},
17650 'required': ['Results'],
17651 'type': 'object'},
17652 'Macaroon': {'additionalProperties': False,
17653 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
17654 'type': 'array'},
17655 'data': {'items': {'type': 'integer'},
17656 'type': 'array'},
17657 'id': {'$ref': '#/definitions/packet'},
17658 'location': {'$ref': '#/definitions/packet'},
17659 'sig': {'items': {'type': 'integer'},
17660 'type': 'array'}},
17661 'required': ['data',
17662 'location',
17663 'id',
17664 'caveats',
17665 'sig'],
17666 'type': 'object'},
17667 'ModelConfigResult': {'additionalProperties': False,
17668 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
17669 'type': 'object'}},
17670 'type': 'object'}},
17671 'required': ['Config'],
17672 'type': 'object'},
17673 'NotifyWatchResult': {'additionalProperties': False,
17674 'properties': {'Error': {'$ref': '#/definitions/Error'},
17675 'NotifyWatcherId': {'type': 'string'}},
17676 'required': ['NotifyWatcherId', 'Error'],
17677 'type': 'object'},
17678 'NotifyWatchResults': {'additionalProperties': False,
17679 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
17680 'type': 'array'}},
17681 'required': ['Results'],
17682 'type': 'object'},
17683 'SetStatus': {'additionalProperties': False,
17684 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
17685 'type': 'array'}},
17686 'required': ['Entities'],
17687 'type': 'object'},
17688 'UndertakerModelInfo': {'additionalProperties': False,
17689 'properties': {'GlobalName': {'type': 'string'},
17690 'IsSystem': {'type': 'boolean'},
17691 'Life': {'type': 'string'},
17692 'Name': {'type': 'string'},
17693 'UUID': {'type': 'string'}},
17694 'required': ['UUID',
17695 'Name',
17696 'GlobalName',
17697 'IsSystem',
17698 'Life'],
17699 'type': 'object'},
17700 'UndertakerModelInfoResult': {'additionalProperties': False,
17701 'properties': {'Error': {'$ref': '#/definitions/Error'},
17702 'Result': {'$ref': '#/definitions/UndertakerModelInfo'}},
17703 'required': ['Error', 'Result'],
17704 'type': 'object'},
17705 'caveat': {'additionalProperties': False,
17706 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
17707 'location': {'$ref': '#/definitions/packet'},
17708 'verificationId': {'$ref': '#/definitions/packet'}},
17709 'required': ['location',
17710 'caveatId',
17711 'verificationId'],
17712 'type': 'object'},
17713 'packet': {'additionalProperties': False,
17714 'properties': {'headerLen': {'type': 'integer'},
17715 'start': {'type': 'integer'},
17716 'totalLen': {'type': 'integer'}},
17717 'required': ['start', 'totalLen', 'headerLen'],
17718 'type': 'object'}},
17719 'properties': {'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
17720 'type': 'object'},
17721 'ModelInfo': {'properties': {'Result': {'$ref': '#/definitions/UndertakerModelInfoResult'}},
17722 'type': 'object'},
17723 'ProcessDyingModel': {'type': 'object'},
17724 'RemoveModel': {'type': 'object'},
17725 'SetStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
17726 'Result': {'$ref': '#/definitions/ErrorResults'}},
17727 'type': 'object'},
17728 'UpdateStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
17729 'Result': {'$ref': '#/definitions/ErrorResults'}},
17730 'type': 'object'},
17731 'WatchModelResources': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
17732 'type': 'object'}},
17733 'type': 'object'}
17734
17735
17736 @ReturnMapping(ModelConfigResult)
17737 async def ModelConfig(self):
17738 '''
17739
17740 Returns -> typing.Mapping[str, typing.Any]
17741 '''
17742 # map input types to rpc msg
17743 params = dict()
17744 msg = dict(Type='Undertaker', Request='ModelConfig', Version=1, Params=params)
17745
17746 reply = await self.rpc(msg)
17747 return reply
17748
17749
17750
17751 @ReturnMapping(UndertakerModelInfoResult)
17752 async def ModelInfo(self):
17753 '''
17754
17755 Returns -> typing.Union[_ForwardRef('Error'), _ForwardRef('UndertakerModelInfo')]
17756 '''
17757 # map input types to rpc msg
17758 params = dict()
17759 msg = dict(Type='Undertaker', Request='ModelInfo', Version=1, Params=params)
17760
17761 reply = await self.rpc(msg)
17762 return reply
17763
17764
17765
17766 @ReturnMapping(None)
17767 async def ProcessDyingModel(self):
17768 '''
17769
17770 Returns -> None
17771 '''
17772 # map input types to rpc msg
17773 params = dict()
17774 msg = dict(Type='Undertaker', Request='ProcessDyingModel', Version=1, Params=params)
17775
17776 reply = await self.rpc(msg)
17777 return reply
17778
17779
17780
17781 @ReturnMapping(None)
17782 async def RemoveModel(self):
17783 '''
17784
17785 Returns -> None
17786 '''
17787 # map input types to rpc msg
17788 params = dict()
17789 msg = dict(Type='Undertaker', Request='RemoveModel', Version=1, Params=params)
17790
17791 reply = await self.rpc(msg)
17792 return reply
17793
17794
17795
17796 @ReturnMapping(ErrorResults)
17797 async def SetStatus(self, entities):
17798 '''
17799 entities : typing.Sequence[~EntityStatusArgs]
17800 Returns -> typing.Sequence[~ErrorResult]
17801 '''
17802 # map input types to rpc msg
17803 params = dict()
17804 msg = dict(Type='Undertaker', Request='SetStatus', Version=1, Params=params)
17805 params['Entities'] = entities
17806 reply = await self.rpc(msg)
17807 return reply
17808
17809
17810
17811 @ReturnMapping(ErrorResults)
17812 async def UpdateStatus(self, entities):
17813 '''
17814 entities : typing.Sequence[~EntityStatusArgs]
17815 Returns -> typing.Sequence[~ErrorResult]
17816 '''
17817 # map input types to rpc msg
17818 params = dict()
17819 msg = dict(Type='Undertaker', Request='UpdateStatus', Version=1, Params=params)
17820 params['Entities'] = entities
17821 reply = await self.rpc(msg)
17822 return reply
17823
17824
17825
17826 @ReturnMapping(NotifyWatchResults)
17827 async def WatchModelResources(self):
17828 '''
17829
17830 Returns -> typing.Sequence[~NotifyWatchResult]
17831 '''
17832 # map input types to rpc msg
17833 params = dict()
17834 msg = dict(Type='Undertaker', Request='WatchModelResources', Version=1, Params=params)
17835
17836 reply = await self.rpc(msg)
17837 return reply
17838
17839
17840 class UnitAssignerFacade(Type):
17841 name = 'UnitAssigner'
17842 version = 1
17843 schema = {'definitions': {'Entities': {'additionalProperties': False,
17844 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
17845 'type': 'array'}},
17846 'required': ['Entities'],
17847 'type': 'object'},
17848 'Entity': {'additionalProperties': False,
17849 'properties': {'Tag': {'type': 'string'}},
17850 'required': ['Tag'],
17851 'type': 'object'},
17852 'EntityStatusArgs': {'additionalProperties': False,
17853 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
17854 'type': 'object'}},
17855 'type': 'object'},
17856 'Info': {'type': 'string'},
17857 'Status': {'type': 'string'},
17858 'Tag': {'type': 'string'}},
17859 'required': ['Tag',
17860 'Status',
17861 'Info',
17862 'Data'],
17863 'type': 'object'},
17864 'Error': {'additionalProperties': False,
17865 'properties': {'Code': {'type': 'string'},
17866 'Info': {'$ref': '#/definitions/ErrorInfo'},
17867 'Message': {'type': 'string'}},
17868 'required': ['Message', 'Code'],
17869 'type': 'object'},
17870 'ErrorInfo': {'additionalProperties': False,
17871 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
17872 'MacaroonPath': {'type': 'string'}},
17873 'type': 'object'},
17874 'ErrorResult': {'additionalProperties': False,
17875 'properties': {'Error': {'$ref': '#/definitions/Error'}},
17876 'required': ['Error'],
17877 'type': 'object'},
17878 'ErrorResults': {'additionalProperties': False,
17879 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
17880 'type': 'array'}},
17881 'required': ['Results'],
17882 'type': 'object'},
17883 'Macaroon': {'additionalProperties': False,
17884 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
17885 'type': 'array'},
17886 'data': {'items': {'type': 'integer'},
17887 'type': 'array'},
17888 'id': {'$ref': '#/definitions/packet'},
17889 'location': {'$ref': '#/definitions/packet'},
17890 'sig': {'items': {'type': 'integer'},
17891 'type': 'array'}},
17892 'required': ['data',
17893 'location',
17894 'id',
17895 'caveats',
17896 'sig'],
17897 'type': 'object'},
17898 'SetStatus': {'additionalProperties': False,
17899 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
17900 'type': 'array'}},
17901 'required': ['Entities'],
17902 'type': 'object'},
17903 'StringsWatchResult': {'additionalProperties': False,
17904 'properties': {'Changes': {'items': {'type': 'string'},
17905 'type': 'array'},
17906 'Error': {'$ref': '#/definitions/Error'},
17907 'StringsWatcherId': {'type': 'string'}},
17908 'required': ['StringsWatcherId',
17909 'Changes',
17910 'Error'],
17911 'type': 'object'},
17912 'caveat': {'additionalProperties': False,
17913 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
17914 'location': {'$ref': '#/definitions/packet'},
17915 'verificationId': {'$ref': '#/definitions/packet'}},
17916 'required': ['location',
17917 'caveatId',
17918 'verificationId'],
17919 'type': 'object'},
17920 'packet': {'additionalProperties': False,
17921 'properties': {'headerLen': {'type': 'integer'},
17922 'start': {'type': 'integer'},
17923 'totalLen': {'type': 'integer'}},
17924 'required': ['start', 'totalLen', 'headerLen'],
17925 'type': 'object'}},
17926 'properties': {'AssignUnits': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
17927 'Result': {'$ref': '#/definitions/ErrorResults'}},
17928 'type': 'object'},
17929 'SetAgentStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
17930 'Result': {'$ref': '#/definitions/ErrorResults'}},
17931 'type': 'object'},
17932 'WatchUnitAssignments': {'properties': {'Result': {'$ref': '#/definitions/StringsWatchResult'}},
17933 'type': 'object'}},
17934 'type': 'object'}
17935
17936
17937 @ReturnMapping(ErrorResults)
17938 async def AssignUnits(self, entities):
17939 '''
17940 entities : typing.Sequence[~Entity]
17941 Returns -> typing.Sequence[~ErrorResult]
17942 '''
17943 # map input types to rpc msg
17944 params = dict()
17945 msg = dict(Type='UnitAssigner', Request='AssignUnits', Version=1, Params=params)
17946 params['Entities'] = entities
17947 reply = await self.rpc(msg)
17948 return reply
17949
17950
17951
17952 @ReturnMapping(ErrorResults)
17953 async def SetAgentStatus(self, entities):
17954 '''
17955 entities : typing.Sequence[~EntityStatusArgs]
17956 Returns -> typing.Sequence[~ErrorResult]
17957 '''
17958 # map input types to rpc msg
17959 params = dict()
17960 msg = dict(Type='UnitAssigner', Request='SetAgentStatus', Version=1, Params=params)
17961 params['Entities'] = entities
17962 reply = await self.rpc(msg)
17963 return reply
17964
17965
17966
17967 @ReturnMapping(StringsWatchResult)
17968 async def WatchUnitAssignments(self):
17969 '''
17970
17971 Returns -> typing.Union[typing.Sequence[str], _ForwardRef('Error')]
17972 '''
17973 # map input types to rpc msg
17974 params = dict()
17975 msg = dict(Type='UnitAssigner', Request='WatchUnitAssignments', Version=1, Params=params)
17976
17977 reply = await self.rpc(msg)
17978 return reply
17979
17980
17981 class UniterFacade(Type):
17982 name = 'Uniter'
17983 version = 4
17984 schema = {'definitions': {'APIHostPortsResult': {'additionalProperties': False,
17985 'properties': {'Servers': {'items': {'items': {'$ref': '#/definitions/HostPort'},
17986 'type': 'array'},
17987 'type': 'array'}},
17988 'required': ['Servers'],
17989 'type': 'object'},
17990 'Action': {'additionalProperties': False,
17991 'properties': {'name': {'type': 'string'},
17992 'parameters': {'patternProperties': {'.*': {'additionalProperties': True,
17993 'type': 'object'}},
17994 'type': 'object'},
17995 'receiver': {'type': 'string'},
17996 'tag': {'type': 'string'}},
17997 'required': ['tag', 'receiver', 'name'],
17998 'type': 'object'},
17999 'ActionExecutionResult': {'additionalProperties': False,
18000 'properties': {'actiontag': {'type': 'string'},
18001 'message': {'type': 'string'},
18002 'results': {'patternProperties': {'.*': {'additionalProperties': True,
18003 'type': 'object'}},
18004 'type': 'object'},
18005 'status': {'type': 'string'}},
18006 'required': ['actiontag', 'status'],
18007 'type': 'object'},
18008 'ActionExecutionResults': {'additionalProperties': False,
18009 'properties': {'results': {'items': {'$ref': '#/definitions/ActionExecutionResult'},
18010 'type': 'array'}},
18011 'type': 'object'},
18012 'ActionResult': {'additionalProperties': False,
18013 'properties': {'action': {'$ref': '#/definitions/Action'},
18014 'completed': {'format': 'date-time',
18015 'type': 'string'},
18016 'enqueued': {'format': 'date-time',
18017 'type': 'string'},
18018 'error': {'$ref': '#/definitions/Error'},
18019 'message': {'type': 'string'},
18020 'output': {'patternProperties': {'.*': {'additionalProperties': True,
18021 'type': 'object'}},
18022 'type': 'object'},
18023 'started': {'format': 'date-time',
18024 'type': 'string'},
18025 'status': {'type': 'string'}},
18026 'type': 'object'},
18027 'ActionResults': {'additionalProperties': False,
18028 'properties': {'results': {'items': {'$ref': '#/definitions/ActionResult'},
18029 'type': 'array'}},
18030 'type': 'object'},
18031 'Address': {'additionalProperties': False,
18032 'properties': {'Scope': {'type': 'string'},
18033 'SpaceName': {'type': 'string'},
18034 'Type': {'type': 'string'},
18035 'Value': {'type': 'string'}},
18036 'required': ['Value', 'Type', 'Scope'],
18037 'type': 'object'},
18038 'ApplicationStatusResult': {'additionalProperties': False,
18039 'properties': {'Application': {'$ref': '#/definitions/StatusResult'},
18040 'Error': {'$ref': '#/definitions/Error'},
18041 'Units': {'patternProperties': {'.*': {'$ref': '#/definitions/StatusResult'}},
18042 'type': 'object'}},
18043 'required': ['Application',
18044 'Units',
18045 'Error'],
18046 'type': 'object'},
18047 'ApplicationStatusResults': {'additionalProperties': False,
18048 'properties': {'Results': {'items': {'$ref': '#/definitions/ApplicationStatusResult'},
18049 'type': 'array'}},
18050 'required': ['Results'],
18051 'type': 'object'},
18052 'BoolResult': {'additionalProperties': False,
18053 'properties': {'Error': {'$ref': '#/definitions/Error'},
18054 'Result': {'type': 'boolean'}},
18055 'required': ['Error', 'Result'],
18056 'type': 'object'},
18057 'BoolResults': {'additionalProperties': False,
18058 'properties': {'Results': {'items': {'$ref': '#/definitions/BoolResult'},
18059 'type': 'array'}},
18060 'required': ['Results'],
18061 'type': 'object'},
18062 'BytesResult': {'additionalProperties': False,
18063 'properties': {'Result': {'items': {'type': 'integer'},
18064 'type': 'array'}},
18065 'required': ['Result'],
18066 'type': 'object'},
18067 'CharmURL': {'additionalProperties': False,
18068 'properties': {'URL': {'type': 'string'}},
18069 'required': ['URL'],
18070 'type': 'object'},
18071 'CharmURLs': {'additionalProperties': False,
18072 'properties': {'URLs': {'items': {'$ref': '#/definitions/CharmURL'},
18073 'type': 'array'}},
18074 'required': ['URLs'],
18075 'type': 'object'},
18076 'ConfigSettingsResult': {'additionalProperties': False,
18077 'properties': {'Error': {'$ref': '#/definitions/Error'},
18078 'Settings': {'patternProperties': {'.*': {'additionalProperties': True,
18079 'type': 'object'}},
18080 'type': 'object'}},
18081 'required': ['Error', 'Settings'],
18082 'type': 'object'},
18083 'ConfigSettingsResults': {'additionalProperties': False,
18084 'properties': {'Results': {'items': {'$ref': '#/definitions/ConfigSettingsResult'},
18085 'type': 'array'}},
18086 'required': ['Results'],
18087 'type': 'object'},
18088 'Endpoint': {'additionalProperties': False,
18089 'properties': {'ApplicationName': {'type': 'string'},
18090 'Relation': {'$ref': '#/definitions/Relation'}},
18091 'required': ['ApplicationName', 'Relation'],
18092 'type': 'object'},
18093 'Entities': {'additionalProperties': False,
18094 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
18095 'type': 'array'}},
18096 'required': ['Entities'],
18097 'type': 'object'},
18098 'EntitiesCharmURL': {'additionalProperties': False,
18099 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityCharmURL'},
18100 'type': 'array'}},
18101 'required': ['Entities'],
18102 'type': 'object'},
18103 'EntitiesPortRanges': {'additionalProperties': False,
18104 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityPortRange'},
18105 'type': 'array'}},
18106 'required': ['Entities'],
18107 'type': 'object'},
18108 'Entity': {'additionalProperties': False,
18109 'properties': {'Tag': {'type': 'string'}},
18110 'required': ['Tag'],
18111 'type': 'object'},
18112 'EntityCharmURL': {'additionalProperties': False,
18113 'properties': {'CharmURL': {'type': 'string'},
18114 'Tag': {'type': 'string'}},
18115 'required': ['Tag', 'CharmURL'],
18116 'type': 'object'},
18117 'EntityPortRange': {'additionalProperties': False,
18118 'properties': {'FromPort': {'type': 'integer'},
18119 'Protocol': {'type': 'string'},
18120 'Tag': {'type': 'string'},
18121 'ToPort': {'type': 'integer'}},
18122 'required': ['Tag',
18123 'Protocol',
18124 'FromPort',
18125 'ToPort'],
18126 'type': 'object'},
18127 'EntityStatusArgs': {'additionalProperties': False,
18128 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
18129 'type': 'object'}},
18130 'type': 'object'},
18131 'Info': {'type': 'string'},
18132 'Status': {'type': 'string'},
18133 'Tag': {'type': 'string'}},
18134 'required': ['Tag',
18135 'Status',
18136 'Info',
18137 'Data'],
18138 'type': 'object'},
18139 'Error': {'additionalProperties': False,
18140 'properties': {'Code': {'type': 'string'},
18141 'Info': {'$ref': '#/definitions/ErrorInfo'},
18142 'Message': {'type': 'string'}},
18143 'required': ['Message', 'Code'],
18144 'type': 'object'},
18145 'ErrorInfo': {'additionalProperties': False,
18146 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
18147 'MacaroonPath': {'type': 'string'}},
18148 'type': 'object'},
18149 'ErrorResult': {'additionalProperties': False,
18150 'properties': {'Error': {'$ref': '#/definitions/Error'}},
18151 'required': ['Error'],
18152 'type': 'object'},
18153 'ErrorResults': {'additionalProperties': False,
18154 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
18155 'type': 'array'}},
18156 'required': ['Results'],
18157 'type': 'object'},
18158 'GetLeadershipSettingsBulkResults': {'additionalProperties': False,
18159 'properties': {'Results': {'items': {'$ref': '#/definitions/GetLeadershipSettingsResult'},
18160 'type': 'array'}},
18161 'required': ['Results'],
18162 'type': 'object'},
18163 'GetLeadershipSettingsResult': {'additionalProperties': False,
18164 'properties': {'Error': {'$ref': '#/definitions/Error'},
18165 'Settings': {'patternProperties': {'.*': {'type': 'string'}},
18166 'type': 'object'}},
18167 'required': ['Settings',
18168 'Error'],
18169 'type': 'object'},
18170 'HostPort': {'additionalProperties': False,
18171 'properties': {'Address': {'$ref': '#/definitions/Address'},
18172 'Port': {'type': 'integer'}},
18173 'required': ['Address', 'Port'],
18174 'type': 'object'},
18175 'IntResult': {'additionalProperties': False,
18176 'properties': {'Error': {'$ref': '#/definitions/Error'},
18177 'Result': {'type': 'integer'}},
18178 'required': ['Error', 'Result'],
18179 'type': 'object'},
18180 'IntResults': {'additionalProperties': False,
18181 'properties': {'Results': {'items': {'$ref': '#/definitions/IntResult'},
18182 'type': 'array'}},
18183 'required': ['Results'],
18184 'type': 'object'},
18185 'LifeResult': {'additionalProperties': False,
18186 'properties': {'Error': {'$ref': '#/definitions/Error'},
18187 'Life': {'type': 'string'}},
18188 'required': ['Life', 'Error'],
18189 'type': 'object'},
18190 'LifeResults': {'additionalProperties': False,
18191 'properties': {'Results': {'items': {'$ref': '#/definitions/LifeResult'},
18192 'type': 'array'}},
18193 'required': ['Results'],
18194 'type': 'object'},
18195 'Macaroon': {'additionalProperties': False,
18196 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
18197 'type': 'array'},
18198 'data': {'items': {'type': 'integer'},
18199 'type': 'array'},
18200 'id': {'$ref': '#/definitions/packet'},
18201 'location': {'$ref': '#/definitions/packet'},
18202 'sig': {'items': {'type': 'integer'},
18203 'type': 'array'}},
18204 'required': ['data',
18205 'location',
18206 'id',
18207 'caveats',
18208 'sig'],
18209 'type': 'object'},
18210 'MachinePortRange': {'additionalProperties': False,
18211 'properties': {'PortRange': {'$ref': '#/definitions/PortRange'},
18212 'RelationTag': {'type': 'string'},
18213 'UnitTag': {'type': 'string'}},
18214 'required': ['UnitTag',
18215 'RelationTag',
18216 'PortRange'],
18217 'type': 'object'},
18218 'MachinePortsResult': {'additionalProperties': False,
18219 'properties': {'Error': {'$ref': '#/definitions/Error'},
18220 'Ports': {'items': {'$ref': '#/definitions/MachinePortRange'},
18221 'type': 'array'}},
18222 'required': ['Error', 'Ports'],
18223 'type': 'object'},
18224 'MachinePortsResults': {'additionalProperties': False,
18225 'properties': {'Results': {'items': {'$ref': '#/definitions/MachinePortsResult'},
18226 'type': 'array'}},
18227 'required': ['Results'],
18228 'type': 'object'},
18229 'MergeLeadershipSettingsBulkParams': {'additionalProperties': False,
18230 'properties': {'Params': {'items': {'$ref': '#/definitions/MergeLeadershipSettingsParam'},
18231 'type': 'array'}},
18232 'required': ['Params'],
18233 'type': 'object'},
18234 'MergeLeadershipSettingsParam': {'additionalProperties': False,
18235 'properties': {'ApplicationTag': {'type': 'string'},
18236 'Settings': {'patternProperties': {'.*': {'type': 'string'}},
18237 'type': 'object'}},
18238 'required': ['ApplicationTag',
18239 'Settings'],
18240 'type': 'object'},
18241 'MeterStatusResult': {'additionalProperties': False,
18242 'properties': {'Code': {'type': 'string'},
18243 'Error': {'$ref': '#/definitions/Error'},
18244 'Info': {'type': 'string'}},
18245 'required': ['Code', 'Info', 'Error'],
18246 'type': 'object'},
18247 'MeterStatusResults': {'additionalProperties': False,
18248 'properties': {'Results': {'items': {'$ref': '#/definitions/MeterStatusResult'},
18249 'type': 'array'}},
18250 'required': ['Results'],
18251 'type': 'object'},
18252 'Metric': {'additionalProperties': False,
18253 'properties': {'Key': {'type': 'string'},
18254 'Time': {'format': 'date-time',
18255 'type': 'string'},
18256 'Value': {'type': 'string'}},
18257 'required': ['Key', 'Value', 'Time'],
18258 'type': 'object'},
18259 'MetricBatch': {'additionalProperties': False,
18260 'properties': {'CharmURL': {'type': 'string'},
18261 'Created': {'format': 'date-time',
18262 'type': 'string'},
18263 'Metrics': {'items': {'$ref': '#/definitions/Metric'},
18264 'type': 'array'},
18265 'UUID': {'type': 'string'}},
18266 'required': ['UUID',
18267 'CharmURL',
18268 'Created',
18269 'Metrics'],
18270 'type': 'object'},
18271 'MetricBatchParam': {'additionalProperties': False,
18272 'properties': {'Batch': {'$ref': '#/definitions/MetricBatch'},
18273 'Tag': {'type': 'string'}},
18274 'required': ['Tag', 'Batch'],
18275 'type': 'object'},
18276 'MetricBatchParams': {'additionalProperties': False,
18277 'properties': {'Batches': {'items': {'$ref': '#/definitions/MetricBatchParam'},
18278 'type': 'array'}},
18279 'required': ['Batches'],
18280 'type': 'object'},
18281 'ModelConfigResult': {'additionalProperties': False,
18282 'properties': {'Config': {'patternProperties': {'.*': {'additionalProperties': True,
18283 'type': 'object'}},
18284 'type': 'object'}},
18285 'required': ['Config'],
18286 'type': 'object'},
18287 'ModelResult': {'additionalProperties': False,
18288 'properties': {'Error': {'$ref': '#/definitions/Error'},
18289 'Name': {'type': 'string'},
18290 'UUID': {'type': 'string'}},
18291 'required': ['Error', 'Name', 'UUID'],
18292 'type': 'object'},
18293 'NetworkConfig': {'additionalProperties': False,
18294 'properties': {'Address': {'type': 'string'},
18295 'CIDR': {'type': 'string'},
18296 'ConfigType': {'type': 'string'},
18297 'DNSSearchDomains': {'items': {'type': 'string'},
18298 'type': 'array'},
18299 'DNSServers': {'items': {'type': 'string'},
18300 'type': 'array'},
18301 'DeviceIndex': {'type': 'integer'},
18302 'Disabled': {'type': 'boolean'},
18303 'GatewayAddress': {'type': 'string'},
18304 'InterfaceName': {'type': 'string'},
18305 'InterfaceType': {'type': 'string'},
18306 'MACAddress': {'type': 'string'},
18307 'MTU': {'type': 'integer'},
18308 'NoAutoStart': {'type': 'boolean'},
18309 'ParentInterfaceName': {'type': 'string'},
18310 'ProviderAddressId': {'type': 'string'},
18311 'ProviderId': {'type': 'string'},
18312 'ProviderSpaceId': {'type': 'string'},
18313 'ProviderSubnetId': {'type': 'string'},
18314 'ProviderVLANId': {'type': 'string'},
18315 'VLANTag': {'type': 'integer'}},
18316 'required': ['DeviceIndex',
18317 'MACAddress',
18318 'CIDR',
18319 'MTU',
18320 'ProviderId',
18321 'ProviderSubnetId',
18322 'ProviderSpaceId',
18323 'ProviderAddressId',
18324 'ProviderVLANId',
18325 'VLANTag',
18326 'InterfaceName',
18327 'ParentInterfaceName',
18328 'InterfaceType',
18329 'Disabled'],
18330 'type': 'object'},
18331 'NotifyWatchResult': {'additionalProperties': False,
18332 'properties': {'Error': {'$ref': '#/definitions/Error'},
18333 'NotifyWatcherId': {'type': 'string'}},
18334 'required': ['NotifyWatcherId', 'Error'],
18335 'type': 'object'},
18336 'NotifyWatchResults': {'additionalProperties': False,
18337 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
18338 'type': 'array'}},
18339 'required': ['Results'],
18340 'type': 'object'},
18341 'PortRange': {'additionalProperties': False,
18342 'properties': {'FromPort': {'type': 'integer'},
18343 'Protocol': {'type': 'string'},
18344 'ToPort': {'type': 'integer'}},
18345 'required': ['FromPort', 'ToPort', 'Protocol'],
18346 'type': 'object'},
18347 'Relation': {'additionalProperties': False,
18348 'properties': {'Interface': {'type': 'string'},
18349 'Limit': {'type': 'integer'},
18350 'Name': {'type': 'string'},
18351 'Optional': {'type': 'boolean'},
18352 'Role': {'type': 'string'},
18353 'Scope': {'type': 'string'}},
18354 'required': ['Name',
18355 'Role',
18356 'Interface',
18357 'Optional',
18358 'Limit',
18359 'Scope'],
18360 'type': 'object'},
18361 'RelationIds': {'additionalProperties': False,
18362 'properties': {'RelationIds': {'items': {'type': 'integer'},
18363 'type': 'array'}},
18364 'required': ['RelationIds'],
18365 'type': 'object'},
18366 'RelationResult': {'additionalProperties': False,
18367 'properties': {'Endpoint': {'$ref': '#/definitions/Endpoint'},
18368 'Error': {'$ref': '#/definitions/Error'},
18369 'Id': {'type': 'integer'},
18370 'Key': {'type': 'string'},
18371 'Life': {'type': 'string'}},
18372 'required': ['Error',
18373 'Life',
18374 'Id',
18375 'Key',
18376 'Endpoint'],
18377 'type': 'object'},
18378 'RelationResults': {'additionalProperties': False,
18379 'properties': {'Results': {'items': {'$ref': '#/definitions/RelationResult'},
18380 'type': 'array'}},
18381 'required': ['Results'],
18382 'type': 'object'},
18383 'RelationUnit': {'additionalProperties': False,
18384 'properties': {'Relation': {'type': 'string'},
18385 'Unit': {'type': 'string'}},
18386 'required': ['Relation', 'Unit'],
18387 'type': 'object'},
18388 'RelationUnitPair': {'additionalProperties': False,
18389 'properties': {'LocalUnit': {'type': 'string'},
18390 'Relation': {'type': 'string'},
18391 'RemoteUnit': {'type': 'string'}},
18392 'required': ['Relation',
18393 'LocalUnit',
18394 'RemoteUnit'],
18395 'type': 'object'},
18396 'RelationUnitPairs': {'additionalProperties': False,
18397 'properties': {'RelationUnitPairs': {'items': {'$ref': '#/definitions/RelationUnitPair'},
18398 'type': 'array'}},
18399 'required': ['RelationUnitPairs'],
18400 'type': 'object'},
18401 'RelationUnitSettings': {'additionalProperties': False,
18402 'properties': {'Relation': {'type': 'string'},
18403 'Settings': {'patternProperties': {'.*': {'type': 'string'}},
18404 'type': 'object'},
18405 'Unit': {'type': 'string'}},
18406 'required': ['Relation',
18407 'Unit',
18408 'Settings'],
18409 'type': 'object'},
18410 'RelationUnits': {'additionalProperties': False,
18411 'properties': {'RelationUnits': {'items': {'$ref': '#/definitions/RelationUnit'},
18412 'type': 'array'}},
18413 'required': ['RelationUnits'],
18414 'type': 'object'},
18415 'RelationUnitsChange': {'additionalProperties': False,
18416 'properties': {'Changed': {'patternProperties': {'.*': {'$ref': '#/definitions/UnitSettings'}},
18417 'type': 'object'},
18418 'Departed': {'items': {'type': 'string'},
18419 'type': 'array'}},
18420 'required': ['Changed', 'Departed'],
18421 'type': 'object'},
18422 'RelationUnitsSettings': {'additionalProperties': False,
18423 'properties': {'RelationUnits': {'items': {'$ref': '#/definitions/RelationUnitSettings'},
18424 'type': 'array'}},
18425 'required': ['RelationUnits'],
18426 'type': 'object'},
18427 'RelationUnitsWatchResult': {'additionalProperties': False,
18428 'properties': {'Changes': {'$ref': '#/definitions/RelationUnitsChange'},
18429 'Error': {'$ref': '#/definitions/Error'},
18430 'RelationUnitsWatcherId': {'type': 'string'}},
18431 'required': ['RelationUnitsWatcherId',
18432 'Changes',
18433 'Error'],
18434 'type': 'object'},
18435 'RelationUnitsWatchResults': {'additionalProperties': False,
18436 'properties': {'Results': {'items': {'$ref': '#/definitions/RelationUnitsWatchResult'},
18437 'type': 'array'}},
18438 'required': ['Results'],
18439 'type': 'object'},
18440 'ResolvedModeResult': {'additionalProperties': False,
18441 'properties': {'Error': {'$ref': '#/definitions/Error'},
18442 'Mode': {'type': 'string'}},
18443 'required': ['Error', 'Mode'],
18444 'type': 'object'},
18445 'ResolvedModeResults': {'additionalProperties': False,
18446 'properties': {'Results': {'items': {'$ref': '#/definitions/ResolvedModeResult'},
18447 'type': 'array'}},
18448 'required': ['Results'],
18449 'type': 'object'},
18450 'SetStatus': {'additionalProperties': False,
18451 'properties': {'Entities': {'items': {'$ref': '#/definitions/EntityStatusArgs'},
18452 'type': 'array'}},
18453 'required': ['Entities'],
18454 'type': 'object'},
18455 'SettingsResult': {'additionalProperties': False,
18456 'properties': {'Error': {'$ref': '#/definitions/Error'},
18457 'Settings': {'patternProperties': {'.*': {'type': 'string'}},
18458 'type': 'object'}},
18459 'required': ['Error', 'Settings'],
18460 'type': 'object'},
18461 'SettingsResults': {'additionalProperties': False,
18462 'properties': {'Results': {'items': {'$ref': '#/definitions/SettingsResult'},
18463 'type': 'array'}},
18464 'required': ['Results'],
18465 'type': 'object'},
18466 'StatusResult': {'additionalProperties': False,
18467 'properties': {'Data': {'patternProperties': {'.*': {'additionalProperties': True,
18468 'type': 'object'}},
18469 'type': 'object'},
18470 'Error': {'$ref': '#/definitions/Error'},
18471 'Id': {'type': 'string'},
18472 'Info': {'type': 'string'},
18473 'Life': {'type': 'string'},
18474 'Since': {'format': 'date-time',
18475 'type': 'string'},
18476 'Status': {'type': 'string'}},
18477 'required': ['Error',
18478 'Id',
18479 'Life',
18480 'Status',
18481 'Info',
18482 'Data',
18483 'Since'],
18484 'type': 'object'},
18485 'StatusResults': {'additionalProperties': False,
18486 'properties': {'Results': {'items': {'$ref': '#/definitions/StatusResult'},
18487 'type': 'array'}},
18488 'required': ['Results'],
18489 'type': 'object'},
18490 'StorageAddParams': {'additionalProperties': False,
18491 'properties': {'StorageName': {'type': 'string'},
18492 'storage': {'$ref': '#/definitions/StorageConstraints'},
18493 'unit': {'type': 'string'}},
18494 'required': ['unit',
18495 'StorageName',
18496 'storage'],
18497 'type': 'object'},
18498 'StorageAttachment': {'additionalProperties': False,
18499 'properties': {'Kind': {'type': 'integer'},
18500 'Life': {'type': 'string'},
18501 'Location': {'type': 'string'},
18502 'OwnerTag': {'type': 'string'},
18503 'StorageTag': {'type': 'string'},
18504 'UnitTag': {'type': 'string'}},
18505 'required': ['StorageTag',
18506 'OwnerTag',
18507 'UnitTag',
18508 'Kind',
18509 'Location',
18510 'Life'],
18511 'type': 'object'},
18512 'StorageAttachmentId': {'additionalProperties': False,
18513 'properties': {'storagetag': {'type': 'string'},
18514 'unittag': {'type': 'string'}},
18515 'required': ['storagetag', 'unittag'],
18516 'type': 'object'},
18517 'StorageAttachmentIds': {'additionalProperties': False,
18518 'properties': {'ids': {'items': {'$ref': '#/definitions/StorageAttachmentId'},
18519 'type': 'array'}},
18520 'required': ['ids'],
18521 'type': 'object'},
18522 'StorageAttachmentIdsResult': {'additionalProperties': False,
18523 'properties': {'error': {'$ref': '#/definitions/Error'},
18524 'result': {'$ref': '#/definitions/StorageAttachmentIds'}},
18525 'required': ['result'],
18526 'type': 'object'},
18527 'StorageAttachmentIdsResults': {'additionalProperties': False,
18528 'properties': {'results': {'items': {'$ref': '#/definitions/StorageAttachmentIdsResult'},
18529 'type': 'array'}},
18530 'type': 'object'},
18531 'StorageAttachmentResult': {'additionalProperties': False,
18532 'properties': {'error': {'$ref': '#/definitions/Error'},
18533 'result': {'$ref': '#/definitions/StorageAttachment'}},
18534 'required': ['result'],
18535 'type': 'object'},
18536 'StorageAttachmentResults': {'additionalProperties': False,
18537 'properties': {'results': {'items': {'$ref': '#/definitions/StorageAttachmentResult'},
18538 'type': 'array'}},
18539 'type': 'object'},
18540 'StorageConstraints': {'additionalProperties': False,
18541 'properties': {'Count': {'type': 'integer'},
18542 'Pool': {'type': 'string'},
18543 'Size': {'type': 'integer'}},
18544 'required': ['Pool', 'Size', 'Count'],
18545 'type': 'object'},
18546 'StoragesAddParams': {'additionalProperties': False,
18547 'properties': {'storages': {'items': {'$ref': '#/definitions/StorageAddParams'},
18548 'type': 'array'}},
18549 'required': ['storages'],
18550 'type': 'object'},
18551 'StringBoolResult': {'additionalProperties': False,
18552 'properties': {'Error': {'$ref': '#/definitions/Error'},
18553 'Ok': {'type': 'boolean'},
18554 'Result': {'type': 'string'}},
18555 'required': ['Error', 'Result', 'Ok'],
18556 'type': 'object'},
18557 'StringBoolResults': {'additionalProperties': False,
18558 'properties': {'Results': {'items': {'$ref': '#/definitions/StringBoolResult'},
18559 'type': 'array'}},
18560 'required': ['Results'],
18561 'type': 'object'},
18562 'StringResult': {'additionalProperties': False,
18563 'properties': {'Error': {'$ref': '#/definitions/Error'},
18564 'Result': {'type': 'string'}},
18565 'required': ['Error', 'Result'],
18566 'type': 'object'},
18567 'StringResults': {'additionalProperties': False,
18568 'properties': {'Results': {'items': {'$ref': '#/definitions/StringResult'},
18569 'type': 'array'}},
18570 'required': ['Results'],
18571 'type': 'object'},
18572 'StringsResult': {'additionalProperties': False,
18573 'properties': {'Error': {'$ref': '#/definitions/Error'},
18574 'Result': {'items': {'type': 'string'},
18575 'type': 'array'}},
18576 'required': ['Error', 'Result'],
18577 'type': 'object'},
18578 'StringsResults': {'additionalProperties': False,
18579 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsResult'},
18580 'type': 'array'}},
18581 'required': ['Results'],
18582 'type': 'object'},
18583 'StringsWatchResult': {'additionalProperties': False,
18584 'properties': {'Changes': {'items': {'type': 'string'},
18585 'type': 'array'},
18586 'Error': {'$ref': '#/definitions/Error'},
18587 'StringsWatcherId': {'type': 'string'}},
18588 'required': ['StringsWatcherId',
18589 'Changes',
18590 'Error'],
18591 'type': 'object'},
18592 'StringsWatchResults': {'additionalProperties': False,
18593 'properties': {'Results': {'items': {'$ref': '#/definitions/StringsWatchResult'},
18594 'type': 'array'}},
18595 'required': ['Results'],
18596 'type': 'object'},
18597 'UnitNetworkConfig': {'additionalProperties': False,
18598 'properties': {'BindingName': {'type': 'string'},
18599 'UnitTag': {'type': 'string'}},
18600 'required': ['UnitTag', 'BindingName'],
18601 'type': 'object'},
18602 'UnitNetworkConfigResult': {'additionalProperties': False,
18603 'properties': {'Error': {'$ref': '#/definitions/Error'},
18604 'Info': {'items': {'$ref': '#/definitions/NetworkConfig'},
18605 'type': 'array'}},
18606 'required': ['Error', 'Info'],
18607 'type': 'object'},
18608 'UnitNetworkConfigResults': {'additionalProperties': False,
18609 'properties': {'Results': {'items': {'$ref': '#/definitions/UnitNetworkConfigResult'},
18610 'type': 'array'}},
18611 'required': ['Results'],
18612 'type': 'object'},
18613 'UnitSettings': {'additionalProperties': False,
18614 'properties': {'Version': {'type': 'integer'}},
18615 'required': ['Version'],
18616 'type': 'object'},
18617 'UnitsNetworkConfig': {'additionalProperties': False,
18618 'properties': {'Args': {'items': {'$ref': '#/definitions/UnitNetworkConfig'},
18619 'type': 'array'}},
18620 'required': ['Args'],
18621 'type': 'object'},
18622 'caveat': {'additionalProperties': False,
18623 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
18624 'location': {'$ref': '#/definitions/packet'},
18625 'verificationId': {'$ref': '#/definitions/packet'}},
18626 'required': ['location',
18627 'caveatId',
18628 'verificationId'],
18629 'type': 'object'},
18630 'packet': {'additionalProperties': False,
18631 'properties': {'headerLen': {'type': 'integer'},
18632 'start': {'type': 'integer'},
18633 'totalLen': {'type': 'integer'}},
18634 'required': ['start', 'totalLen', 'headerLen'],
18635 'type': 'object'}},
18636 'properties': {'APIAddresses': {'properties': {'Result': {'$ref': '#/definitions/StringsResult'}},
18637 'type': 'object'},
18638 'APIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/APIHostPortsResult'}},
18639 'type': 'object'},
18640 'Actions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18641 'Result': {'$ref': '#/definitions/ActionResults'}},
18642 'type': 'object'},
18643 'AddMetricBatches': {'properties': {'Params': {'$ref': '#/definitions/MetricBatchParams'},
18644 'Result': {'$ref': '#/definitions/ErrorResults'}},
18645 'type': 'object'},
18646 'AddUnitStorage': {'properties': {'Params': {'$ref': '#/definitions/StoragesAddParams'},
18647 'Result': {'$ref': '#/definitions/ErrorResults'}},
18648 'type': 'object'},
18649 'AllMachinePorts': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18650 'Result': {'$ref': '#/definitions/MachinePortsResults'}},
18651 'type': 'object'},
18652 'ApplicationOwner': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18653 'Result': {'$ref': '#/definitions/StringResults'}},
18654 'type': 'object'},
18655 'ApplicationStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18656 'Result': {'$ref': '#/definitions/ApplicationStatusResults'}},
18657 'type': 'object'},
18658 'AssignedMachine': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18659 'Result': {'$ref': '#/definitions/StringResults'}},
18660 'type': 'object'},
18661 'AvailabilityZone': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18662 'Result': {'$ref': '#/definitions/StringResults'}},
18663 'type': 'object'},
18664 'BeginActions': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18665 'Result': {'$ref': '#/definitions/ErrorResults'}},
18666 'type': 'object'},
18667 'CACert': {'properties': {'Result': {'$ref': '#/definitions/BytesResult'}},
18668 'type': 'object'},
18669 'CharmArchiveSha256': {'properties': {'Params': {'$ref': '#/definitions/CharmURLs'},
18670 'Result': {'$ref': '#/definitions/StringResults'}},
18671 'type': 'object'},
18672 'CharmModifiedVersion': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18673 'Result': {'$ref': '#/definitions/IntResults'}},
18674 'type': 'object'},
18675 'CharmURL': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18676 'Result': {'$ref': '#/definitions/StringBoolResults'}},
18677 'type': 'object'},
18678 'ClearResolved': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18679 'Result': {'$ref': '#/definitions/ErrorResults'}},
18680 'type': 'object'},
18681 'ClosePorts': {'properties': {'Params': {'$ref': '#/definitions/EntitiesPortRanges'},
18682 'Result': {'$ref': '#/definitions/ErrorResults'}},
18683 'type': 'object'},
18684 'ConfigSettings': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18685 'Result': {'$ref': '#/definitions/ConfigSettingsResults'}},
18686 'type': 'object'},
18687 'CurrentModel': {'properties': {'Result': {'$ref': '#/definitions/ModelResult'}},
18688 'type': 'object'},
18689 'Destroy': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18690 'Result': {'$ref': '#/definitions/ErrorResults'}},
18691 'type': 'object'},
18692 'DestroyAllSubordinates': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18693 'Result': {'$ref': '#/definitions/ErrorResults'}},
18694 'type': 'object'},
18695 'DestroyUnitStorageAttachments': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18696 'Result': {'$ref': '#/definitions/ErrorResults'}},
18697 'type': 'object'},
18698 'EnsureDead': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18699 'Result': {'$ref': '#/definitions/ErrorResults'}},
18700 'type': 'object'},
18701 'EnterScope': {'properties': {'Params': {'$ref': '#/definitions/RelationUnits'},
18702 'Result': {'$ref': '#/definitions/ErrorResults'}},
18703 'type': 'object'},
18704 'FinishActions': {'properties': {'Params': {'$ref': '#/definitions/ActionExecutionResults'},
18705 'Result': {'$ref': '#/definitions/ErrorResults'}},
18706 'type': 'object'},
18707 'GetMeterStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18708 'Result': {'$ref': '#/definitions/MeterStatusResults'}},
18709 'type': 'object'},
18710 'GetPrincipal': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18711 'Result': {'$ref': '#/definitions/StringBoolResults'}},
18712 'type': 'object'},
18713 'HasSubordinates': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18714 'Result': {'$ref': '#/definitions/BoolResults'}},
18715 'type': 'object'},
18716 'JoinedRelations': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18717 'Result': {'$ref': '#/definitions/StringsResults'}},
18718 'type': 'object'},
18719 'LeaveScope': {'properties': {'Params': {'$ref': '#/definitions/RelationUnits'},
18720 'Result': {'$ref': '#/definitions/ErrorResults'}},
18721 'type': 'object'},
18722 'Life': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18723 'Result': {'$ref': '#/definitions/LifeResults'}},
18724 'type': 'object'},
18725 'Merge': {'properties': {'Params': {'$ref': '#/definitions/MergeLeadershipSettingsBulkParams'},
18726 'Result': {'$ref': '#/definitions/ErrorResults'}},
18727 'type': 'object'},
18728 'ModelConfig': {'properties': {'Result': {'$ref': '#/definitions/ModelConfigResult'}},
18729 'type': 'object'},
18730 'ModelUUID': {'properties': {'Result': {'$ref': '#/definitions/StringResult'}},
18731 'type': 'object'},
18732 'NetworkConfig': {'properties': {'Params': {'$ref': '#/definitions/UnitsNetworkConfig'},
18733 'Result': {'$ref': '#/definitions/UnitNetworkConfigResults'}},
18734 'type': 'object'},
18735 'OpenPorts': {'properties': {'Params': {'$ref': '#/definitions/EntitiesPortRanges'},
18736 'Result': {'$ref': '#/definitions/ErrorResults'}},
18737 'type': 'object'},
18738 'PrivateAddress': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18739 'Result': {'$ref': '#/definitions/StringResults'}},
18740 'type': 'object'},
18741 'ProviderType': {'properties': {'Result': {'$ref': '#/definitions/StringResult'}},
18742 'type': 'object'},
18743 'PublicAddress': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18744 'Result': {'$ref': '#/definitions/StringResults'}},
18745 'type': 'object'},
18746 'Read': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18747 'Result': {'$ref': '#/definitions/GetLeadershipSettingsBulkResults'}},
18748 'type': 'object'},
18749 'ReadRemoteSettings': {'properties': {'Params': {'$ref': '#/definitions/RelationUnitPairs'},
18750 'Result': {'$ref': '#/definitions/SettingsResults'}},
18751 'type': 'object'},
18752 'ReadSettings': {'properties': {'Params': {'$ref': '#/definitions/RelationUnits'},
18753 'Result': {'$ref': '#/definitions/SettingsResults'}},
18754 'type': 'object'},
18755 'Relation': {'properties': {'Params': {'$ref': '#/definitions/RelationUnits'},
18756 'Result': {'$ref': '#/definitions/RelationResults'}},
18757 'type': 'object'},
18758 'RelationById': {'properties': {'Params': {'$ref': '#/definitions/RelationIds'},
18759 'Result': {'$ref': '#/definitions/RelationResults'}},
18760 'type': 'object'},
18761 'RemoveStorageAttachments': {'properties': {'Params': {'$ref': '#/definitions/StorageAttachmentIds'},
18762 'Result': {'$ref': '#/definitions/ErrorResults'}},
18763 'type': 'object'},
18764 'RequestReboot': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18765 'Result': {'$ref': '#/definitions/ErrorResults'}},
18766 'type': 'object'},
18767 'Resolved': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18768 'Result': {'$ref': '#/definitions/ResolvedModeResults'}},
18769 'type': 'object'},
18770 'SetAgentStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
18771 'Result': {'$ref': '#/definitions/ErrorResults'}},
18772 'type': 'object'},
18773 'SetApplicationStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
18774 'Result': {'$ref': '#/definitions/ErrorResults'}},
18775 'type': 'object'},
18776 'SetCharmURL': {'properties': {'Params': {'$ref': '#/definitions/EntitiesCharmURL'},
18777 'Result': {'$ref': '#/definitions/ErrorResults'}},
18778 'type': 'object'},
18779 'SetStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
18780 'Result': {'$ref': '#/definitions/ErrorResults'}},
18781 'type': 'object'},
18782 'SetUnitStatus': {'properties': {'Params': {'$ref': '#/definitions/SetStatus'},
18783 'Result': {'$ref': '#/definitions/ErrorResults'}},
18784 'type': 'object'},
18785 'StorageAttachmentLife': {'properties': {'Params': {'$ref': '#/definitions/StorageAttachmentIds'},
18786 'Result': {'$ref': '#/definitions/LifeResults'}},
18787 'type': 'object'},
18788 'StorageAttachments': {'properties': {'Params': {'$ref': '#/definitions/StorageAttachmentIds'},
18789 'Result': {'$ref': '#/definitions/StorageAttachmentResults'}},
18790 'type': 'object'},
18791 'UnitStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18792 'Result': {'$ref': '#/definitions/StatusResults'}},
18793 'type': 'object'},
18794 'UnitStorageAttachments': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18795 'Result': {'$ref': '#/definitions/StorageAttachmentIdsResults'}},
18796 'type': 'object'},
18797 'UpdateSettings': {'properties': {'Params': {'$ref': '#/definitions/RelationUnitsSettings'},
18798 'Result': {'$ref': '#/definitions/ErrorResults'}},
18799 'type': 'object'},
18800 'Watch': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18801 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
18802 'type': 'object'},
18803 'WatchAPIHostPorts': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
18804 'type': 'object'},
18805 'WatchActionNotifications': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18806 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
18807 'type': 'object'},
18808 'WatchApplicationRelations': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18809 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
18810 'type': 'object'},
18811 'WatchConfigSettings': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18812 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
18813 'type': 'object'},
18814 'WatchForModelConfigChanges': {'properties': {'Result': {'$ref': '#/definitions/NotifyWatchResult'}},
18815 'type': 'object'},
18816 'WatchLeadershipSettings': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18817 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
18818 'type': 'object'},
18819 'WatchMeterStatus': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18820 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
18821 'type': 'object'},
18822 'WatchRelationUnits': {'properties': {'Params': {'$ref': '#/definitions/RelationUnits'},
18823 'Result': {'$ref': '#/definitions/RelationUnitsWatchResults'}},
18824 'type': 'object'},
18825 'WatchStorageAttachments': {'properties': {'Params': {'$ref': '#/definitions/StorageAttachmentIds'},
18826 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
18827 'type': 'object'},
18828 'WatchUnitAddresses': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18829 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
18830 'type': 'object'},
18831 'WatchUnitStorageAttachments': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
18832 'Result': {'$ref': '#/definitions/StringsWatchResults'}},
18833 'type': 'object'}},
18834 'type': 'object'}
18835
18836
18837 @ReturnMapping(StringsResult)
18838 async def APIAddresses(self):
18839 '''
18840
18841 Returns -> typing.Union[_ForwardRef('Error'), typing.Sequence[str]]
18842 '''
18843 # map input types to rpc msg
18844 params = dict()
18845 msg = dict(Type='Uniter', Request='APIAddresses', Version=4, Params=params)
18846
18847 reply = await self.rpc(msg)
18848 return reply
18849
18850
18851
18852 @ReturnMapping(APIHostPortsResult)
18853 async def APIHostPorts(self):
18854 '''
18855
18856 Returns -> typing.Sequence[~HostPort]
18857 '''
18858 # map input types to rpc msg
18859 params = dict()
18860 msg = dict(Type='Uniter', Request='APIHostPorts', Version=4, Params=params)
18861
18862 reply = await self.rpc(msg)
18863 return reply
18864
18865
18866
18867 @ReturnMapping(ActionResults)
18868 async def Actions(self, entities):
18869 '''
18870 entities : typing.Sequence[~Entity]
18871 Returns -> typing.Sequence[~ActionResult]
18872 '''
18873 # map input types to rpc msg
18874 params = dict()
18875 msg = dict(Type='Uniter', Request='Actions', Version=4, Params=params)
18876 params['Entities'] = entities
18877 reply = await self.rpc(msg)
18878 return reply
18879
18880
18881
18882 @ReturnMapping(ErrorResults)
18883 async def AddMetricBatches(self, batches):
18884 '''
18885 batches : typing.Sequence[~MetricBatchParam]
18886 Returns -> typing.Sequence[~ErrorResult]
18887 '''
18888 # map input types to rpc msg
18889 params = dict()
18890 msg = dict(Type='Uniter', Request='AddMetricBatches', Version=4, Params=params)
18891 params['Batches'] = batches
18892 reply = await self.rpc(msg)
18893 return reply
18894
18895
18896
18897 @ReturnMapping(ErrorResults)
18898 async def AddUnitStorage(self, storages):
18899 '''
18900 storages : typing.Sequence[~StorageAddParams]
18901 Returns -> typing.Sequence[~ErrorResult]
18902 '''
18903 # map input types to rpc msg
18904 params = dict()
18905 msg = dict(Type='Uniter', Request='AddUnitStorage', Version=4, Params=params)
18906 params['storages'] = storages
18907 reply = await self.rpc(msg)
18908 return reply
18909
18910
18911
18912 @ReturnMapping(MachinePortsResults)
18913 async def AllMachinePorts(self, entities):
18914 '''
18915 entities : typing.Sequence[~Entity]
18916 Returns -> typing.Sequence[~MachinePortsResult]
18917 '''
18918 # map input types to rpc msg
18919 params = dict()
18920 msg = dict(Type='Uniter', Request='AllMachinePorts', Version=4, Params=params)
18921 params['Entities'] = entities
18922 reply = await self.rpc(msg)
18923 return reply
18924
18925
18926
18927 @ReturnMapping(StringResults)
18928 async def ApplicationOwner(self, entities):
18929 '''
18930 entities : typing.Sequence[~Entity]
18931 Returns -> typing.Sequence[~StringResult]
18932 '''
18933 # map input types to rpc msg
18934 params = dict()
18935 msg = dict(Type='Uniter', Request='ApplicationOwner', Version=4, Params=params)
18936 params['Entities'] = entities
18937 reply = await self.rpc(msg)
18938 return reply
18939
18940
18941
18942 @ReturnMapping(ApplicationStatusResults)
18943 async def ApplicationStatus(self, entities):
18944 '''
18945 entities : typing.Sequence[~Entity]
18946 Returns -> typing.Sequence[~ApplicationStatusResult]
18947 '''
18948 # map input types to rpc msg
18949 params = dict()
18950 msg = dict(Type='Uniter', Request='ApplicationStatus', Version=4, Params=params)
18951 params['Entities'] = entities
18952 reply = await self.rpc(msg)
18953 return reply
18954
18955
18956
18957 @ReturnMapping(StringResults)
18958 async def AssignedMachine(self, entities):
18959 '''
18960 entities : typing.Sequence[~Entity]
18961 Returns -> typing.Sequence[~StringResult]
18962 '''
18963 # map input types to rpc msg
18964 params = dict()
18965 msg = dict(Type='Uniter', Request='AssignedMachine', Version=4, Params=params)
18966 params['Entities'] = entities
18967 reply = await self.rpc(msg)
18968 return reply
18969
18970
18971
18972 @ReturnMapping(StringResults)
18973 async def AvailabilityZone(self, entities):
18974 '''
18975 entities : typing.Sequence[~Entity]
18976 Returns -> typing.Sequence[~StringResult]
18977 '''
18978 # map input types to rpc msg
18979 params = dict()
18980 msg = dict(Type='Uniter', Request='AvailabilityZone', Version=4, Params=params)
18981 params['Entities'] = entities
18982 reply = await self.rpc(msg)
18983 return reply
18984
18985
18986
18987 @ReturnMapping(ErrorResults)
18988 async def BeginActions(self, entities):
18989 '''
18990 entities : typing.Sequence[~Entity]
18991 Returns -> typing.Sequence[~ErrorResult]
18992 '''
18993 # map input types to rpc msg
18994 params = dict()
18995 msg = dict(Type='Uniter', Request='BeginActions', Version=4, Params=params)
18996 params['Entities'] = entities
18997 reply = await self.rpc(msg)
18998 return reply
18999
19000
19001
19002 @ReturnMapping(BytesResult)
19003 async def CACert(self):
19004 '''
19005
19006 Returns -> typing.Sequence[int]
19007 '''
19008 # map input types to rpc msg
19009 params = dict()
19010 msg = dict(Type='Uniter', Request='CACert', Version=4, Params=params)
19011
19012 reply = await self.rpc(msg)
19013 return reply
19014
19015
19016
19017 @ReturnMapping(StringResults)
19018 async def CharmArchiveSha256(self, urls):
19019 '''
19020 urls : typing.Sequence[~CharmURL]
19021 Returns -> typing.Sequence[~StringResult]
19022 '''
19023 # map input types to rpc msg
19024 params = dict()
19025 msg = dict(Type='Uniter', Request='CharmArchiveSha256', Version=4, Params=params)
19026 params['URLs'] = urls
19027 reply = await self.rpc(msg)
19028 return reply
19029
19030
19031
19032 @ReturnMapping(IntResults)
19033 async def CharmModifiedVersion(self, entities):
19034 '''
19035 entities : typing.Sequence[~Entity]
19036 Returns -> typing.Sequence[~IntResult]
19037 '''
19038 # map input types to rpc msg
19039 params = dict()
19040 msg = dict(Type='Uniter', Request='CharmModifiedVersion', Version=4, Params=params)
19041 params['Entities'] = entities
19042 reply = await self.rpc(msg)
19043 return reply
19044
19045
19046
19047 @ReturnMapping(StringBoolResults)
19048 async def CharmURL(self, entities):
19049 '''
19050 entities : typing.Sequence[~Entity]
19051 Returns -> typing.Sequence[~StringBoolResult]
19052 '''
19053 # map input types to rpc msg
19054 params = dict()
19055 msg = dict(Type='Uniter', Request='CharmURL', Version=4, Params=params)
19056 params['Entities'] = entities
19057 reply = await self.rpc(msg)
19058 return reply
19059
19060
19061
19062 @ReturnMapping(ErrorResults)
19063 async def ClearResolved(self, entities):
19064 '''
19065 entities : typing.Sequence[~Entity]
19066 Returns -> typing.Sequence[~ErrorResult]
19067 '''
19068 # map input types to rpc msg
19069 params = dict()
19070 msg = dict(Type='Uniter', Request='ClearResolved', Version=4, Params=params)
19071 params['Entities'] = entities
19072 reply = await self.rpc(msg)
19073 return reply
19074
19075
19076
19077 @ReturnMapping(ErrorResults)
19078 async def ClosePorts(self, entities):
19079 '''
19080 entities : typing.Sequence[~EntityPortRange]
19081 Returns -> typing.Sequence[~ErrorResult]
19082 '''
19083 # map input types to rpc msg
19084 params = dict()
19085 msg = dict(Type='Uniter', Request='ClosePorts', Version=4, Params=params)
19086 params['Entities'] = entities
19087 reply = await self.rpc(msg)
19088 return reply
19089
19090
19091
19092 @ReturnMapping(ConfigSettingsResults)
19093 async def ConfigSettings(self, entities):
19094 '''
19095 entities : typing.Sequence[~Entity]
19096 Returns -> typing.Sequence[~ConfigSettingsResult]
19097 '''
19098 # map input types to rpc msg
19099 params = dict()
19100 msg = dict(Type='Uniter', Request='ConfigSettings', Version=4, Params=params)
19101 params['Entities'] = entities
19102 reply = await self.rpc(msg)
19103 return reply
19104
19105
19106
19107 @ReturnMapping(ModelResult)
19108 async def CurrentModel(self):
19109 '''
19110
19111 Returns -> typing.Union[_ForwardRef('Error'), str]
19112 '''
19113 # map input types to rpc msg
19114 params = dict()
19115 msg = dict(Type='Uniter', Request='CurrentModel', Version=4, Params=params)
19116
19117 reply = await self.rpc(msg)
19118 return reply
19119
19120
19121
19122 @ReturnMapping(ErrorResults)
19123 async def Destroy(self, entities):
19124 '''
19125 entities : typing.Sequence[~Entity]
19126 Returns -> typing.Sequence[~ErrorResult]
19127 '''
19128 # map input types to rpc msg
19129 params = dict()
19130 msg = dict(Type='Uniter', Request='Destroy', Version=4, Params=params)
19131 params['Entities'] = entities
19132 reply = await self.rpc(msg)
19133 return reply
19134
19135
19136
19137 @ReturnMapping(ErrorResults)
19138 async def DestroyAllSubordinates(self, entities):
19139 '''
19140 entities : typing.Sequence[~Entity]
19141 Returns -> typing.Sequence[~ErrorResult]
19142 '''
19143 # map input types to rpc msg
19144 params = dict()
19145 msg = dict(Type='Uniter', Request='DestroyAllSubordinates', Version=4, Params=params)
19146 params['Entities'] = entities
19147 reply = await self.rpc(msg)
19148 return reply
19149
19150
19151
19152 @ReturnMapping(ErrorResults)
19153 async def DestroyUnitStorageAttachments(self, entities):
19154 '''
19155 entities : typing.Sequence[~Entity]
19156 Returns -> typing.Sequence[~ErrorResult]
19157 '''
19158 # map input types to rpc msg
19159 params = dict()
19160 msg = dict(Type='Uniter', Request='DestroyUnitStorageAttachments', Version=4, Params=params)
19161 params['Entities'] = entities
19162 reply = await self.rpc(msg)
19163 return reply
19164
19165
19166
19167 @ReturnMapping(ErrorResults)
19168 async def EnsureDead(self, entities):
19169 '''
19170 entities : typing.Sequence[~Entity]
19171 Returns -> typing.Sequence[~ErrorResult]
19172 '''
19173 # map input types to rpc msg
19174 params = dict()
19175 msg = dict(Type='Uniter', Request='EnsureDead', Version=4, Params=params)
19176 params['Entities'] = entities
19177 reply = await self.rpc(msg)
19178 return reply
19179
19180
19181
19182 @ReturnMapping(ErrorResults)
19183 async def EnterScope(self, relationunits):
19184 '''
19185 relationunits : typing.Sequence[~RelationUnit]
19186 Returns -> typing.Sequence[~ErrorResult]
19187 '''
19188 # map input types to rpc msg
19189 params = dict()
19190 msg = dict(Type='Uniter', Request='EnterScope', Version=4, Params=params)
19191 params['RelationUnits'] = relationunits
19192 reply = await self.rpc(msg)
19193 return reply
19194
19195
19196
19197 @ReturnMapping(ErrorResults)
19198 async def FinishActions(self, results):
19199 '''
19200 results : typing.Sequence[~ActionExecutionResult]
19201 Returns -> typing.Sequence[~ErrorResult]
19202 '''
19203 # map input types to rpc msg
19204 params = dict()
19205 msg = dict(Type='Uniter', Request='FinishActions', Version=4, Params=params)
19206 params['results'] = results
19207 reply = await self.rpc(msg)
19208 return reply
19209
19210
19211
19212 @ReturnMapping(MeterStatusResults)
19213 async def GetMeterStatus(self, entities):
19214 '''
19215 entities : typing.Sequence[~Entity]
19216 Returns -> typing.Sequence[~MeterStatusResult]
19217 '''
19218 # map input types to rpc msg
19219 params = dict()
19220 msg = dict(Type='Uniter', Request='GetMeterStatus', Version=4, Params=params)
19221 params['Entities'] = entities
19222 reply = await self.rpc(msg)
19223 return reply
19224
19225
19226
19227 @ReturnMapping(StringBoolResults)
19228 async def GetPrincipal(self, entities):
19229 '''
19230 entities : typing.Sequence[~Entity]
19231 Returns -> typing.Sequence[~StringBoolResult]
19232 '''
19233 # map input types to rpc msg
19234 params = dict()
19235 msg = dict(Type='Uniter', Request='GetPrincipal', Version=4, Params=params)
19236 params['Entities'] = entities
19237 reply = await self.rpc(msg)
19238 return reply
19239
19240
19241
19242 @ReturnMapping(BoolResults)
19243 async def HasSubordinates(self, entities):
19244 '''
19245 entities : typing.Sequence[~Entity]
19246 Returns -> typing.Sequence[~BoolResult]
19247 '''
19248 # map input types to rpc msg
19249 params = dict()
19250 msg = dict(Type='Uniter', Request='HasSubordinates', Version=4, Params=params)
19251 params['Entities'] = entities
19252 reply = await self.rpc(msg)
19253 return reply
19254
19255
19256
19257 @ReturnMapping(StringsResults)
19258 async def JoinedRelations(self, entities):
19259 '''
19260 entities : typing.Sequence[~Entity]
19261 Returns -> typing.Sequence[~StringsResult]
19262 '''
19263 # map input types to rpc msg
19264 params = dict()
19265 msg = dict(Type='Uniter', Request='JoinedRelations', Version=4, Params=params)
19266 params['Entities'] = entities
19267 reply = await self.rpc(msg)
19268 return reply
19269
19270
19271
19272 @ReturnMapping(ErrorResults)
19273 async def LeaveScope(self, relationunits):
19274 '''
19275 relationunits : typing.Sequence[~RelationUnit]
19276 Returns -> typing.Sequence[~ErrorResult]
19277 '''
19278 # map input types to rpc msg
19279 params = dict()
19280 msg = dict(Type='Uniter', Request='LeaveScope', Version=4, Params=params)
19281 params['RelationUnits'] = relationunits
19282 reply = await self.rpc(msg)
19283 return reply
19284
19285
19286
19287 @ReturnMapping(LifeResults)
19288 async def Life(self, entities):
19289 '''
19290 entities : typing.Sequence[~Entity]
19291 Returns -> typing.Sequence[~LifeResult]
19292 '''
19293 # map input types to rpc msg
19294 params = dict()
19295 msg = dict(Type='Uniter', Request='Life', Version=4, Params=params)
19296 params['Entities'] = entities
19297 reply = await self.rpc(msg)
19298 return reply
19299
19300
19301
19302 @ReturnMapping(ErrorResults)
19303 async def Merge(self, params):
19304 '''
19305 params : typing.Sequence[~MergeLeadershipSettingsParam]
19306 Returns -> typing.Sequence[~ErrorResult]
19307 '''
19308 # map input types to rpc msg
19309 params = dict()
19310 msg = dict(Type='Uniter', Request='Merge', Version=4, Params=params)
19311 params['Params'] = params
19312 reply = await self.rpc(msg)
19313 return reply
19314
19315
19316
19317 @ReturnMapping(ModelConfigResult)
19318 async def ModelConfig(self):
19319 '''
19320
19321 Returns -> typing.Mapping[str, typing.Any]
19322 '''
19323 # map input types to rpc msg
19324 params = dict()
19325 msg = dict(Type='Uniter', Request='ModelConfig', Version=4, Params=params)
19326
19327 reply = await self.rpc(msg)
19328 return reply
19329
19330
19331
19332 @ReturnMapping(StringResult)
19333 async def ModelUUID(self):
19334 '''
19335
19336 Returns -> typing.Union[_ForwardRef('Error'), str]
19337 '''
19338 # map input types to rpc msg
19339 params = dict()
19340 msg = dict(Type='Uniter', Request='ModelUUID', Version=4, Params=params)
19341
19342 reply = await self.rpc(msg)
19343 return reply
19344
19345
19346
19347 @ReturnMapping(UnitNetworkConfigResults)
19348 async def NetworkConfig(self, args):
19349 '''
19350 args : typing.Sequence[~UnitNetworkConfig]
19351 Returns -> typing.Sequence[~UnitNetworkConfigResult]
19352 '''
19353 # map input types to rpc msg
19354 params = dict()
19355 msg = dict(Type='Uniter', Request='NetworkConfig', Version=4, Params=params)
19356 params['Args'] = args
19357 reply = await self.rpc(msg)
19358 return reply
19359
19360
19361
19362 @ReturnMapping(ErrorResults)
19363 async def OpenPorts(self, entities):
19364 '''
19365 entities : typing.Sequence[~EntityPortRange]
19366 Returns -> typing.Sequence[~ErrorResult]
19367 '''
19368 # map input types to rpc msg
19369 params = dict()
19370 msg = dict(Type='Uniter', Request='OpenPorts', Version=4, Params=params)
19371 params['Entities'] = entities
19372 reply = await self.rpc(msg)
19373 return reply
19374
19375
19376
19377 @ReturnMapping(StringResults)
19378 async def PrivateAddress(self, entities):
19379 '''
19380 entities : typing.Sequence[~Entity]
19381 Returns -> typing.Sequence[~StringResult]
19382 '''
19383 # map input types to rpc msg
19384 params = dict()
19385 msg = dict(Type='Uniter', Request='PrivateAddress', Version=4, Params=params)
19386 params['Entities'] = entities
19387 reply = await self.rpc(msg)
19388 return reply
19389
19390
19391
19392 @ReturnMapping(StringResult)
19393 async def ProviderType(self):
19394 '''
19395
19396 Returns -> typing.Union[_ForwardRef('Error'), str]
19397 '''
19398 # map input types to rpc msg
19399 params = dict()
19400 msg = dict(Type='Uniter', Request='ProviderType', Version=4, Params=params)
19401
19402 reply = await self.rpc(msg)
19403 return reply
19404
19405
19406
19407 @ReturnMapping(StringResults)
19408 async def PublicAddress(self, entities):
19409 '''
19410 entities : typing.Sequence[~Entity]
19411 Returns -> typing.Sequence[~StringResult]
19412 '''
19413 # map input types to rpc msg
19414 params = dict()
19415 msg = dict(Type='Uniter', Request='PublicAddress', Version=4, Params=params)
19416 params['Entities'] = entities
19417 reply = await self.rpc(msg)
19418 return reply
19419
19420
19421
19422 @ReturnMapping(GetLeadershipSettingsBulkResults)
19423 async def Read(self, entities):
19424 '''
19425 entities : typing.Sequence[~Entity]
19426 Returns -> typing.Sequence[~GetLeadershipSettingsResult]
19427 '''
19428 # map input types to rpc msg
19429 params = dict()
19430 msg = dict(Type='Uniter', Request='Read', Version=4, Params=params)
19431 params['Entities'] = entities
19432 reply = await self.rpc(msg)
19433 return reply
19434
19435
19436
19437 @ReturnMapping(SettingsResults)
19438 async def ReadRemoteSettings(self, relationunitpairs):
19439 '''
19440 relationunitpairs : typing.Sequence[~RelationUnitPair]
19441 Returns -> typing.Sequence[~SettingsResult]
19442 '''
19443 # map input types to rpc msg
19444 params = dict()
19445 msg = dict(Type='Uniter', Request='ReadRemoteSettings', Version=4, Params=params)
19446 params['RelationUnitPairs'] = relationunitpairs
19447 reply = await self.rpc(msg)
19448 return reply
19449
19450
19451
19452 @ReturnMapping(SettingsResults)
19453 async def ReadSettings(self, relationunits):
19454 '''
19455 relationunits : typing.Sequence[~RelationUnit]
19456 Returns -> typing.Sequence[~SettingsResult]
19457 '''
19458 # map input types to rpc msg
19459 params = dict()
19460 msg = dict(Type='Uniter', Request='ReadSettings', Version=4, Params=params)
19461 params['RelationUnits'] = relationunits
19462 reply = await self.rpc(msg)
19463 return reply
19464
19465
19466
19467 @ReturnMapping(RelationResults)
19468 async def Relation(self, relationunits):
19469 '''
19470 relationunits : typing.Sequence[~RelationUnit]
19471 Returns -> typing.Sequence[~RelationResult]
19472 '''
19473 # map input types to rpc msg
19474 params = dict()
19475 msg = dict(Type='Uniter', Request='Relation', Version=4, Params=params)
19476 params['RelationUnits'] = relationunits
19477 reply = await self.rpc(msg)
19478 return reply
19479
19480
19481
19482 @ReturnMapping(RelationResults)
19483 async def RelationById(self, relationids):
19484 '''
19485 relationids : typing.Sequence[int]
19486 Returns -> typing.Sequence[~RelationResult]
19487 '''
19488 # map input types to rpc msg
19489 params = dict()
19490 msg = dict(Type='Uniter', Request='RelationById', Version=4, Params=params)
19491 params['RelationIds'] = relationids
19492 reply = await self.rpc(msg)
19493 return reply
19494
19495
19496
19497 @ReturnMapping(ErrorResults)
19498 async def RemoveStorageAttachments(self, ids):
19499 '''
19500 ids : typing.Sequence[~StorageAttachmentId]
19501 Returns -> typing.Sequence[~ErrorResult]
19502 '''
19503 # map input types to rpc msg
19504 params = dict()
19505 msg = dict(Type='Uniter', Request='RemoveStorageAttachments', Version=4, Params=params)
19506 params['ids'] = ids
19507 reply = await self.rpc(msg)
19508 return reply
19509
19510
19511
19512 @ReturnMapping(ErrorResults)
19513 async def RequestReboot(self, entities):
19514 '''
19515 entities : typing.Sequence[~Entity]
19516 Returns -> typing.Sequence[~ErrorResult]
19517 '''
19518 # map input types to rpc msg
19519 params = dict()
19520 msg = dict(Type='Uniter', Request='RequestReboot', Version=4, Params=params)
19521 params['Entities'] = entities
19522 reply = await self.rpc(msg)
19523 return reply
19524
19525
19526
19527 @ReturnMapping(ResolvedModeResults)
19528 async def Resolved(self, entities):
19529 '''
19530 entities : typing.Sequence[~Entity]
19531 Returns -> typing.Sequence[~ResolvedModeResult]
19532 '''
19533 # map input types to rpc msg
19534 params = dict()
19535 msg = dict(Type='Uniter', Request='Resolved', Version=4, Params=params)
19536 params['Entities'] = entities
19537 reply = await self.rpc(msg)
19538 return reply
19539
19540
19541
19542 @ReturnMapping(ErrorResults)
19543 async def SetAgentStatus(self, entities):
19544 '''
19545 entities : typing.Sequence[~EntityStatusArgs]
19546 Returns -> typing.Sequence[~ErrorResult]
19547 '''
19548 # map input types to rpc msg
19549 params = dict()
19550 msg = dict(Type='Uniter', Request='SetAgentStatus', Version=4, Params=params)
19551 params['Entities'] = entities
19552 reply = await self.rpc(msg)
19553 return reply
19554
19555
19556
19557 @ReturnMapping(ErrorResults)
19558 async def SetApplicationStatus(self, entities):
19559 '''
19560 entities : typing.Sequence[~EntityStatusArgs]
19561 Returns -> typing.Sequence[~ErrorResult]
19562 '''
19563 # map input types to rpc msg
19564 params = dict()
19565 msg = dict(Type='Uniter', Request='SetApplicationStatus', Version=4, Params=params)
19566 params['Entities'] = entities
19567 reply = await self.rpc(msg)
19568 return reply
19569
19570
19571
19572 @ReturnMapping(ErrorResults)
19573 async def SetCharmURL(self, entities):
19574 '''
19575 entities : typing.Sequence[~EntityCharmURL]
19576 Returns -> typing.Sequence[~ErrorResult]
19577 '''
19578 # map input types to rpc msg
19579 params = dict()
19580 msg = dict(Type='Uniter', Request='SetCharmURL', Version=4, Params=params)
19581 params['Entities'] = entities
19582 reply = await self.rpc(msg)
19583 return reply
19584
19585
19586
19587 @ReturnMapping(ErrorResults)
19588 async def SetStatus(self, entities):
19589 '''
19590 entities : typing.Sequence[~EntityStatusArgs]
19591 Returns -> typing.Sequence[~ErrorResult]
19592 '''
19593 # map input types to rpc msg
19594 params = dict()
19595 msg = dict(Type='Uniter', Request='SetStatus', Version=4, Params=params)
19596 params['Entities'] = entities
19597 reply = await self.rpc(msg)
19598 return reply
19599
19600
19601
19602 @ReturnMapping(ErrorResults)
19603 async def SetUnitStatus(self, entities):
19604 '''
19605 entities : typing.Sequence[~EntityStatusArgs]
19606 Returns -> typing.Sequence[~ErrorResult]
19607 '''
19608 # map input types to rpc msg
19609 params = dict()
19610 msg = dict(Type='Uniter', Request='SetUnitStatus', Version=4, Params=params)
19611 params['Entities'] = entities
19612 reply = await self.rpc(msg)
19613 return reply
19614
19615
19616
19617 @ReturnMapping(LifeResults)
19618 async def StorageAttachmentLife(self, ids):
19619 '''
19620 ids : typing.Sequence[~StorageAttachmentId]
19621 Returns -> typing.Sequence[~LifeResult]
19622 '''
19623 # map input types to rpc msg
19624 params = dict()
19625 msg = dict(Type='Uniter', Request='StorageAttachmentLife', Version=4, Params=params)
19626 params['ids'] = ids
19627 reply = await self.rpc(msg)
19628 return reply
19629
19630
19631
19632 @ReturnMapping(StorageAttachmentResults)
19633 async def StorageAttachments(self, ids):
19634 '''
19635 ids : typing.Sequence[~StorageAttachmentId]
19636 Returns -> typing.Sequence[~StorageAttachmentResult]
19637 '''
19638 # map input types to rpc msg
19639 params = dict()
19640 msg = dict(Type='Uniter', Request='StorageAttachments', Version=4, Params=params)
19641 params['ids'] = ids
19642 reply = await self.rpc(msg)
19643 return reply
19644
19645
19646
19647 @ReturnMapping(StatusResults)
19648 async def UnitStatus(self, entities):
19649 '''
19650 entities : typing.Sequence[~Entity]
19651 Returns -> typing.Sequence[~StatusResult]
19652 '''
19653 # map input types to rpc msg
19654 params = dict()
19655 msg = dict(Type='Uniter', Request='UnitStatus', Version=4, Params=params)
19656 params['Entities'] = entities
19657 reply = await self.rpc(msg)
19658 return reply
19659
19660
19661
19662 @ReturnMapping(StorageAttachmentIdsResults)
19663 async def UnitStorageAttachments(self, entities):
19664 '''
19665 entities : typing.Sequence[~Entity]
19666 Returns -> typing.Sequence[~StorageAttachmentIdsResult]
19667 '''
19668 # map input types to rpc msg
19669 params = dict()
19670 msg = dict(Type='Uniter', Request='UnitStorageAttachments', Version=4, Params=params)
19671 params['Entities'] = entities
19672 reply = await self.rpc(msg)
19673 return reply
19674
19675
19676
19677 @ReturnMapping(ErrorResults)
19678 async def UpdateSettings(self, relationunits):
19679 '''
19680 relationunits : typing.Sequence[~RelationUnitSettings]
19681 Returns -> typing.Sequence[~ErrorResult]
19682 '''
19683 # map input types to rpc msg
19684 params = dict()
19685 msg = dict(Type='Uniter', Request='UpdateSettings', Version=4, Params=params)
19686 params['RelationUnits'] = relationunits
19687 reply = await self.rpc(msg)
19688 return reply
19689
19690
19691
19692 @ReturnMapping(NotifyWatchResults)
19693 async def Watch(self, entities):
19694 '''
19695 entities : typing.Sequence[~Entity]
19696 Returns -> typing.Sequence[~NotifyWatchResult]
19697 '''
19698 # map input types to rpc msg
19699 params = dict()
19700 msg = dict(Type='Uniter', Request='Watch', Version=4, Params=params)
19701 params['Entities'] = entities
19702 reply = await self.rpc(msg)
19703 return reply
19704
19705
19706
19707 @ReturnMapping(NotifyWatchResult)
19708 async def WatchAPIHostPorts(self):
19709 '''
19710
19711 Returns -> typing.Union[_ForwardRef('Error'), str]
19712 '''
19713 # map input types to rpc msg
19714 params = dict()
19715 msg = dict(Type='Uniter', Request='WatchAPIHostPorts', Version=4, Params=params)
19716
19717 reply = await self.rpc(msg)
19718 return reply
19719
19720
19721
19722 @ReturnMapping(StringsWatchResults)
19723 async def WatchActionNotifications(self, entities):
19724 '''
19725 entities : typing.Sequence[~Entity]
19726 Returns -> typing.Sequence[~StringsWatchResult]
19727 '''
19728 # map input types to rpc msg
19729 params = dict()
19730 msg = dict(Type='Uniter', Request='WatchActionNotifications', Version=4, Params=params)
19731 params['Entities'] = entities
19732 reply = await self.rpc(msg)
19733 return reply
19734
19735
19736
19737 @ReturnMapping(StringsWatchResults)
19738 async def WatchApplicationRelations(self, entities):
19739 '''
19740 entities : typing.Sequence[~Entity]
19741 Returns -> typing.Sequence[~StringsWatchResult]
19742 '''
19743 # map input types to rpc msg
19744 params = dict()
19745 msg = dict(Type='Uniter', Request='WatchApplicationRelations', Version=4, Params=params)
19746 params['Entities'] = entities
19747 reply = await self.rpc(msg)
19748 return reply
19749
19750
19751
19752 @ReturnMapping(NotifyWatchResults)
19753 async def WatchConfigSettings(self, entities):
19754 '''
19755 entities : typing.Sequence[~Entity]
19756 Returns -> typing.Sequence[~NotifyWatchResult]
19757 '''
19758 # map input types to rpc msg
19759 params = dict()
19760 msg = dict(Type='Uniter', Request='WatchConfigSettings', Version=4, Params=params)
19761 params['Entities'] = entities
19762 reply = await self.rpc(msg)
19763 return reply
19764
19765
19766
19767 @ReturnMapping(NotifyWatchResult)
19768 async def WatchForModelConfigChanges(self):
19769 '''
19770
19771 Returns -> typing.Union[_ForwardRef('Error'), str]
19772 '''
19773 # map input types to rpc msg
19774 params = dict()
19775 msg = dict(Type='Uniter', Request='WatchForModelConfigChanges', Version=4, Params=params)
19776
19777 reply = await self.rpc(msg)
19778 return reply
19779
19780
19781
19782 @ReturnMapping(NotifyWatchResults)
19783 async def WatchLeadershipSettings(self, entities):
19784 '''
19785 entities : typing.Sequence[~Entity]
19786 Returns -> typing.Sequence[~NotifyWatchResult]
19787 '''
19788 # map input types to rpc msg
19789 params = dict()
19790 msg = dict(Type='Uniter', Request='WatchLeadershipSettings', Version=4, Params=params)
19791 params['Entities'] = entities
19792 reply = await self.rpc(msg)
19793 return reply
19794
19795
19796
19797 @ReturnMapping(NotifyWatchResults)
19798 async def WatchMeterStatus(self, entities):
19799 '''
19800 entities : typing.Sequence[~Entity]
19801 Returns -> typing.Sequence[~NotifyWatchResult]
19802 '''
19803 # map input types to rpc msg
19804 params = dict()
19805 msg = dict(Type='Uniter', Request='WatchMeterStatus', Version=4, Params=params)
19806 params['Entities'] = entities
19807 reply = await self.rpc(msg)
19808 return reply
19809
19810
19811
19812 @ReturnMapping(RelationUnitsWatchResults)
19813 async def WatchRelationUnits(self, relationunits):
19814 '''
19815 relationunits : typing.Sequence[~RelationUnit]
19816 Returns -> typing.Sequence[~RelationUnitsWatchResult]
19817 '''
19818 # map input types to rpc msg
19819 params = dict()
19820 msg = dict(Type='Uniter', Request='WatchRelationUnits', Version=4, Params=params)
19821 params['RelationUnits'] = relationunits
19822 reply = await self.rpc(msg)
19823 return reply
19824
19825
19826
19827 @ReturnMapping(NotifyWatchResults)
19828 async def WatchStorageAttachments(self, ids):
19829 '''
19830 ids : typing.Sequence[~StorageAttachmentId]
19831 Returns -> typing.Sequence[~NotifyWatchResult]
19832 '''
19833 # map input types to rpc msg
19834 params = dict()
19835 msg = dict(Type='Uniter', Request='WatchStorageAttachments', Version=4, Params=params)
19836 params['ids'] = ids
19837 reply = await self.rpc(msg)
19838 return reply
19839
19840
19841
19842 @ReturnMapping(NotifyWatchResults)
19843 async def WatchUnitAddresses(self, entities):
19844 '''
19845 entities : typing.Sequence[~Entity]
19846 Returns -> typing.Sequence[~NotifyWatchResult]
19847 '''
19848 # map input types to rpc msg
19849 params = dict()
19850 msg = dict(Type='Uniter', Request='WatchUnitAddresses', Version=4, Params=params)
19851 params['Entities'] = entities
19852 reply = await self.rpc(msg)
19853 return reply
19854
19855
19856
19857 @ReturnMapping(StringsWatchResults)
19858 async def WatchUnitStorageAttachments(self, entities):
19859 '''
19860 entities : typing.Sequence[~Entity]
19861 Returns -> typing.Sequence[~StringsWatchResult]
19862 '''
19863 # map input types to rpc msg
19864 params = dict()
19865 msg = dict(Type='Uniter', Request='WatchUnitStorageAttachments', Version=4, Params=params)
19866 params['Entities'] = entities
19867 reply = await self.rpc(msg)
19868 return reply
19869
19870
19871 class UpgraderFacade(Type):
19872 name = 'Upgrader'
19873 version = 1
19874 schema = {'definitions': {'Binary': {'additionalProperties': False,
19875 'properties': {'Arch': {'type': 'string'},
19876 'Number': {'$ref': '#/definitions/Number'},
19877 'Series': {'type': 'string'}},
19878 'required': ['Number', 'Series', 'Arch'],
19879 'type': 'object'},
19880 'Entities': {'additionalProperties': False,
19881 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
19882 'type': 'array'}},
19883 'required': ['Entities'],
19884 'type': 'object'},
19885 'EntitiesVersion': {'additionalProperties': False,
19886 'properties': {'AgentTools': {'items': {'$ref': '#/definitions/EntityVersion'},
19887 'type': 'array'}},
19888 'required': ['AgentTools'],
19889 'type': 'object'},
19890 'Entity': {'additionalProperties': False,
19891 'properties': {'Tag': {'type': 'string'}},
19892 'required': ['Tag'],
19893 'type': 'object'},
19894 'EntityVersion': {'additionalProperties': False,
19895 'properties': {'Tag': {'type': 'string'},
19896 'Tools': {'$ref': '#/definitions/Version'}},
19897 'required': ['Tag', 'Tools'],
19898 'type': 'object'},
19899 'Error': {'additionalProperties': False,
19900 'properties': {'Code': {'type': 'string'},
19901 'Info': {'$ref': '#/definitions/ErrorInfo'},
19902 'Message': {'type': 'string'}},
19903 'required': ['Message', 'Code'],
19904 'type': 'object'},
19905 'ErrorInfo': {'additionalProperties': False,
19906 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
19907 'MacaroonPath': {'type': 'string'}},
19908 'type': 'object'},
19909 'ErrorResult': {'additionalProperties': False,
19910 'properties': {'Error': {'$ref': '#/definitions/Error'}},
19911 'required': ['Error'],
19912 'type': 'object'},
19913 'ErrorResults': {'additionalProperties': False,
19914 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
19915 'type': 'array'}},
19916 'required': ['Results'],
19917 'type': 'object'},
19918 'Macaroon': {'additionalProperties': False,
19919 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
19920 'type': 'array'},
19921 'data': {'items': {'type': 'integer'},
19922 'type': 'array'},
19923 'id': {'$ref': '#/definitions/packet'},
19924 'location': {'$ref': '#/definitions/packet'},
19925 'sig': {'items': {'type': 'integer'},
19926 'type': 'array'}},
19927 'required': ['data',
19928 'location',
19929 'id',
19930 'caveats',
19931 'sig'],
19932 'type': 'object'},
19933 'NotifyWatchResult': {'additionalProperties': False,
19934 'properties': {'Error': {'$ref': '#/definitions/Error'},
19935 'NotifyWatcherId': {'type': 'string'}},
19936 'required': ['NotifyWatcherId', 'Error'],
19937 'type': 'object'},
19938 'NotifyWatchResults': {'additionalProperties': False,
19939 'properties': {'Results': {'items': {'$ref': '#/definitions/NotifyWatchResult'},
19940 'type': 'array'}},
19941 'required': ['Results'],
19942 'type': 'object'},
19943 'Number': {'additionalProperties': False,
19944 'properties': {'Build': {'type': 'integer'},
19945 'Major': {'type': 'integer'},
19946 'Minor': {'type': 'integer'},
19947 'Patch': {'type': 'integer'},
19948 'Tag': {'type': 'string'}},
19949 'required': ['Major',
19950 'Minor',
19951 'Tag',
19952 'Patch',
19953 'Build'],
19954 'type': 'object'},
19955 'Tools': {'additionalProperties': False,
19956 'properties': {'sha256': {'type': 'string'},
19957 'size': {'type': 'integer'},
19958 'url': {'type': 'string'},
19959 'version': {'$ref': '#/definitions/Binary'}},
19960 'required': ['version', 'url', 'size'],
19961 'type': 'object'},
19962 'ToolsResult': {'additionalProperties': False,
19963 'properties': {'DisableSSLHostnameVerification': {'type': 'boolean'},
19964 'Error': {'$ref': '#/definitions/Error'},
19965 'ToolsList': {'items': {'$ref': '#/definitions/Tools'},
19966 'type': 'array'}},
19967 'required': ['ToolsList',
19968 'DisableSSLHostnameVerification',
19969 'Error'],
19970 'type': 'object'},
19971 'ToolsResults': {'additionalProperties': False,
19972 'properties': {'Results': {'items': {'$ref': '#/definitions/ToolsResult'},
19973 'type': 'array'}},
19974 'required': ['Results'],
19975 'type': 'object'},
19976 'Version': {'additionalProperties': False,
19977 'properties': {'Version': {'$ref': '#/definitions/Binary'}},
19978 'required': ['Version'],
19979 'type': 'object'},
19980 'VersionResult': {'additionalProperties': False,
19981 'properties': {'Error': {'$ref': '#/definitions/Error'},
19982 'Version': {'$ref': '#/definitions/Number'}},
19983 'required': ['Version', 'Error'],
19984 'type': 'object'},
19985 'VersionResults': {'additionalProperties': False,
19986 'properties': {'Results': {'items': {'$ref': '#/definitions/VersionResult'},
19987 'type': 'array'}},
19988 'required': ['Results'],
19989 'type': 'object'},
19990 'caveat': {'additionalProperties': False,
19991 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
19992 'location': {'$ref': '#/definitions/packet'},
19993 'verificationId': {'$ref': '#/definitions/packet'}},
19994 'required': ['location',
19995 'caveatId',
19996 'verificationId'],
19997 'type': 'object'},
19998 'packet': {'additionalProperties': False,
19999 'properties': {'headerLen': {'type': 'integer'},
20000 'start': {'type': 'integer'},
20001 'totalLen': {'type': 'integer'}},
20002 'required': ['start', 'totalLen', 'headerLen'],
20003 'type': 'object'}},
20004 'properties': {'DesiredVersion': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
20005 'Result': {'$ref': '#/definitions/VersionResults'}},
20006 'type': 'object'},
20007 'SetTools': {'properties': {'Params': {'$ref': '#/definitions/EntitiesVersion'},
20008 'Result': {'$ref': '#/definitions/ErrorResults'}},
20009 'type': 'object'},
20010 'Tools': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
20011 'Result': {'$ref': '#/definitions/ToolsResults'}},
20012 'type': 'object'},
20013 'WatchAPIVersion': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
20014 'Result': {'$ref': '#/definitions/NotifyWatchResults'}},
20015 'type': 'object'}},
20016 'type': 'object'}
20017
20018
20019 @ReturnMapping(VersionResults)
20020 async def DesiredVersion(self, entities):
20021 '''
20022 entities : typing.Sequence[~Entity]
20023 Returns -> typing.Sequence[~VersionResult]
20024 '''
20025 # map input types to rpc msg
20026 params = dict()
20027 msg = dict(Type='Upgrader', Request='DesiredVersion', Version=1, Params=params)
20028 params['Entities'] = entities
20029 reply = await self.rpc(msg)
20030 return reply
20031
20032
20033
20034 @ReturnMapping(ErrorResults)
20035 async def SetTools(self, agenttools):
20036 '''
20037 agenttools : typing.Sequence[~EntityVersion]
20038 Returns -> typing.Sequence[~ErrorResult]
20039 '''
20040 # map input types to rpc msg
20041 params = dict()
20042 msg = dict(Type='Upgrader', Request='SetTools', Version=1, Params=params)
20043 params['AgentTools'] = agenttools
20044 reply = await self.rpc(msg)
20045 return reply
20046
20047
20048
20049 @ReturnMapping(ToolsResults)
20050 async def Tools(self, entities):
20051 '''
20052 entities : typing.Sequence[~Entity]
20053 Returns -> typing.Sequence[~ToolsResult]
20054 '''
20055 # map input types to rpc msg
20056 params = dict()
20057 msg = dict(Type='Upgrader', Request='Tools', Version=1, Params=params)
20058 params['Entities'] = entities
20059 reply = await self.rpc(msg)
20060 return reply
20061
20062
20063
20064 @ReturnMapping(NotifyWatchResults)
20065 async def WatchAPIVersion(self, entities):
20066 '''
20067 entities : typing.Sequence[~Entity]
20068 Returns -> typing.Sequence[~NotifyWatchResult]
20069 '''
20070 # map input types to rpc msg
20071 params = dict()
20072 msg = dict(Type='Upgrader', Request='WatchAPIVersion', Version=1, Params=params)
20073 params['Entities'] = entities
20074 reply = await self.rpc(msg)
20075 return reply
20076
20077
20078 class UserManagerFacade(Type):
20079 name = 'UserManager'
20080 version = 1
20081 schema = {'definitions': {'AddUser': {'additionalProperties': False,
20082 'properties': {'display-name': {'type': 'string'},
20083 'model-access-permission': {'type': 'string'},
20084 'password': {'type': 'string'},
20085 'shared-model-tags': {'items': {'type': 'string'},
20086 'type': 'array'},
20087 'username': {'type': 'string'}},
20088 'required': ['username',
20089 'display-name',
20090 'shared-model-tags'],
20091 'type': 'object'},
20092 'AddUserResult': {'additionalProperties': False,
20093 'properties': {'error': {'$ref': '#/definitions/Error'},
20094 'secret-key': {'items': {'type': 'integer'},
20095 'type': 'array'},
20096 'tag': {'type': 'string'}},
20097 'type': 'object'},
20098 'AddUserResults': {'additionalProperties': False,
20099 'properties': {'results': {'items': {'$ref': '#/definitions/AddUserResult'},
20100 'type': 'array'}},
20101 'required': ['results'],
20102 'type': 'object'},
20103 'AddUsers': {'additionalProperties': False,
20104 'properties': {'users': {'items': {'$ref': '#/definitions/AddUser'},
20105 'type': 'array'}},
20106 'required': ['users'],
20107 'type': 'object'},
20108 'Entities': {'additionalProperties': False,
20109 'properties': {'Entities': {'items': {'$ref': '#/definitions/Entity'},
20110 'type': 'array'}},
20111 'required': ['Entities'],
20112 'type': 'object'},
20113 'Entity': {'additionalProperties': False,
20114 'properties': {'Tag': {'type': 'string'}},
20115 'required': ['Tag'],
20116 'type': 'object'},
20117 'EntityPassword': {'additionalProperties': False,
20118 'properties': {'Password': {'type': 'string'},
20119 'Tag': {'type': 'string'}},
20120 'required': ['Tag', 'Password'],
20121 'type': 'object'},
20122 'EntityPasswords': {'additionalProperties': False,
20123 'properties': {'Changes': {'items': {'$ref': '#/definitions/EntityPassword'},
20124 'type': 'array'}},
20125 'required': ['Changes'],
20126 'type': 'object'},
20127 'Error': {'additionalProperties': False,
20128 'properties': {'Code': {'type': 'string'},
20129 'Info': {'$ref': '#/definitions/ErrorInfo'},
20130 'Message': {'type': 'string'}},
20131 'required': ['Message', 'Code'],
20132 'type': 'object'},
20133 'ErrorInfo': {'additionalProperties': False,
20134 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
20135 'MacaroonPath': {'type': 'string'}},
20136 'type': 'object'},
20137 'ErrorResult': {'additionalProperties': False,
20138 'properties': {'Error': {'$ref': '#/definitions/Error'}},
20139 'required': ['Error'],
20140 'type': 'object'},
20141 'ErrorResults': {'additionalProperties': False,
20142 'properties': {'Results': {'items': {'$ref': '#/definitions/ErrorResult'},
20143 'type': 'array'}},
20144 'required': ['Results'],
20145 'type': 'object'},
20146 'Macaroon': {'additionalProperties': False,
20147 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
20148 'type': 'array'},
20149 'data': {'items': {'type': 'integer'},
20150 'type': 'array'},
20151 'id': {'$ref': '#/definitions/packet'},
20152 'location': {'$ref': '#/definitions/packet'},
20153 'sig': {'items': {'type': 'integer'},
20154 'type': 'array'}},
20155 'required': ['data',
20156 'location',
20157 'id',
20158 'caveats',
20159 'sig'],
20160 'type': 'object'},
20161 'MacaroonResult': {'additionalProperties': False,
20162 'properties': {'error': {'$ref': '#/definitions/Error'},
20163 'result': {'$ref': '#/definitions/Macaroon'}},
20164 'type': 'object'},
20165 'MacaroonResults': {'additionalProperties': False,
20166 'properties': {'results': {'items': {'$ref': '#/definitions/MacaroonResult'},
20167 'type': 'array'}},
20168 'required': ['results'],
20169 'type': 'object'},
20170 'UserInfo': {'additionalProperties': False,
20171 'properties': {'created-by': {'type': 'string'},
20172 'date-created': {'format': 'date-time',
20173 'type': 'string'},
20174 'disabled': {'type': 'boolean'},
20175 'display-name': {'type': 'string'},
20176 'last-connection': {'format': 'date-time',
20177 'type': 'string'},
20178 'username': {'type': 'string'}},
20179 'required': ['username',
20180 'display-name',
20181 'created-by',
20182 'date-created',
20183 'disabled'],
20184 'type': 'object'},
20185 'UserInfoRequest': {'additionalProperties': False,
20186 'properties': {'entities': {'items': {'$ref': '#/definitions/Entity'},
20187 'type': 'array'},
20188 'include-disabled': {'type': 'boolean'}},
20189 'required': ['entities',
20190 'include-disabled'],
20191 'type': 'object'},
20192 'UserInfoResult': {'additionalProperties': False,
20193 'properties': {'error': {'$ref': '#/definitions/Error'},
20194 'result': {'$ref': '#/definitions/UserInfo'}},
20195 'type': 'object'},
20196 'UserInfoResults': {'additionalProperties': False,
20197 'properties': {'results': {'items': {'$ref': '#/definitions/UserInfoResult'},
20198 'type': 'array'}},
20199 'required': ['results'],
20200 'type': 'object'},
20201 'caveat': {'additionalProperties': False,
20202 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
20203 'location': {'$ref': '#/definitions/packet'},
20204 'verificationId': {'$ref': '#/definitions/packet'}},
20205 'required': ['location',
20206 'caveatId',
20207 'verificationId'],
20208 'type': 'object'},
20209 'packet': {'additionalProperties': False,
20210 'properties': {'headerLen': {'type': 'integer'},
20211 'start': {'type': 'integer'},
20212 'totalLen': {'type': 'integer'}},
20213 'required': ['start', 'totalLen', 'headerLen'],
20214 'type': 'object'}},
20215 'properties': {'AddUser': {'properties': {'Params': {'$ref': '#/definitions/AddUsers'},
20216 'Result': {'$ref': '#/definitions/AddUserResults'}},
20217 'type': 'object'},
20218 'CreateLocalLoginMacaroon': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
20219 'Result': {'$ref': '#/definitions/MacaroonResults'}},
20220 'type': 'object'},
20221 'DisableUser': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
20222 'Result': {'$ref': '#/definitions/ErrorResults'}},
20223 'type': 'object'},
20224 'EnableUser': {'properties': {'Params': {'$ref': '#/definitions/Entities'},
20225 'Result': {'$ref': '#/definitions/ErrorResults'}},
20226 'type': 'object'},
20227 'SetPassword': {'properties': {'Params': {'$ref': '#/definitions/EntityPasswords'},
20228 'Result': {'$ref': '#/definitions/ErrorResults'}},
20229 'type': 'object'},
20230 'UserInfo': {'properties': {'Params': {'$ref': '#/definitions/UserInfoRequest'},
20231 'Result': {'$ref': '#/definitions/UserInfoResults'}},
20232 'type': 'object'}},
20233 'type': 'object'}
20234
20235
20236 @ReturnMapping(AddUserResults)
20237 async def AddUser(self, users):
20238 '''
20239 users : typing.Sequence[~AddUser]
20240 Returns -> typing.Sequence[~AddUserResult]
20241 '''
20242 # map input types to rpc msg
20243 params = dict()
20244 msg = dict(Type='UserManager', Request='AddUser', Version=1, Params=params)
20245 params['users'] = users
20246 reply = await self.rpc(msg)
20247 return reply
20248
20249
20250
20251 @ReturnMapping(MacaroonResults)
20252 async def CreateLocalLoginMacaroon(self, entities):
20253 '''
20254 entities : typing.Sequence[~Entity]
20255 Returns -> typing.Sequence[~MacaroonResult]
20256 '''
20257 # map input types to rpc msg
20258 params = dict()
20259 msg = dict(Type='UserManager', Request='CreateLocalLoginMacaroon', Version=1, Params=params)
20260 params['Entities'] = entities
20261 reply = await self.rpc(msg)
20262 return reply
20263
20264
20265
20266 @ReturnMapping(ErrorResults)
20267 async def DisableUser(self, entities):
20268 '''
20269 entities : typing.Sequence[~Entity]
20270 Returns -> typing.Sequence[~ErrorResult]
20271 '''
20272 # map input types to rpc msg
20273 params = dict()
20274 msg = dict(Type='UserManager', Request='DisableUser', Version=1, Params=params)
20275 params['Entities'] = entities
20276 reply = await self.rpc(msg)
20277 return reply
20278
20279
20280
20281 @ReturnMapping(ErrorResults)
20282 async def EnableUser(self, entities):
20283 '''
20284 entities : typing.Sequence[~Entity]
20285 Returns -> typing.Sequence[~ErrorResult]
20286 '''
20287 # map input types to rpc msg
20288 params = dict()
20289 msg = dict(Type='UserManager', Request='EnableUser', Version=1, Params=params)
20290 params['Entities'] = entities
20291 reply = await self.rpc(msg)
20292 return reply
20293
20294
20295
20296 @ReturnMapping(ErrorResults)
20297 async def SetPassword(self, changes):
20298 '''
20299 changes : typing.Sequence[~EntityPassword]
20300 Returns -> typing.Sequence[~ErrorResult]
20301 '''
20302 # map input types to rpc msg
20303 params = dict()
20304 msg = dict(Type='UserManager', Request='SetPassword', Version=1, Params=params)
20305 params['Changes'] = changes
20306 reply = await self.rpc(msg)
20307 return reply
20308
20309
20310
20311 @ReturnMapping(UserInfoResults)
20312 async def UserInfo(self, entities, include_disabled):
20313 '''
20314 entities : typing.Sequence[~Entity]
20315 include_disabled : bool
20316 Returns -> typing.Sequence[~UserInfoResult]
20317 '''
20318 # map input types to rpc msg
20319 params = dict()
20320 msg = dict(Type='UserManager', Request='UserInfo', Version=1, Params=params)
20321 params['entities'] = entities
20322 params['include-disabled'] = include_disabled
20323 reply = await self.rpc(msg)
20324 return reply
20325
20326
20327 class VolumeAttachmentsWatcherFacade(Type):
20328 name = 'VolumeAttachmentsWatcher'
20329 version = 2
20330 schema = {'definitions': {'Error': {'additionalProperties': False,
20331 'properties': {'Code': {'type': 'string'},
20332 'Info': {'$ref': '#/definitions/ErrorInfo'},
20333 'Message': {'type': 'string'}},
20334 'required': ['Message', 'Code'],
20335 'type': 'object'},
20336 'ErrorInfo': {'additionalProperties': False,
20337 'properties': {'Macaroon': {'$ref': '#/definitions/Macaroon'},
20338 'MacaroonPath': {'type': 'string'}},
20339 'type': 'object'},
20340 'Macaroon': {'additionalProperties': False,
20341 'properties': {'caveats': {'items': {'$ref': '#/definitions/caveat'},
20342 'type': 'array'},
20343 'data': {'items': {'type': 'integer'},
20344 'type': 'array'},
20345 'id': {'$ref': '#/definitions/packet'},
20346 'location': {'$ref': '#/definitions/packet'},
20347 'sig': {'items': {'type': 'integer'},
20348 'type': 'array'}},
20349 'required': ['data',
20350 'location',
20351 'id',
20352 'caveats',
20353 'sig'],
20354 'type': 'object'},
20355 'MachineStorageId': {'additionalProperties': False,
20356 'properties': {'attachmenttag': {'type': 'string'},
20357 'machinetag': {'type': 'string'}},
20358 'required': ['machinetag',
20359 'attachmenttag'],
20360 'type': 'object'},
20361 'MachineStorageIdsWatchResult': {'additionalProperties': False,
20362 'properties': {'Changes': {'items': {'$ref': '#/definitions/MachineStorageId'},
20363 'type': 'array'},
20364 'Error': {'$ref': '#/definitions/Error'},
20365 'MachineStorageIdsWatcherId': {'type': 'string'}},
20366 'required': ['MachineStorageIdsWatcherId',
20367 'Changes',
20368 'Error'],
20369 'type': 'object'},
20370 'caveat': {'additionalProperties': False,
20371 'properties': {'caveatId': {'$ref': '#/definitions/packet'},
20372 'location': {'$ref': '#/definitions/packet'},
20373 'verificationId': {'$ref': '#/definitions/packet'}},
20374 'required': ['location',
20375 'caveatId',
20376 'verificationId'],
20377 'type': 'object'},
20378 'packet': {'additionalProperties': False,
20379 'properties': {'headerLen': {'type': 'integer'},
20380 'start': {'type': 'integer'},
20381 'totalLen': {'type': 'integer'}},
20382 'required': ['start', 'totalLen', 'headerLen'],
20383 'type': 'object'}},
20384 'properties': {'Next': {'properties': {'Result': {'$ref': '#/definitions/MachineStorageIdsWatchResult'}},
20385 'type': 'object'},
20386 'Stop': {'type': 'object'}},
20387 'type': 'object'}
20388
20389
20390 @ReturnMapping(MachineStorageIdsWatchResult)
20391 async def Next(self):
20392 '''
20393
20394 Returns -> typing.Union[typing.Sequence[~MachineStorageId], _ForwardRef('Error')]
20395 '''
20396 # map input types to rpc msg
20397 params = dict()
20398 msg = dict(Type='VolumeAttachmentsWatcher', Request='Next', Version=2, Params=params)
20399
20400 reply = await self.rpc(msg)
20401 return reply
20402
20403
20404
20405 @ReturnMapping(None)
20406 async def Stop(self):
20407 '''
20408
20409 Returns -> None
20410 '''
20411 # map input types to rpc msg
20412 params = dict()
20413 msg = dict(Type='VolumeAttachmentsWatcher', Request='Stop', Version=2, Params=params)
20414
20415 reply = await self.rpc(msg)
20416 return reply
20417
20418