1# coding=utf-8
2# --------------------------------------------------------------------------
3# Copyright (c) Microsoft Corporation. All rights reserved.
4# Licensed under the MIT License. See License.txt in the project root for license information.
5# Code generated by Microsoft (R) AutoRest Code Generator.
6# Changes may cause incorrect behavior and will be lost if the code is regenerated.
7# --------------------------------------------------------------------------
8
9from azure.core.exceptions import HttpResponseError
10import msrest.serialization
11
12
13class ActivationProperties(msrest.serialization.Model):
14    """The activation properties of the connected registry.
15
16    Variables are only populated by the server, and will be ignored when sending a request.
17
18    :ivar status: The activation status of the connected registry. Possible values include:
19     "Active", "Inactive".
20    :vartype status: str or
21     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ActivationStatus
22    """
23
24    _validation = {
25        'status': {'readonly': True},
26    }
27
28    _attribute_map = {
29        'status': {'key': 'status', 'type': 'str'},
30    }
31
32    def __init__(
33        self,
34        **kwargs
35    ):
36        super(ActivationProperties, self).__init__(**kwargs)
37        self.status = None
38
39
40class ActiveDirectoryObject(msrest.serialization.Model):
41    """The Active Directory Object that will be used for authenticating the token of a container registry.
42
43    :param object_id: The user/group/application object ID for Active Directory Object that will be
44     used for authenticating the token of a container registry.
45    :type object_id: str
46    :param tenant_id: The tenant ID of user/group/application object Active Directory Object that
47     will be used for authenticating the token of a container registry.
48    :type tenant_id: str
49    """
50
51    _attribute_map = {
52        'object_id': {'key': 'objectId', 'type': 'str'},
53        'tenant_id': {'key': 'tenantId', 'type': 'str'},
54    }
55
56    def __init__(
57        self,
58        **kwargs
59    ):
60        super(ActiveDirectoryObject, self).__init__(**kwargs)
61        self.object_id = kwargs.get('object_id', None)
62        self.tenant_id = kwargs.get('tenant_id', None)
63
64
65class Actor(msrest.serialization.Model):
66    """The agent that initiated the event. For most situations, this could be from the authorization context of the request.
67
68    :param name: The subject or username associated with the request context that generated the
69     event.
70    :type name: str
71    """
72
73    _attribute_map = {
74        'name': {'key': 'name', 'type': 'str'},
75    }
76
77    def __init__(
78        self,
79        **kwargs
80    ):
81        super(Actor, self).__init__(**kwargs)
82        self.name = kwargs.get('name', None)
83
84
85class CallbackConfig(msrest.serialization.Model):
86    """The configuration of service URI and custom headers for the webhook.
87
88    All required parameters must be populated in order to send to Azure.
89
90    :param service_uri: Required. The service URI for the webhook to post notifications.
91    :type service_uri: str
92    :param custom_headers: Custom headers that will be added to the webhook notifications.
93    :type custom_headers: dict[str, str]
94    """
95
96    _validation = {
97        'service_uri': {'required': True},
98    }
99
100    _attribute_map = {
101        'service_uri': {'key': 'serviceUri', 'type': 'str'},
102        'custom_headers': {'key': 'customHeaders', 'type': '{str}'},
103    }
104
105    def __init__(
106        self,
107        **kwargs
108    ):
109        super(CallbackConfig, self).__init__(**kwargs)
110        self.service_uri = kwargs['service_uri']
111        self.custom_headers = kwargs.get('custom_headers', None)
112
113
114class ProxyResource(msrest.serialization.Model):
115    """The resource model definition for a ARM proxy resource. It will have everything other than required location and tags.
116
117    Variables are only populated by the server, and will be ignored when sending a request.
118
119    :ivar id: The resource ID.
120    :vartype id: str
121    :ivar name: The name of the resource.
122    :vartype name: str
123    :ivar type: The type of the resource.
124    :vartype type: str
125    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
126    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
127    """
128
129    _validation = {
130        'id': {'readonly': True},
131        'name': {'readonly': True},
132        'type': {'readonly': True},
133        'system_data': {'readonly': True},
134    }
135
136    _attribute_map = {
137        'id': {'key': 'id', 'type': 'str'},
138        'name': {'key': 'name', 'type': 'str'},
139        'type': {'key': 'type', 'type': 'str'},
140        'system_data': {'key': 'systemData', 'type': 'SystemData'},
141    }
142
143    def __init__(
144        self,
145        **kwargs
146    ):
147        super(ProxyResource, self).__init__(**kwargs)
148        self.id = None
149        self.name = None
150        self.type = None
151        self.system_data = None
152
153
154class ConnectedRegistry(ProxyResource):
155    """An object that represents a connected registry for a container registry.
156
157    Variables are only populated by the server, and will be ignored when sending a request.
158
159    :ivar id: The resource ID.
160    :vartype id: str
161    :ivar name: The name of the resource.
162    :vartype name: str
163    :ivar type: The type of the resource.
164    :vartype type: str
165    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
166    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
167    :ivar provisioning_state: Provisioning state of the resource. Possible values include:
168     "Creating", "Updating", "Deleting", "Succeeded", "Failed", "Canceled".
169    :vartype provisioning_state: str or
170     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
171    :param mode: The mode of the connected registry resource that indicates the permissions of the
172     registry. Possible values include: "Registry", "Mirror".
173    :type mode: str or
174     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ConnectedRegistryMode
175    :ivar version: The current version of ACR runtime on the connected registry.
176    :vartype version: str
177    :ivar connection_state: The current connection state of the connected registry. Possible values
178     include: "Online", "Offline", "Syncing", "Unhealthy".
179    :vartype connection_state: str or
180     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ConnectionState
181    :ivar last_activity_time: The last activity time of the connected registry.
182    :vartype last_activity_time: ~datetime.datetime
183    :ivar activation: The activation properties of the connected registry.
184    :vartype activation:
185     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ActivationProperties
186    :param parent: The parent of the connected registry.
187    :type parent: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ParentProperties
188    :param client_token_ids: The list of the ACR token resource IDs used to authenticate clients to
189     the connected registry.
190    :type client_token_ids: list[str]
191    :param login_server: The login server properties of the connected registry.
192    :type login_server:
193     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.LoginServerProperties
194    :param logging: The logging properties of the connected registry.
195    :type logging: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.LoggingProperties
196    :ivar status_details: The list of current statuses of the connected registry.
197    :vartype status_details:
198     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.StatusDetailProperties]
199    """
200
201    _validation = {
202        'id': {'readonly': True},
203        'name': {'readonly': True},
204        'type': {'readonly': True},
205        'system_data': {'readonly': True},
206        'provisioning_state': {'readonly': True},
207        'version': {'readonly': True},
208        'connection_state': {'readonly': True},
209        'last_activity_time': {'readonly': True},
210        'activation': {'readonly': True},
211        'status_details': {'readonly': True},
212    }
213
214    _attribute_map = {
215        'id': {'key': 'id', 'type': 'str'},
216        'name': {'key': 'name', 'type': 'str'},
217        'type': {'key': 'type', 'type': 'str'},
218        'system_data': {'key': 'systemData', 'type': 'SystemData'},
219        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
220        'mode': {'key': 'properties.mode', 'type': 'str'},
221        'version': {'key': 'properties.version', 'type': 'str'},
222        'connection_state': {'key': 'properties.connectionState', 'type': 'str'},
223        'last_activity_time': {'key': 'properties.lastActivityTime', 'type': 'iso-8601'},
224        'activation': {'key': 'properties.activation', 'type': 'ActivationProperties'},
225        'parent': {'key': 'properties.parent', 'type': 'ParentProperties'},
226        'client_token_ids': {'key': 'properties.clientTokenIds', 'type': '[str]'},
227        'login_server': {'key': 'properties.loginServer', 'type': 'LoginServerProperties'},
228        'logging': {'key': 'properties.logging', 'type': 'LoggingProperties'},
229        'status_details': {'key': 'properties.statusDetails', 'type': '[StatusDetailProperties]'},
230    }
231
232    def __init__(
233        self,
234        **kwargs
235    ):
236        super(ConnectedRegistry, self).__init__(**kwargs)
237        self.provisioning_state = None
238        self.mode = kwargs.get('mode', None)
239        self.version = None
240        self.connection_state = None
241        self.last_activity_time = None
242        self.activation = None
243        self.parent = kwargs.get('parent', None)
244        self.client_token_ids = kwargs.get('client_token_ids', None)
245        self.login_server = kwargs.get('login_server', None)
246        self.logging = kwargs.get('logging', None)
247        self.status_details = None
248
249
250class ConnectedRegistryListResult(msrest.serialization.Model):
251    """The result of a request to list connected registries for a container registry.
252
253    :param value: The list of connected registries. Since this list may be incomplete, the nextLink
254     field should be used to request the next list of connected registries.
255    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.ConnectedRegistry]
256    :param next_link: The URI that can be used to request the next list of connected registries.
257    :type next_link: str
258    """
259
260    _attribute_map = {
261        'value': {'key': 'value', 'type': '[ConnectedRegistry]'},
262        'next_link': {'key': 'nextLink', 'type': 'str'},
263    }
264
265    def __init__(
266        self,
267        **kwargs
268    ):
269        super(ConnectedRegistryListResult, self).__init__(**kwargs)
270        self.value = kwargs.get('value', None)
271        self.next_link = kwargs.get('next_link', None)
272
273
274class ConnectedRegistryUpdateParameters(msrest.serialization.Model):
275    """The parameters for updating a connected registry.
276
277    :param sync_properties: The sync properties of the connected registry with its parent.
278    :type sync_properties:
279     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SyncUpdateProperties
280    :param logging: The logging properties of the connected registry.
281    :type logging: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.LoggingProperties
282    :param client_token_ids: The list of the ACR token resource IDs used to authenticate clients to
283     the connected registry.
284    :type client_token_ids: list[str]
285    """
286
287    _attribute_map = {
288        'sync_properties': {'key': 'properties.syncProperties', 'type': 'SyncUpdateProperties'},
289        'logging': {'key': 'properties.logging', 'type': 'LoggingProperties'},
290        'client_token_ids': {'key': 'properties.clientTokenIds', 'type': '[str]'},
291    }
292
293    def __init__(
294        self,
295        **kwargs
296    ):
297        super(ConnectedRegistryUpdateParameters, self).__init__(**kwargs)
298        self.sync_properties = kwargs.get('sync_properties', None)
299        self.logging = kwargs.get('logging', None)
300        self.client_token_ids = kwargs.get('client_token_ids', None)
301
302
303class EncryptionProperty(msrest.serialization.Model):
304    """EncryptionProperty.
305
306    :param status: Indicates whether or not the encryption is enabled for container registry.
307     Possible values include: "enabled", "disabled".
308    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.EncryptionStatus
309    :param key_vault_properties: Key vault properties.
310    :type key_vault_properties:
311     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.KeyVaultProperties
312    """
313
314    _attribute_map = {
315        'status': {'key': 'status', 'type': 'str'},
316        'key_vault_properties': {'key': 'keyVaultProperties', 'type': 'KeyVaultProperties'},
317    }
318
319    def __init__(
320        self,
321        **kwargs
322    ):
323        super(EncryptionProperty, self).__init__(**kwargs)
324        self.status = kwargs.get('status', None)
325        self.key_vault_properties = kwargs.get('key_vault_properties', None)
326
327
328class ErrorResponse(msrest.serialization.Model):
329    """An error response from the Azure Container Registry service.
330
331    :param error: Azure container registry build API error body.
332    :type error: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ErrorResponseBody
333    """
334
335    _attribute_map = {
336        'error': {'key': 'error', 'type': 'ErrorResponseBody'},
337    }
338
339    def __init__(
340        self,
341        **kwargs
342    ):
343        super(ErrorResponse, self).__init__(**kwargs)
344        self.error = kwargs.get('error', None)
345
346
347class ErrorResponseBody(msrest.serialization.Model):
348    """An error response from the Azure Container Registry service.
349
350    All required parameters must be populated in order to send to Azure.
351
352    :param code: Required. error code.
353    :type code: str
354    :param message: Required. error message.
355    :type message: str
356    :param target: target of the particular error.
357    :type target: str
358    :param details: an array of additional nested error response info objects, as described by this
359     contract.
360    :type details: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.InnerErrorDescription
361    """
362
363    _validation = {
364        'code': {'required': True},
365        'message': {'required': True},
366    }
367
368    _attribute_map = {
369        'code': {'key': 'code', 'type': 'str'},
370        'message': {'key': 'message', 'type': 'str'},
371        'target': {'key': 'target', 'type': 'str'},
372        'details': {'key': 'details', 'type': 'InnerErrorDescription'},
373    }
374
375    def __init__(
376        self,
377        **kwargs
378    ):
379        super(ErrorResponseBody, self).__init__(**kwargs)
380        self.code = kwargs['code']
381        self.message = kwargs['message']
382        self.target = kwargs.get('target', None)
383        self.details = kwargs.get('details', None)
384
385
386class EventInfo(msrest.serialization.Model):
387    """The basic information of an event.
388
389    :param id: The event ID.
390    :type id: str
391    """
392
393    _attribute_map = {
394        'id': {'key': 'id', 'type': 'str'},
395    }
396
397    def __init__(
398        self,
399        **kwargs
400    ):
401        super(EventInfo, self).__init__(**kwargs)
402        self.id = kwargs.get('id', None)
403
404
405class Event(EventInfo):
406    """The event for a webhook.
407
408    :param id: The event ID.
409    :type id: str
410    :param event_request_message: The event request message sent to the service URI.
411    :type event_request_message:
412     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.EventRequestMessage
413    :param event_response_message: The event response message received from the service URI.
414    :type event_response_message:
415     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.EventResponseMessage
416    """
417
418    _attribute_map = {
419        'id': {'key': 'id', 'type': 'str'},
420        'event_request_message': {'key': 'eventRequestMessage', 'type': 'EventRequestMessage'},
421        'event_response_message': {'key': 'eventResponseMessage', 'type': 'EventResponseMessage'},
422    }
423
424    def __init__(
425        self,
426        **kwargs
427    ):
428        super(Event, self).__init__(**kwargs)
429        self.event_request_message = kwargs.get('event_request_message', None)
430        self.event_response_message = kwargs.get('event_response_message', None)
431
432
433class EventContent(msrest.serialization.Model):
434    """The content of the event request message.
435
436    :param id: The event ID.
437    :type id: str
438    :param timestamp: The time at which the event occurred.
439    :type timestamp: ~datetime.datetime
440    :param action: The action that encompasses the provided event.
441    :type action: str
442    :param target: The target of the event.
443    :type target: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Target
444    :param request: The request that generated the event.
445    :type request: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Request
446    :param actor: The agent that initiated the event. For most situations, this could be from the
447     authorization context of the request.
448    :type actor: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Actor
449    :param source: The registry node that generated the event. Put differently, while the actor
450     initiates the event, the source generates it.
451    :type source: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Source
452    """
453
454    _attribute_map = {
455        'id': {'key': 'id', 'type': 'str'},
456        'timestamp': {'key': 'timestamp', 'type': 'iso-8601'},
457        'action': {'key': 'action', 'type': 'str'},
458        'target': {'key': 'target', 'type': 'Target'},
459        'request': {'key': 'request', 'type': 'Request'},
460        'actor': {'key': 'actor', 'type': 'Actor'},
461        'source': {'key': 'source', 'type': 'Source'},
462    }
463
464    def __init__(
465        self,
466        **kwargs
467    ):
468        super(EventContent, self).__init__(**kwargs)
469        self.id = kwargs.get('id', None)
470        self.timestamp = kwargs.get('timestamp', None)
471        self.action = kwargs.get('action', None)
472        self.target = kwargs.get('target', None)
473        self.request = kwargs.get('request', None)
474        self.actor = kwargs.get('actor', None)
475        self.source = kwargs.get('source', None)
476
477
478class EventListResult(msrest.serialization.Model):
479    """The result of a request to list events for a webhook.
480
481    :param value: The list of events. Since this list may be incomplete, the nextLink field should
482     be used to request the next list of events.
483    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.Event]
484    :param next_link: The URI that can be used to request the next list of events.
485    :type next_link: str
486    """
487
488    _attribute_map = {
489        'value': {'key': 'value', 'type': '[Event]'},
490        'next_link': {'key': 'nextLink', 'type': 'str'},
491    }
492
493    def __init__(
494        self,
495        **kwargs
496    ):
497        super(EventListResult, self).__init__(**kwargs)
498        self.value = kwargs.get('value', None)
499        self.next_link = kwargs.get('next_link', None)
500
501
502class EventRequestMessage(msrest.serialization.Model):
503    """The event request message sent to the service URI.
504
505    :param content: The content of the event request message.
506    :type content: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.EventContent
507    :param headers: The headers of the event request message.
508    :type headers: dict[str, str]
509    :param method: The HTTP method used to send the event request message.
510    :type method: str
511    :param request_uri: The URI used to send the event request message.
512    :type request_uri: str
513    :param version: The HTTP message version.
514    :type version: str
515    """
516
517    _attribute_map = {
518        'content': {'key': 'content', 'type': 'EventContent'},
519        'headers': {'key': 'headers', 'type': '{str}'},
520        'method': {'key': 'method', 'type': 'str'},
521        'request_uri': {'key': 'requestUri', 'type': 'str'},
522        'version': {'key': 'version', 'type': 'str'},
523    }
524
525    def __init__(
526        self,
527        **kwargs
528    ):
529        super(EventRequestMessage, self).__init__(**kwargs)
530        self.content = kwargs.get('content', None)
531        self.headers = kwargs.get('headers', None)
532        self.method = kwargs.get('method', None)
533        self.request_uri = kwargs.get('request_uri', None)
534        self.version = kwargs.get('version', None)
535
536
537class EventResponseMessage(msrest.serialization.Model):
538    """The event response message received from the service URI.
539
540    :param content: The content of the event response message.
541    :type content: str
542    :param headers: The headers of the event response message.
543    :type headers: dict[str, str]
544    :param reason_phrase: The reason phrase of the event response message.
545    :type reason_phrase: str
546    :param status_code: The status code of the event response message.
547    :type status_code: str
548    :param version: The HTTP message version.
549    :type version: str
550    """
551
552    _attribute_map = {
553        'content': {'key': 'content', 'type': 'str'},
554        'headers': {'key': 'headers', 'type': '{str}'},
555        'reason_phrase': {'key': 'reasonPhrase', 'type': 'str'},
556        'status_code': {'key': 'statusCode', 'type': 'str'},
557        'version': {'key': 'version', 'type': 'str'},
558    }
559
560    def __init__(
561        self,
562        **kwargs
563    ):
564        super(EventResponseMessage, self).__init__(**kwargs)
565        self.content = kwargs.get('content', None)
566        self.headers = kwargs.get('headers', None)
567        self.reason_phrase = kwargs.get('reason_phrase', None)
568        self.status_code = kwargs.get('status_code', None)
569        self.version = kwargs.get('version', None)
570
571
572class ExportPipeline(ProxyResource):
573    """An object that represents an export pipeline for a container registry.
574
575    Variables are only populated by the server, and will be ignored when sending a request.
576
577    :ivar id: The resource ID.
578    :vartype id: str
579    :ivar name: The name of the resource.
580    :vartype name: str
581    :ivar type: The type of the resource.
582    :vartype type: str
583    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
584    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
585    :param location: The location of the export pipeline.
586    :type location: str
587    :param identity: The identity of the export pipeline.
588    :type identity: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.IdentityProperties
589    :param target: The target properties of the export pipeline.
590    :type target:
591     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ExportPipelineTargetProperties
592    :param options: The list of all options configured for the pipeline.
593    :type options: list[str or
594     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineOptions]
595    :ivar provisioning_state: The provisioning state of the pipeline at the time the operation was
596     called. Possible values include: "Creating", "Updating", "Deleting", "Succeeded", "Failed",
597     "Canceled".
598    :vartype provisioning_state: str or
599     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
600    """
601
602    _validation = {
603        'id': {'readonly': True},
604        'name': {'readonly': True},
605        'type': {'readonly': True},
606        'system_data': {'readonly': True},
607        'provisioning_state': {'readonly': True},
608    }
609
610    _attribute_map = {
611        'id': {'key': 'id', 'type': 'str'},
612        'name': {'key': 'name', 'type': 'str'},
613        'type': {'key': 'type', 'type': 'str'},
614        'system_data': {'key': 'systemData', 'type': 'SystemData'},
615        'location': {'key': 'location', 'type': 'str'},
616        'identity': {'key': 'identity', 'type': 'IdentityProperties'},
617        'target': {'key': 'properties.target', 'type': 'ExportPipelineTargetProperties'},
618        'options': {'key': 'properties.options', 'type': '[str]'},
619        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
620    }
621
622    def __init__(
623        self,
624        **kwargs
625    ):
626        super(ExportPipeline, self).__init__(**kwargs)
627        self.location = kwargs.get('location', None)
628        self.identity = kwargs.get('identity', None)
629        self.target = kwargs.get('target', None)
630        self.options = kwargs.get('options', None)
631        self.provisioning_state = None
632
633
634class ExportPipelineListResult(msrest.serialization.Model):
635    """The result of a request to list export pipelines for a container registry.
636
637    :param value: The list of export pipelines. Since this list may be incomplete, the nextLink
638     field should be used to request the next list of export pipelines.
639    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.ExportPipeline]
640    :param next_link: The URI that can be used to request the next list of pipeline runs.
641    :type next_link: str
642    """
643
644    _attribute_map = {
645        'value': {'key': 'value', 'type': '[ExportPipeline]'},
646        'next_link': {'key': 'nextLink', 'type': 'str'},
647    }
648
649    def __init__(
650        self,
651        **kwargs
652    ):
653        super(ExportPipelineListResult, self).__init__(**kwargs)
654        self.value = kwargs.get('value', None)
655        self.next_link = kwargs.get('next_link', None)
656
657
658class ExportPipelineTargetProperties(msrest.serialization.Model):
659    """The properties of the export pipeline target.
660
661    All required parameters must be populated in order to send to Azure.
662
663    :param type: The type of target for the export pipeline.
664    :type type: str
665    :param uri: The target uri of the export pipeline.
666     When 'AzureStorageBlob': "https://accountName.blob.core.windows.net/containerName/blobName"
667     When 'AzureStorageBlobContainer':  "https://accountName.blob.core.windows.net/containerName".
668    :type uri: str
669    :param key_vault_uri: Required. They key vault secret uri to obtain the target storage SAS
670     token.
671    :type key_vault_uri: str
672    """
673
674    _validation = {
675        'key_vault_uri': {'required': True},
676    }
677
678    _attribute_map = {
679        'type': {'key': 'type', 'type': 'str'},
680        'uri': {'key': 'uri', 'type': 'str'},
681        'key_vault_uri': {'key': 'keyVaultUri', 'type': 'str'},
682    }
683
684    def __init__(
685        self,
686        **kwargs
687    ):
688        super(ExportPipelineTargetProperties, self).__init__(**kwargs)
689        self.type = kwargs.get('type', None)
690        self.uri = kwargs.get('uri', None)
691        self.key_vault_uri = kwargs['key_vault_uri']
692
693
694class ExportPolicy(msrest.serialization.Model):
695    """The export policy for a container registry.
696
697    :param status: The value that indicates whether the policy is enabled or not. Possible values
698     include: "enabled", "disabled". Default value: "enabled".
699    :type status: str or
700     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ExportPolicyStatus
701    """
702
703    _attribute_map = {
704        'status': {'key': 'status', 'type': 'str'},
705    }
706
707    def __init__(
708        self,
709        **kwargs
710    ):
711        super(ExportPolicy, self).__init__(**kwargs)
712        self.status = kwargs.get('status', "enabled")
713
714
715class GenerateCredentialsParameters(msrest.serialization.Model):
716    """The parameters used to generate credentials for a specified token or user of a container registry.
717
718    :param token_id: The resource ID of the token for which credentials have to be generated.
719    :type token_id: str
720    :param expiry: The expiry date of the generated credentials after which the credentials become
721     invalid.
722    :type expiry: ~datetime.datetime
723    :param name: Specifies name of the password which should be regenerated if any -- password1 or
724     password2. Possible values include: "password1", "password2".
725    :type name: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenPasswordName
726    """
727
728    _attribute_map = {
729        'token_id': {'key': 'tokenId', 'type': 'str'},
730        'expiry': {'key': 'expiry', 'type': 'iso-8601'},
731        'name': {'key': 'name', 'type': 'str'},
732    }
733
734    def __init__(
735        self,
736        **kwargs
737    ):
738        super(GenerateCredentialsParameters, self).__init__(**kwargs)
739        self.token_id = kwargs.get('token_id', None)
740        self.expiry = kwargs.get('expiry', None)
741        self.name = kwargs.get('name', None)
742
743
744class GenerateCredentialsResult(msrest.serialization.Model):
745    """The response from the GenerateCredentials operation.
746
747    :param username: The username for a container registry.
748    :type username: str
749    :param passwords: The list of passwords for a container registry.
750    :type passwords: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenPassword]
751    """
752
753    _attribute_map = {
754        'username': {'key': 'username', 'type': 'str'},
755        'passwords': {'key': 'passwords', 'type': '[TokenPassword]'},
756    }
757
758    def __init__(
759        self,
760        **kwargs
761    ):
762        super(GenerateCredentialsResult, self).__init__(**kwargs)
763        self.username = kwargs.get('username', None)
764        self.passwords = kwargs.get('passwords', None)
765
766
767class IdentityProperties(msrest.serialization.Model):
768    """Managed identity for the resource.
769
770    :param principal_id: The principal ID of resource identity.
771    :type principal_id: str
772    :param tenant_id: The tenant ID of resource.
773    :type tenant_id: str
774    :param type: The identity type. Possible values include: "SystemAssigned", "UserAssigned",
775     "SystemAssigned, UserAssigned", "None".
776    :type type: str or
777     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ResourceIdentityType
778    :param user_assigned_identities: The list of user identities associated with the resource. The
779     user identity
780     dictionary key references will be ARM resource ids in the form:
781     '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/
782         providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
783    :type user_assigned_identities: dict[str,
784     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.UserIdentityProperties]
785    """
786
787    _attribute_map = {
788        'principal_id': {'key': 'principalId', 'type': 'str'},
789        'tenant_id': {'key': 'tenantId', 'type': 'str'},
790        'type': {'key': 'type', 'type': 'str'},
791        'user_assigned_identities': {'key': 'userAssignedIdentities', 'type': '{UserIdentityProperties}'},
792    }
793
794    def __init__(
795        self,
796        **kwargs
797    ):
798        super(IdentityProperties, self).__init__(**kwargs)
799        self.principal_id = kwargs.get('principal_id', None)
800        self.tenant_id = kwargs.get('tenant_id', None)
801        self.type = kwargs.get('type', None)
802        self.user_assigned_identities = kwargs.get('user_assigned_identities', None)
803
804
805class ImportImageParameters(msrest.serialization.Model):
806    """ImportImageParameters.
807
808    All required parameters must be populated in order to send to Azure.
809
810    :param source: Required. The source of the image.
811    :type source: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ImportSource
812    :param target_tags: List of strings of the form repo[:tag]. When tag is omitted the source will
813     be used (or 'latest' if source tag is also omitted).
814    :type target_tags: list[str]
815    :param untagged_target_repositories: List of strings of repository names to do a manifest only
816     copy. No tag will be created.
817    :type untagged_target_repositories: list[str]
818    :param mode: When Force, any existing target tags will be overwritten. When NoForce, any
819     existing target tags will fail the operation before any copying begins. Possible values
820     include: "NoForce", "Force". Default value: "NoForce".
821    :type mode: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ImportMode
822    """
823
824    _validation = {
825        'source': {'required': True},
826    }
827
828    _attribute_map = {
829        'source': {'key': 'source', 'type': 'ImportSource'},
830        'target_tags': {'key': 'targetTags', 'type': '[str]'},
831        'untagged_target_repositories': {'key': 'untaggedTargetRepositories', 'type': '[str]'},
832        'mode': {'key': 'mode', 'type': 'str'},
833    }
834
835    def __init__(
836        self,
837        **kwargs
838    ):
839        super(ImportImageParameters, self).__init__(**kwargs)
840        self.source = kwargs['source']
841        self.target_tags = kwargs.get('target_tags', None)
842        self.untagged_target_repositories = kwargs.get('untagged_target_repositories', None)
843        self.mode = kwargs.get('mode', "NoForce")
844
845
846class ImportPipeline(ProxyResource):
847    """An object that represents an import pipeline for a container registry.
848
849    Variables are only populated by the server, and will be ignored when sending a request.
850
851    :ivar id: The resource ID.
852    :vartype id: str
853    :ivar name: The name of the resource.
854    :vartype name: str
855    :ivar type: The type of the resource.
856    :vartype type: str
857    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
858    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
859    :param location: The location of the import pipeline.
860    :type location: str
861    :param identity: The identity of the import pipeline.
862    :type identity: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.IdentityProperties
863    :param source: The source properties of the import pipeline.
864    :type source:
865     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ImportPipelineSourceProperties
866    :param trigger: The properties that describe the trigger of the import pipeline.
867    :type trigger:
868     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineTriggerProperties
869    :param options: The list of all options configured for the pipeline.
870    :type options: list[str or
871     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineOptions]
872    :ivar provisioning_state: The provisioning state of the pipeline at the time the operation was
873     called. Possible values include: "Creating", "Updating", "Deleting", "Succeeded", "Failed",
874     "Canceled".
875    :vartype provisioning_state: str or
876     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
877    """
878
879    _validation = {
880        'id': {'readonly': True},
881        'name': {'readonly': True},
882        'type': {'readonly': True},
883        'system_data': {'readonly': True},
884        'provisioning_state': {'readonly': True},
885    }
886
887    _attribute_map = {
888        'id': {'key': 'id', 'type': 'str'},
889        'name': {'key': 'name', 'type': 'str'},
890        'type': {'key': 'type', 'type': 'str'},
891        'system_data': {'key': 'systemData', 'type': 'SystemData'},
892        'location': {'key': 'location', 'type': 'str'},
893        'identity': {'key': 'identity', 'type': 'IdentityProperties'},
894        'source': {'key': 'properties.source', 'type': 'ImportPipelineSourceProperties'},
895        'trigger': {'key': 'properties.trigger', 'type': 'PipelineTriggerProperties'},
896        'options': {'key': 'properties.options', 'type': '[str]'},
897        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
898    }
899
900    def __init__(
901        self,
902        **kwargs
903    ):
904        super(ImportPipeline, self).__init__(**kwargs)
905        self.location = kwargs.get('location', None)
906        self.identity = kwargs.get('identity', None)
907        self.source = kwargs.get('source', None)
908        self.trigger = kwargs.get('trigger', None)
909        self.options = kwargs.get('options', None)
910        self.provisioning_state = None
911
912
913class ImportPipelineListResult(msrest.serialization.Model):
914    """The result of a request to list import pipelines for a container registry.
915
916    :param value: The list of import pipelines. Since this list may be incomplete, the nextLink
917     field should be used to request the next list of import pipelines.
918    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.ImportPipeline]
919    :param next_link: The URI that can be used to request the next list of pipeline runs.
920    :type next_link: str
921    """
922
923    _attribute_map = {
924        'value': {'key': 'value', 'type': '[ImportPipeline]'},
925        'next_link': {'key': 'nextLink', 'type': 'str'},
926    }
927
928    def __init__(
929        self,
930        **kwargs
931    ):
932        super(ImportPipelineListResult, self).__init__(**kwargs)
933        self.value = kwargs.get('value', None)
934        self.next_link = kwargs.get('next_link', None)
935
936
937class ImportPipelineSourceProperties(msrest.serialization.Model):
938    """The properties of the import pipeline source.
939
940    All required parameters must be populated in order to send to Azure.
941
942    :param type: The type of source for the import pipeline. Possible values include:
943     "AzureStorageBlobContainer". Default value: "AzureStorageBlobContainer".
944    :type type: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineSourceType
945    :param uri: The source uri of the import pipeline.
946     When 'AzureStorageBlob': "https://accountName.blob.core.windows.net/containerName/blobName"
947     When 'AzureStorageBlobContainer': "https://accountName.blob.core.windows.net/containerName".
948    :type uri: str
949    :param key_vault_uri: Required. They key vault secret uri to obtain the source storage SAS
950     token.
951    :type key_vault_uri: str
952    """
953
954    _validation = {
955        'key_vault_uri': {'required': True},
956    }
957
958    _attribute_map = {
959        'type': {'key': 'type', 'type': 'str'},
960        'uri': {'key': 'uri', 'type': 'str'},
961        'key_vault_uri': {'key': 'keyVaultUri', 'type': 'str'},
962    }
963
964    def __init__(
965        self,
966        **kwargs
967    ):
968        super(ImportPipelineSourceProperties, self).__init__(**kwargs)
969        self.type = kwargs.get('type', "AzureStorageBlobContainer")
970        self.uri = kwargs.get('uri', None)
971        self.key_vault_uri = kwargs['key_vault_uri']
972
973
974class ImportSource(msrest.serialization.Model):
975    """ImportSource.
976
977    All required parameters must be populated in order to send to Azure.
978
979    :param resource_id: The resource identifier of the source Azure Container Registry.
980    :type resource_id: str
981    :param registry_uri: The address of the source registry (e.g. 'mcr.microsoft.com').
982    :type registry_uri: str
983    :param credentials: Credentials used when importing from a registry uri.
984    :type credentials:
985     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ImportSourceCredentials
986    :param source_image: Required. Repository name of the source image.
987     Specify an image by repository ('hello-world'). This will use the 'latest' tag.
988     Specify an image by tag ('hello-world:latest').
989     Specify an image by sha256-based manifest digest ('hello-world@sha256:abc123').
990    :type source_image: str
991    """
992
993    _validation = {
994        'source_image': {'required': True},
995    }
996
997    _attribute_map = {
998        'resource_id': {'key': 'resourceId', 'type': 'str'},
999        'registry_uri': {'key': 'registryUri', 'type': 'str'},
1000        'credentials': {'key': 'credentials', 'type': 'ImportSourceCredentials'},
1001        'source_image': {'key': 'sourceImage', 'type': 'str'},
1002    }
1003
1004    def __init__(
1005        self,
1006        **kwargs
1007    ):
1008        super(ImportSource, self).__init__(**kwargs)
1009        self.resource_id = kwargs.get('resource_id', None)
1010        self.registry_uri = kwargs.get('registry_uri', None)
1011        self.credentials = kwargs.get('credentials', None)
1012        self.source_image = kwargs['source_image']
1013
1014
1015class ImportSourceCredentials(msrest.serialization.Model):
1016    """ImportSourceCredentials.
1017
1018    All required parameters must be populated in order to send to Azure.
1019
1020    :param username: The username to authenticate with the source registry.
1021    :type username: str
1022    :param password: Required. The password used to authenticate with the source registry.
1023    :type password: str
1024    """
1025
1026    _validation = {
1027        'password': {'required': True},
1028    }
1029
1030    _attribute_map = {
1031        'username': {'key': 'username', 'type': 'str'},
1032        'password': {'key': 'password', 'type': 'str'},
1033    }
1034
1035    def __init__(
1036        self,
1037        **kwargs
1038    ):
1039        super(ImportSourceCredentials, self).__init__(**kwargs)
1040        self.username = kwargs.get('username', None)
1041        self.password = kwargs['password']
1042
1043
1044class InnerErrorDescription(msrest.serialization.Model):
1045    """inner error.
1046
1047    All required parameters must be populated in order to send to Azure.
1048
1049    :param code: Required. error code.
1050    :type code: str
1051    :param message: Required. error message.
1052    :type message: str
1053    :param target: target of the particular error.
1054    :type target: str
1055    """
1056
1057    _validation = {
1058        'code': {'required': True},
1059        'message': {'required': True},
1060    }
1061
1062    _attribute_map = {
1063        'code': {'key': 'code', 'type': 'str'},
1064        'message': {'key': 'message', 'type': 'str'},
1065        'target': {'key': 'target', 'type': 'str'},
1066    }
1067
1068    def __init__(
1069        self,
1070        **kwargs
1071    ):
1072        super(InnerErrorDescription, self).__init__(**kwargs)
1073        self.code = kwargs['code']
1074        self.message = kwargs['message']
1075        self.target = kwargs.get('target', None)
1076
1077
1078class IPRule(msrest.serialization.Model):
1079    """IP rule with specific IP or IP range in CIDR format.
1080
1081    All required parameters must be populated in order to send to Azure.
1082
1083    :param action: The action of IP ACL rule. Possible values include: "Allow".
1084    :type action: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Action
1085    :param ip_address_or_range: Required. Specifies the IP or IP range in CIDR format. Only IPV4
1086     address is allowed.
1087    :type ip_address_or_range: str
1088    """
1089
1090    _validation = {
1091        'ip_address_or_range': {'required': True},
1092    }
1093
1094    _attribute_map = {
1095        'action': {'key': 'action', 'type': 'str'},
1096        'ip_address_or_range': {'key': 'value', 'type': 'str'},
1097    }
1098
1099    def __init__(
1100        self,
1101        **kwargs
1102    ):
1103        super(IPRule, self).__init__(**kwargs)
1104        self.action = kwargs.get('action', None)
1105        self.ip_address_or_range = kwargs['ip_address_or_range']
1106
1107
1108class KeyVaultProperties(msrest.serialization.Model):
1109    """KeyVaultProperties.
1110
1111    Variables are only populated by the server, and will be ignored when sending a request.
1112
1113    :param key_identifier: Key vault uri to access the encryption key.
1114    :type key_identifier: str
1115    :ivar versioned_key_identifier: The fully qualified key identifier that includes the version of
1116     the key that is actually used for encryption.
1117    :vartype versioned_key_identifier: str
1118    :param identity: The client id of the identity which will be used to access key vault.
1119    :type identity: str
1120    :ivar key_rotation_enabled: Auto key rotation status for a CMK enabled registry.
1121    :vartype key_rotation_enabled: bool
1122    :ivar last_key_rotation_timestamp: Timestamp of the last successful key rotation.
1123    :vartype last_key_rotation_timestamp: ~datetime.datetime
1124    """
1125
1126    _validation = {
1127        'versioned_key_identifier': {'readonly': True},
1128        'key_rotation_enabled': {'readonly': True},
1129        'last_key_rotation_timestamp': {'readonly': True},
1130    }
1131
1132    _attribute_map = {
1133        'key_identifier': {'key': 'keyIdentifier', 'type': 'str'},
1134        'versioned_key_identifier': {'key': 'versionedKeyIdentifier', 'type': 'str'},
1135        'identity': {'key': 'identity', 'type': 'str'},
1136        'key_rotation_enabled': {'key': 'keyRotationEnabled', 'type': 'bool'},
1137        'last_key_rotation_timestamp': {'key': 'lastKeyRotationTimestamp', 'type': 'iso-8601'},
1138    }
1139
1140    def __init__(
1141        self,
1142        **kwargs
1143    ):
1144        super(KeyVaultProperties, self).__init__(**kwargs)
1145        self.key_identifier = kwargs.get('key_identifier', None)
1146        self.versioned_key_identifier = None
1147        self.identity = kwargs.get('identity', None)
1148        self.key_rotation_enabled = None
1149        self.last_key_rotation_timestamp = None
1150
1151
1152class LoggingProperties(msrest.serialization.Model):
1153    """The logging properties of the connected registry.
1154
1155    :param log_level: The verbosity of logs persisted on the connected registry. Possible values
1156     include: "Debug", "Information", "Warning", "Error", "None". Default value: "Information".
1157    :type log_level: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.LogLevel
1158    :param audit_log_status: Indicates whether audit logs are enabled on the connected registry.
1159     Possible values include: "Enabled", "Disabled". Default value: "Disabled".
1160    :type audit_log_status: str or
1161     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.AuditLogStatus
1162    """
1163
1164    _attribute_map = {
1165        'log_level': {'key': 'logLevel', 'type': 'str'},
1166        'audit_log_status': {'key': 'auditLogStatus', 'type': 'str'},
1167    }
1168
1169    def __init__(
1170        self,
1171        **kwargs
1172    ):
1173        super(LoggingProperties, self).__init__(**kwargs)
1174        self.log_level = kwargs.get('log_level', "Information")
1175        self.audit_log_status = kwargs.get('audit_log_status', "Disabled")
1176
1177
1178class LoginServerProperties(msrest.serialization.Model):
1179    """The login server properties of the connected registry.
1180
1181    Variables are only populated by the server, and will be ignored when sending a request.
1182
1183    :ivar host: The host of the connected registry. Can be FQDN or IP.
1184    :vartype host: str
1185    :ivar tls: The TLS properties of the connected registry login server.
1186    :vartype tls: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TlsProperties
1187    """
1188
1189    _validation = {
1190        'host': {'readonly': True},
1191        'tls': {'readonly': True},
1192    }
1193
1194    _attribute_map = {
1195        'host': {'key': 'host', 'type': 'str'},
1196        'tls': {'key': 'tls', 'type': 'TlsProperties'},
1197    }
1198
1199    def __init__(
1200        self,
1201        **kwargs
1202    ):
1203        super(LoginServerProperties, self).__init__(**kwargs)
1204        self.host = None
1205        self.tls = None
1206
1207
1208class NetworkRuleSet(msrest.serialization.Model):
1209    """The network rule set for a container registry.
1210
1211    All required parameters must be populated in order to send to Azure.
1212
1213    :param default_action: Required. The default action of allow or deny when no other rules match.
1214     Possible values include: "Allow", "Deny". Default value: "Allow".
1215    :type default_action: str or
1216     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.DefaultAction
1217    :param virtual_network_rules: The virtual network rules.
1218    :type virtual_network_rules:
1219     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.VirtualNetworkRule]
1220    :param ip_rules: The IP ACL rules.
1221    :type ip_rules: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.IPRule]
1222    """
1223
1224    _validation = {
1225        'default_action': {'required': True},
1226    }
1227
1228    _attribute_map = {
1229        'default_action': {'key': 'defaultAction', 'type': 'str'},
1230        'virtual_network_rules': {'key': 'virtualNetworkRules', 'type': '[VirtualNetworkRule]'},
1231        'ip_rules': {'key': 'ipRules', 'type': '[IPRule]'},
1232    }
1233
1234    def __init__(
1235        self,
1236        **kwargs
1237    ):
1238        super(NetworkRuleSet, self).__init__(**kwargs)
1239        self.default_action = kwargs.get('default_action', "Allow")
1240        self.virtual_network_rules = kwargs.get('virtual_network_rules', None)
1241        self.ip_rules = kwargs.get('ip_rules', None)
1242
1243
1244class OperationDefinition(msrest.serialization.Model):
1245    """The definition of a container registry operation.
1246
1247    :param origin: The origin information of the container registry operation.
1248    :type origin: str
1249    :param name: Operation name: {provider}/{resource}/{operation}.
1250    :type name: str
1251    :param display: The display information for the container registry operation.
1252    :type display:
1253     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.OperationDisplayDefinition
1254    :param is_data_action: This property indicates if the operation is an action or a data action
1255     ref:
1256     https://docs.microsoft.com/en-us/azure/role-based-access-control/role-definitions#management-and-data-operations.
1257    :type is_data_action: bool
1258    :param service_specification: The definition of Azure Monitoring service.
1259    :type service_specification:
1260     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.OperationServiceSpecificationDefinition
1261    """
1262
1263    _attribute_map = {
1264        'origin': {'key': 'origin', 'type': 'str'},
1265        'name': {'key': 'name', 'type': 'str'},
1266        'display': {'key': 'display', 'type': 'OperationDisplayDefinition'},
1267        'is_data_action': {'key': 'isDataAction', 'type': 'bool'},
1268        'service_specification': {'key': 'properties.serviceSpecification', 'type': 'OperationServiceSpecificationDefinition'},
1269    }
1270
1271    def __init__(
1272        self,
1273        **kwargs
1274    ):
1275        super(OperationDefinition, self).__init__(**kwargs)
1276        self.origin = kwargs.get('origin', None)
1277        self.name = kwargs.get('name', None)
1278        self.display = kwargs.get('display', None)
1279        self.is_data_action = kwargs.get('is_data_action', None)
1280        self.service_specification = kwargs.get('service_specification', None)
1281
1282
1283class OperationDisplayDefinition(msrest.serialization.Model):
1284    """The display information for a container registry operation.
1285
1286    :param provider: The resource provider name: Microsoft.ContainerRegistry.
1287    :type provider: str
1288    :param resource: The resource on which the operation is performed.
1289    :type resource: str
1290    :param operation: The operation that users can perform.
1291    :type operation: str
1292    :param description: The description for the operation.
1293    :type description: str
1294    """
1295
1296    _attribute_map = {
1297        'provider': {'key': 'provider', 'type': 'str'},
1298        'resource': {'key': 'resource', 'type': 'str'},
1299        'operation': {'key': 'operation', 'type': 'str'},
1300        'description': {'key': 'description', 'type': 'str'},
1301    }
1302
1303    def __init__(
1304        self,
1305        **kwargs
1306    ):
1307        super(OperationDisplayDefinition, self).__init__(**kwargs)
1308        self.provider = kwargs.get('provider', None)
1309        self.resource = kwargs.get('resource', None)
1310        self.operation = kwargs.get('operation', None)
1311        self.description = kwargs.get('description', None)
1312
1313
1314class OperationListResult(msrest.serialization.Model):
1315    """The result of a request to list container registry operations.
1316
1317    :param value: The list of container registry operations. Since this list may be incomplete, the
1318     nextLink field should be used to request the next list of operations.
1319    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.OperationDefinition]
1320    :param next_link: The URI that can be used to request the next list of container registry
1321     operations.
1322    :type next_link: str
1323    """
1324
1325    _attribute_map = {
1326        'value': {'key': 'value', 'type': '[OperationDefinition]'},
1327        'next_link': {'key': 'nextLink', 'type': 'str'},
1328    }
1329
1330    def __init__(
1331        self,
1332        **kwargs
1333    ):
1334        super(OperationListResult, self).__init__(**kwargs)
1335        self.value = kwargs.get('value', None)
1336        self.next_link = kwargs.get('next_link', None)
1337
1338
1339class OperationLogSpecificationDefinition(msrest.serialization.Model):
1340    """The definition of Azure Monitoring log.
1341
1342    :param name: Log name.
1343    :type name: str
1344    :param display_name: Log display name.
1345    :type display_name: str
1346    :param blob_duration: Log blob duration.
1347    :type blob_duration: str
1348    """
1349
1350    _attribute_map = {
1351        'name': {'key': 'name', 'type': 'str'},
1352        'display_name': {'key': 'displayName', 'type': 'str'},
1353        'blob_duration': {'key': 'blobDuration', 'type': 'str'},
1354    }
1355
1356    def __init__(
1357        self,
1358        **kwargs
1359    ):
1360        super(OperationLogSpecificationDefinition, self).__init__(**kwargs)
1361        self.name = kwargs.get('name', None)
1362        self.display_name = kwargs.get('display_name', None)
1363        self.blob_duration = kwargs.get('blob_duration', None)
1364
1365
1366class OperationMetricSpecificationDefinition(msrest.serialization.Model):
1367    """The definition of Azure Monitoring metric.
1368
1369    :param name: Metric name.
1370    :type name: str
1371    :param display_name: Metric display name.
1372    :type display_name: str
1373    :param display_description: Metric description.
1374    :type display_description: str
1375    :param unit: Metric unit.
1376    :type unit: str
1377    :param aggregation_type: Metric aggregation type.
1378    :type aggregation_type: str
1379    :param internal_metric_name: Internal metric name.
1380    :type internal_metric_name: str
1381    """
1382
1383    _attribute_map = {
1384        'name': {'key': 'name', 'type': 'str'},
1385        'display_name': {'key': 'displayName', 'type': 'str'},
1386        'display_description': {'key': 'displayDescription', 'type': 'str'},
1387        'unit': {'key': 'unit', 'type': 'str'},
1388        'aggregation_type': {'key': 'aggregationType', 'type': 'str'},
1389        'internal_metric_name': {'key': 'internalMetricName', 'type': 'str'},
1390    }
1391
1392    def __init__(
1393        self,
1394        **kwargs
1395    ):
1396        super(OperationMetricSpecificationDefinition, self).__init__(**kwargs)
1397        self.name = kwargs.get('name', None)
1398        self.display_name = kwargs.get('display_name', None)
1399        self.display_description = kwargs.get('display_description', None)
1400        self.unit = kwargs.get('unit', None)
1401        self.aggregation_type = kwargs.get('aggregation_type', None)
1402        self.internal_metric_name = kwargs.get('internal_metric_name', None)
1403
1404
1405class OperationServiceSpecificationDefinition(msrest.serialization.Model):
1406    """The definition of Azure Monitoring list.
1407
1408    :param metric_specifications: A list of Azure Monitoring metrics definition.
1409    :type metric_specifications:
1410     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.OperationMetricSpecificationDefinition]
1411    :param log_specifications: A list of Azure Monitoring log definitions.
1412    :type log_specifications:
1413     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.OperationLogSpecificationDefinition]
1414    """
1415
1416    _attribute_map = {
1417        'metric_specifications': {'key': 'metricSpecifications', 'type': '[OperationMetricSpecificationDefinition]'},
1418        'log_specifications': {'key': 'logSpecifications', 'type': '[OperationLogSpecificationDefinition]'},
1419    }
1420
1421    def __init__(
1422        self,
1423        **kwargs
1424    ):
1425        super(OperationServiceSpecificationDefinition, self).__init__(**kwargs)
1426        self.metric_specifications = kwargs.get('metric_specifications', None)
1427        self.log_specifications = kwargs.get('log_specifications', None)
1428
1429
1430class ParentProperties(msrest.serialization.Model):
1431    """The properties of the connected registry parent.
1432
1433    All required parameters must be populated in order to send to Azure.
1434
1435    :param id: The resource ID of the parent to which the connected registry will be associated.
1436    :type id: str
1437    :param sync_properties: Required. The sync properties of the connected registry with its
1438     parent.
1439    :type sync_properties: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SyncProperties
1440    """
1441
1442    _validation = {
1443        'sync_properties': {'required': True},
1444    }
1445
1446    _attribute_map = {
1447        'id': {'key': 'id', 'type': 'str'},
1448        'sync_properties': {'key': 'syncProperties', 'type': 'SyncProperties'},
1449    }
1450
1451    def __init__(
1452        self,
1453        **kwargs
1454    ):
1455        super(ParentProperties, self).__init__(**kwargs)
1456        self.id = kwargs.get('id', None)
1457        self.sync_properties = kwargs['sync_properties']
1458
1459
1460class PipelineRun(ProxyResource):
1461    """An object that represents a pipeline run for a container registry.
1462
1463    Variables are only populated by the server, and will be ignored when sending a request.
1464
1465    :ivar id: The resource ID.
1466    :vartype id: str
1467    :ivar name: The name of the resource.
1468    :vartype name: str
1469    :ivar type: The type of the resource.
1470    :vartype type: str
1471    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
1472    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
1473    :ivar provisioning_state: The provisioning state of a pipeline run. Possible values include:
1474     "Creating", "Updating", "Deleting", "Succeeded", "Failed", "Canceled".
1475    :vartype provisioning_state: str or
1476     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
1477    :param request: The request parameters for a pipeline run.
1478    :type request: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRunRequest
1479    :ivar response: The response of a pipeline run.
1480    :vartype response: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRunResponse
1481    :param force_update_tag: How the pipeline run should be forced to recreate even if the pipeline
1482     run configuration has not changed.
1483    :type force_update_tag: str
1484    """
1485
1486    _validation = {
1487        'id': {'readonly': True},
1488        'name': {'readonly': True},
1489        'type': {'readonly': True},
1490        'system_data': {'readonly': True},
1491        'provisioning_state': {'readonly': True},
1492        'response': {'readonly': True},
1493    }
1494
1495    _attribute_map = {
1496        'id': {'key': 'id', 'type': 'str'},
1497        'name': {'key': 'name', 'type': 'str'},
1498        'type': {'key': 'type', 'type': 'str'},
1499        'system_data': {'key': 'systemData', 'type': 'SystemData'},
1500        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
1501        'request': {'key': 'properties.request', 'type': 'PipelineRunRequest'},
1502        'response': {'key': 'properties.response', 'type': 'PipelineRunResponse'},
1503        'force_update_tag': {'key': 'properties.forceUpdateTag', 'type': 'str'},
1504    }
1505
1506    def __init__(
1507        self,
1508        **kwargs
1509    ):
1510        super(PipelineRun, self).__init__(**kwargs)
1511        self.provisioning_state = None
1512        self.request = kwargs.get('request', None)
1513        self.response = None
1514        self.force_update_tag = kwargs.get('force_update_tag', None)
1515
1516
1517class PipelineRunListResult(msrest.serialization.Model):
1518    """The result of a request to list pipeline runs for a container registry.
1519
1520    :param value: The list of pipeline runs. Since this list may be incomplete, the nextLink field
1521     should be used to request the next list of pipeline runs.
1522    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRun]
1523    :param next_link: The URI that can be used to request the next list of pipeline runs.
1524    :type next_link: str
1525    """
1526
1527    _attribute_map = {
1528        'value': {'key': 'value', 'type': '[PipelineRun]'},
1529        'next_link': {'key': 'nextLink', 'type': 'str'},
1530    }
1531
1532    def __init__(
1533        self,
1534        **kwargs
1535    ):
1536        super(PipelineRunListResult, self).__init__(**kwargs)
1537        self.value = kwargs.get('value', None)
1538        self.next_link = kwargs.get('next_link', None)
1539
1540
1541class PipelineRunRequest(msrest.serialization.Model):
1542    """The request properties provided for a pipeline run.
1543
1544    :param pipeline_resource_id: The resource ID of the pipeline to run.
1545    :type pipeline_resource_id: str
1546    :param artifacts: List of source artifacts to be transferred by the pipeline.
1547     Specify an image by repository ('hello-world'). This will use the 'latest' tag.
1548     Specify an image by tag ('hello-world:latest').
1549     Specify an image by sha256-based manifest digest ('hello-world@sha256:abc123').
1550    :type artifacts: list[str]
1551    :param source: The source properties of the pipeline run.
1552    :type source:
1553     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRunSourceProperties
1554    :param target: The target properties of the pipeline run.
1555    :type target:
1556     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRunTargetProperties
1557    :param catalog_digest: The digest of the tar used to transfer the artifacts.
1558    :type catalog_digest: str
1559    """
1560
1561    _attribute_map = {
1562        'pipeline_resource_id': {'key': 'pipelineResourceId', 'type': 'str'},
1563        'artifacts': {'key': 'artifacts', 'type': '[str]'},
1564        'source': {'key': 'source', 'type': 'PipelineRunSourceProperties'},
1565        'target': {'key': 'target', 'type': 'PipelineRunTargetProperties'},
1566        'catalog_digest': {'key': 'catalogDigest', 'type': 'str'},
1567    }
1568
1569    def __init__(
1570        self,
1571        **kwargs
1572    ):
1573        super(PipelineRunRequest, self).__init__(**kwargs)
1574        self.pipeline_resource_id = kwargs.get('pipeline_resource_id', None)
1575        self.artifacts = kwargs.get('artifacts', None)
1576        self.source = kwargs.get('source', None)
1577        self.target = kwargs.get('target', None)
1578        self.catalog_digest = kwargs.get('catalog_digest', None)
1579
1580
1581class PipelineRunResponse(msrest.serialization.Model):
1582    """The response properties returned for a pipeline run.
1583
1584    :param status: The current status of the pipeline run.
1585    :type status: str
1586    :param imported_artifacts: The artifacts imported in the pipeline run.
1587    :type imported_artifacts: list[str]
1588    :param progress: The current progress of the copy operation.
1589    :type progress: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProgressProperties
1590    :param start_time: The time the pipeline run started.
1591    :type start_time: ~datetime.datetime
1592    :param finish_time: The time the pipeline run finished.
1593    :type finish_time: ~datetime.datetime
1594    :param source: The source of the pipeline run.
1595    :type source:
1596     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ImportPipelineSourceProperties
1597    :param target: The target of the pipeline run.
1598    :type target:
1599     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ExportPipelineTargetProperties
1600    :param catalog_digest: The digest of the tar used to transfer the artifacts.
1601    :type catalog_digest: str
1602    :param trigger: The trigger that caused the pipeline run.
1603    :type trigger:
1604     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineTriggerDescriptor
1605    :param pipeline_run_error_message: The detailed error message for the pipeline run in the case
1606     of failure.
1607    :type pipeline_run_error_message: str
1608    """
1609
1610    _attribute_map = {
1611        'status': {'key': 'status', 'type': 'str'},
1612        'imported_artifacts': {'key': 'importedArtifacts', 'type': '[str]'},
1613        'progress': {'key': 'progress', 'type': 'ProgressProperties'},
1614        'start_time': {'key': 'startTime', 'type': 'iso-8601'},
1615        'finish_time': {'key': 'finishTime', 'type': 'iso-8601'},
1616        'source': {'key': 'source', 'type': 'ImportPipelineSourceProperties'},
1617        'target': {'key': 'target', 'type': 'ExportPipelineTargetProperties'},
1618        'catalog_digest': {'key': 'catalogDigest', 'type': 'str'},
1619        'trigger': {'key': 'trigger', 'type': 'PipelineTriggerDescriptor'},
1620        'pipeline_run_error_message': {'key': 'pipelineRunErrorMessage', 'type': 'str'},
1621    }
1622
1623    def __init__(
1624        self,
1625        **kwargs
1626    ):
1627        super(PipelineRunResponse, self).__init__(**kwargs)
1628        self.status = kwargs.get('status', None)
1629        self.imported_artifacts = kwargs.get('imported_artifacts', None)
1630        self.progress = kwargs.get('progress', None)
1631        self.start_time = kwargs.get('start_time', None)
1632        self.finish_time = kwargs.get('finish_time', None)
1633        self.source = kwargs.get('source', None)
1634        self.target = kwargs.get('target', None)
1635        self.catalog_digest = kwargs.get('catalog_digest', None)
1636        self.trigger = kwargs.get('trigger', None)
1637        self.pipeline_run_error_message = kwargs.get('pipeline_run_error_message', None)
1638
1639
1640class PipelineRunSourceProperties(msrest.serialization.Model):
1641    """PipelineRunSourceProperties.
1642
1643    :param type: The type of the source. Possible values include: "AzureStorageBlob". Default
1644     value: "AzureStorageBlob".
1645    :type type: str or
1646     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRunSourceType
1647    :param name: The name of the source.
1648    :type name: str
1649    """
1650
1651    _attribute_map = {
1652        'type': {'key': 'type', 'type': 'str'},
1653        'name': {'key': 'name', 'type': 'str'},
1654    }
1655
1656    def __init__(
1657        self,
1658        **kwargs
1659    ):
1660        super(PipelineRunSourceProperties, self).__init__(**kwargs)
1661        self.type = kwargs.get('type', "AzureStorageBlob")
1662        self.name = kwargs.get('name', None)
1663
1664
1665class PipelineRunTargetProperties(msrest.serialization.Model):
1666    """PipelineRunTargetProperties.
1667
1668    :param type: The type of the target. Possible values include: "AzureStorageBlob". Default
1669     value: "AzureStorageBlob".
1670    :type type: str or
1671     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineRunTargetType
1672    :param name: The name of the target.
1673    :type name: str
1674    """
1675
1676    _attribute_map = {
1677        'type': {'key': 'type', 'type': 'str'},
1678        'name': {'key': 'name', 'type': 'str'},
1679    }
1680
1681    def __init__(
1682        self,
1683        **kwargs
1684    ):
1685        super(PipelineRunTargetProperties, self).__init__(**kwargs)
1686        self.type = kwargs.get('type', "AzureStorageBlob")
1687        self.name = kwargs.get('name', None)
1688
1689
1690class PipelineSourceTriggerDescriptor(msrest.serialization.Model):
1691    """PipelineSourceTriggerDescriptor.
1692
1693    :param timestamp: The timestamp when the source update happened.
1694    :type timestamp: ~datetime.datetime
1695    """
1696
1697    _attribute_map = {
1698        'timestamp': {'key': 'timestamp', 'type': 'iso-8601'},
1699    }
1700
1701    def __init__(
1702        self,
1703        **kwargs
1704    ):
1705        super(PipelineSourceTriggerDescriptor, self).__init__(**kwargs)
1706        self.timestamp = kwargs.get('timestamp', None)
1707
1708
1709class PipelineSourceTriggerProperties(msrest.serialization.Model):
1710    """PipelineSourceTriggerProperties.
1711
1712    All required parameters must be populated in order to send to Azure.
1713
1714    :param status: Required. The current status of the source trigger. Possible values include:
1715     "Enabled", "Disabled". Default value: "Enabled".
1716    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TriggerStatus
1717    """
1718
1719    _validation = {
1720        'status': {'required': True},
1721    }
1722
1723    _attribute_map = {
1724        'status': {'key': 'status', 'type': 'str'},
1725    }
1726
1727    def __init__(
1728        self,
1729        **kwargs
1730    ):
1731        super(PipelineSourceTriggerProperties, self).__init__(**kwargs)
1732        self.status = kwargs.get('status', "Enabled")
1733
1734
1735class PipelineTriggerDescriptor(msrest.serialization.Model):
1736    """PipelineTriggerDescriptor.
1737
1738    :param source_trigger: The source trigger that caused the pipeline run.
1739    :type source_trigger:
1740     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineSourceTriggerDescriptor
1741    """
1742
1743    _attribute_map = {
1744        'source_trigger': {'key': 'sourceTrigger', 'type': 'PipelineSourceTriggerDescriptor'},
1745    }
1746
1747    def __init__(
1748        self,
1749        **kwargs
1750    ):
1751        super(PipelineTriggerDescriptor, self).__init__(**kwargs)
1752        self.source_trigger = kwargs.get('source_trigger', None)
1753
1754
1755class PipelineTriggerProperties(msrest.serialization.Model):
1756    """PipelineTriggerProperties.
1757
1758    :param source_trigger: The source trigger properties of the pipeline.
1759    :type source_trigger:
1760     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PipelineSourceTriggerProperties
1761    """
1762
1763    _attribute_map = {
1764        'source_trigger': {'key': 'sourceTrigger', 'type': 'PipelineSourceTriggerProperties'},
1765    }
1766
1767    def __init__(
1768        self,
1769        **kwargs
1770    ):
1771        super(PipelineTriggerProperties, self).__init__(**kwargs)
1772        self.source_trigger = kwargs.get('source_trigger', None)
1773
1774
1775class Policies(msrest.serialization.Model):
1776    """The policies for a container registry.
1777
1778    :param quarantine_policy: The quarantine policy for a container registry.
1779    :type quarantine_policy:
1780     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.QuarantinePolicy
1781    :param trust_policy: The content trust policy for a container registry.
1782    :type trust_policy: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TrustPolicy
1783    :param retention_policy: The retention policy for a container registry.
1784    :type retention_policy:
1785     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.RetentionPolicy
1786    :param export_policy: The export policy for a container registry.
1787    :type export_policy: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ExportPolicy
1788    """
1789
1790    _attribute_map = {
1791        'quarantine_policy': {'key': 'quarantinePolicy', 'type': 'QuarantinePolicy'},
1792        'trust_policy': {'key': 'trustPolicy', 'type': 'TrustPolicy'},
1793        'retention_policy': {'key': 'retentionPolicy', 'type': 'RetentionPolicy'},
1794        'export_policy': {'key': 'exportPolicy', 'type': 'ExportPolicy'},
1795    }
1796
1797    def __init__(
1798        self,
1799        **kwargs
1800    ):
1801        super(Policies, self).__init__(**kwargs)
1802        self.quarantine_policy = kwargs.get('quarantine_policy', None)
1803        self.trust_policy = kwargs.get('trust_policy', None)
1804        self.retention_policy = kwargs.get('retention_policy', None)
1805        self.export_policy = kwargs.get('export_policy', None)
1806
1807
1808class PrivateEndpoint(msrest.serialization.Model):
1809    """The Private Endpoint resource.
1810
1811    :param id: This is private endpoint resource created with Microsoft.Network resource provider.
1812    :type id: str
1813    """
1814
1815    _attribute_map = {
1816        'id': {'key': 'id', 'type': 'str'},
1817    }
1818
1819    def __init__(
1820        self,
1821        **kwargs
1822    ):
1823        super(PrivateEndpoint, self).__init__(**kwargs)
1824        self.id = kwargs.get('id', None)
1825
1826
1827class PrivateEndpointConnection(ProxyResource):
1828    """An object that represents a private endpoint connection for a container registry.
1829
1830    Variables are only populated by the server, and will be ignored when sending a request.
1831
1832    :ivar id: The resource ID.
1833    :vartype id: str
1834    :ivar name: The name of the resource.
1835    :vartype name: str
1836    :ivar type: The type of the resource.
1837    :vartype type: str
1838    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
1839    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
1840    :param private_endpoint: The resource of private endpoint.
1841    :type private_endpoint:
1842     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PrivateEndpoint
1843    :param private_link_service_connection_state: A collection of information about the state of
1844     the connection between service consumer and provider.
1845    :type private_link_service_connection_state:
1846     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PrivateLinkServiceConnectionState
1847    :ivar provisioning_state: The provisioning state of private endpoint connection resource.
1848     Possible values include: "Creating", "Updating", "Deleting", "Succeeded", "Failed", "Canceled".
1849    :vartype provisioning_state: str or
1850     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
1851    """
1852
1853    _validation = {
1854        'id': {'readonly': True},
1855        'name': {'readonly': True},
1856        'type': {'readonly': True},
1857        'system_data': {'readonly': True},
1858        'provisioning_state': {'readonly': True},
1859    }
1860
1861    _attribute_map = {
1862        'id': {'key': 'id', 'type': 'str'},
1863        'name': {'key': 'name', 'type': 'str'},
1864        'type': {'key': 'type', 'type': 'str'},
1865        'system_data': {'key': 'systemData', 'type': 'SystemData'},
1866        'private_endpoint': {'key': 'properties.privateEndpoint', 'type': 'PrivateEndpoint'},
1867        'private_link_service_connection_state': {'key': 'properties.privateLinkServiceConnectionState', 'type': 'PrivateLinkServiceConnectionState'},
1868        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
1869    }
1870
1871    def __init__(
1872        self,
1873        **kwargs
1874    ):
1875        super(PrivateEndpointConnection, self).__init__(**kwargs)
1876        self.private_endpoint = kwargs.get('private_endpoint', None)
1877        self.private_link_service_connection_state = kwargs.get('private_link_service_connection_state', None)
1878        self.provisioning_state = None
1879
1880
1881class PrivateEndpointConnectionListResult(msrest.serialization.Model):
1882    """The result of a request to list private endpoint connections for a container registry.
1883
1884    :param value: The list of private endpoint connections. Since this list may be incomplete, the
1885     nextLink field should be used to request the next list of private endpoint connections.
1886    :type value:
1887     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.PrivateEndpointConnection]
1888    :param next_link: The URI that can be used to request the next list of private endpoint
1889     connections.
1890    :type next_link: str
1891    """
1892
1893    _attribute_map = {
1894        'value': {'key': 'value', 'type': '[PrivateEndpointConnection]'},
1895        'next_link': {'key': 'nextLink', 'type': 'str'},
1896    }
1897
1898    def __init__(
1899        self,
1900        **kwargs
1901    ):
1902        super(PrivateEndpointConnectionListResult, self).__init__(**kwargs)
1903        self.value = kwargs.get('value', None)
1904        self.next_link = kwargs.get('next_link', None)
1905
1906
1907class PrivateLinkResource(msrest.serialization.Model):
1908    """A resource that supports private link capabilities.
1909
1910    Variables are only populated by the server, and will be ignored when sending a request.
1911
1912    :ivar type: The resource type is private link resource.
1913    :vartype type: str
1914    :param id: The resource ID.
1915    :type id: str
1916    :param name: The name of the resource.
1917    :type name: str
1918    :param group_id: The private link resource group id.
1919    :type group_id: str
1920    :param required_members: The private link resource required member names.
1921    :type required_members: list[str]
1922    :param required_zone_names: The private link resource Private link DNS zone name.
1923    :type required_zone_names: list[str]
1924    """
1925
1926    _validation = {
1927        'type': {'readonly': True},
1928    }
1929
1930    _attribute_map = {
1931        'type': {'key': 'type', 'type': 'str'},
1932        'id': {'key': 'id', 'type': 'str'},
1933        'name': {'key': 'name', 'type': 'str'},
1934        'group_id': {'key': 'properties.groupId', 'type': 'str'},
1935        'required_members': {'key': 'properties.requiredMembers', 'type': '[str]'},
1936        'required_zone_names': {'key': 'properties.requiredZoneNames', 'type': '[str]'},
1937    }
1938
1939    def __init__(
1940        self,
1941        **kwargs
1942    ):
1943        super(PrivateLinkResource, self).__init__(**kwargs)
1944        self.type = None
1945        self.id = kwargs.get('id', None)
1946        self.name = kwargs.get('name', None)
1947        self.group_id = kwargs.get('group_id', None)
1948        self.required_members = kwargs.get('required_members', None)
1949        self.required_zone_names = kwargs.get('required_zone_names', None)
1950
1951
1952class PrivateLinkResourceListResult(msrest.serialization.Model):
1953    """The result of a request to list private link resources for a container registry.
1954
1955    :param value: The list of private link resources. Since this list may be incomplete, the
1956     nextLink field should be used to request the next list of private link resources.
1957    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.PrivateLinkResource]
1958    :param next_link: The URI that can be used to request the next list of private link resources.
1959    :type next_link: str
1960    """
1961
1962    _attribute_map = {
1963        'value': {'key': 'value', 'type': '[PrivateLinkResource]'},
1964        'next_link': {'key': 'nextLink', 'type': 'str'},
1965    }
1966
1967    def __init__(
1968        self,
1969        **kwargs
1970    ):
1971        super(PrivateLinkResourceListResult, self).__init__(**kwargs)
1972        self.value = kwargs.get('value', None)
1973        self.next_link = kwargs.get('next_link', None)
1974
1975
1976class PrivateLinkServiceConnectionState(msrest.serialization.Model):
1977    """The state of a private link service connection.
1978
1979    :param status: The private link service connection status. Possible values include: "Approved",
1980     "Pending", "Rejected", "Disconnected".
1981    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ConnectionStatus
1982    :param description: The description for connection status. For example if connection is
1983     rejected it can indicate reason for rejection.
1984    :type description: str
1985    :param actions_required: A message indicating if changes on the service provider require any
1986     updates on the consumer. Possible values include: "None", "Recreate".
1987    :type actions_required: str or
1988     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ActionsRequired
1989    """
1990
1991    _attribute_map = {
1992        'status': {'key': 'status', 'type': 'str'},
1993        'description': {'key': 'description', 'type': 'str'},
1994        'actions_required': {'key': 'actionsRequired', 'type': 'str'},
1995    }
1996
1997    def __init__(
1998        self,
1999        **kwargs
2000    ):
2001        super(PrivateLinkServiceConnectionState, self).__init__(**kwargs)
2002        self.status = kwargs.get('status', None)
2003        self.description = kwargs.get('description', None)
2004        self.actions_required = kwargs.get('actions_required', None)
2005
2006
2007class ProgressProperties(msrest.serialization.Model):
2008    """ProgressProperties.
2009
2010    :param percentage: The percentage complete of the copy operation.
2011    :type percentage: str
2012    """
2013
2014    _attribute_map = {
2015        'percentage': {'key': 'percentage', 'type': 'str'},
2016    }
2017
2018    def __init__(
2019        self,
2020        **kwargs
2021    ):
2022        super(ProgressProperties, self).__init__(**kwargs)
2023        self.percentage = kwargs.get('percentage', None)
2024
2025
2026class QuarantinePolicy(msrest.serialization.Model):
2027    """The quarantine policy for a container registry.
2028
2029    :param status: The value that indicates whether the policy is enabled or not. Possible values
2030     include: "enabled", "disabled".
2031    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PolicyStatus
2032    """
2033
2034    _attribute_map = {
2035        'status': {'key': 'status', 'type': 'str'},
2036    }
2037
2038    def __init__(
2039        self,
2040        **kwargs
2041    ):
2042        super(QuarantinePolicy, self).__init__(**kwargs)
2043        self.status = kwargs.get('status', None)
2044
2045
2046class RegenerateCredentialParameters(msrest.serialization.Model):
2047    """The parameters used to regenerate the login credential.
2048
2049    All required parameters must be populated in order to send to Azure.
2050
2051    :param name: Required. Specifies name of the password which should be regenerated -- password
2052     or password2. Possible values include: "password", "password2".
2053    :type name: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PasswordName
2054    """
2055
2056    _validation = {
2057        'name': {'required': True},
2058    }
2059
2060    _attribute_map = {
2061        'name': {'key': 'name', 'type': 'str'},
2062    }
2063
2064    def __init__(
2065        self,
2066        **kwargs
2067    ):
2068        super(RegenerateCredentialParameters, self).__init__(**kwargs)
2069        self.name = kwargs['name']
2070
2071
2072class Resource(msrest.serialization.Model):
2073    """An Azure resource.
2074
2075    Variables are only populated by the server, and will be ignored when sending a request.
2076
2077    All required parameters must be populated in order to send to Azure.
2078
2079    :ivar id: The resource ID.
2080    :vartype id: str
2081    :ivar name: The name of the resource.
2082    :vartype name: str
2083    :ivar type: The type of the resource.
2084    :vartype type: str
2085    :param location: Required. The location of the resource. This cannot be changed after the
2086     resource is created.
2087    :type location: str
2088    :param tags: A set of tags. The tags of the resource.
2089    :type tags: dict[str, str]
2090    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
2091    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
2092    """
2093
2094    _validation = {
2095        'id': {'readonly': True},
2096        'name': {'readonly': True},
2097        'type': {'readonly': True},
2098        'location': {'required': True},
2099        'system_data': {'readonly': True},
2100    }
2101
2102    _attribute_map = {
2103        'id': {'key': 'id', 'type': 'str'},
2104        'name': {'key': 'name', 'type': 'str'},
2105        'type': {'key': 'type', 'type': 'str'},
2106        'location': {'key': 'location', 'type': 'str'},
2107        'tags': {'key': 'tags', 'type': '{str}'},
2108        'system_data': {'key': 'systemData', 'type': 'SystemData'},
2109    }
2110
2111    def __init__(
2112        self,
2113        **kwargs
2114    ):
2115        super(Resource, self).__init__(**kwargs)
2116        self.id = None
2117        self.name = None
2118        self.type = None
2119        self.location = kwargs['location']
2120        self.tags = kwargs.get('tags', None)
2121        self.system_data = None
2122
2123
2124class Registry(Resource):
2125    """An object that represents a container registry.
2126
2127    Variables are only populated by the server, and will be ignored when sending a request.
2128
2129    All required parameters must be populated in order to send to Azure.
2130
2131    :ivar id: The resource ID.
2132    :vartype id: str
2133    :ivar name: The name of the resource.
2134    :vartype name: str
2135    :ivar type: The type of the resource.
2136    :vartype type: str
2137    :param location: Required. The location of the resource. This cannot be changed after the
2138     resource is created.
2139    :type location: str
2140    :param tags: A set of tags. The tags of the resource.
2141    :type tags: dict[str, str]
2142    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
2143    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
2144    :param sku: Required. The SKU of the container registry.
2145    :type sku: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Sku
2146    :param identity: The identity of the container registry.
2147    :type identity: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.IdentityProperties
2148    :ivar login_server: The URL that can be used to log into the container registry.
2149    :vartype login_server: str
2150    :ivar creation_date: The creation date of the container registry in ISO8601 format.
2151    :vartype creation_date: ~datetime.datetime
2152    :ivar provisioning_state: The provisioning state of the container registry at the time the
2153     operation was called. Possible values include: "Creating", "Updating", "Deleting", "Succeeded",
2154     "Failed", "Canceled".
2155    :vartype provisioning_state: str or
2156     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
2157    :ivar status: The status of the container registry at the time the operation was called.
2158    :vartype status: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Status
2159    :param admin_user_enabled: The value that indicates whether the admin user is enabled.
2160    :type admin_user_enabled: bool
2161    :param network_rule_set: The network rule set for a container registry.
2162    :type network_rule_set: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.NetworkRuleSet
2163    :param policies: The policies for a container registry.
2164    :type policies: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Policies
2165    :param encryption: The encryption settings of container registry.
2166    :type encryption: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.EncryptionProperty
2167    :param data_endpoint_enabled: Enable a single data endpoint per region for serving data.
2168    :type data_endpoint_enabled: bool
2169    :ivar data_endpoint_host_names: List of host names that will serve data when
2170     dataEndpointEnabled is true.
2171    :vartype data_endpoint_host_names: list[str]
2172    :ivar private_endpoint_connections: List of private endpoint connections for a container
2173     registry.
2174    :vartype private_endpoint_connections:
2175     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.PrivateEndpointConnection]
2176    :param public_network_access: Whether or not public network access is allowed for the container
2177     registry. Possible values include: "Enabled", "Disabled".
2178    :type public_network_access: str or
2179     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PublicNetworkAccess
2180    :param network_rule_bypass_options: Whether to allow trusted Azure services to access a network
2181     restricted registry. Possible values include: "AzureServices", "None".
2182    :type network_rule_bypass_options: str or
2183     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.NetworkRuleBypassOptions
2184    :param zone_redundancy: Whether or not zone redundancy is enabled for this container registry.
2185     Possible values include: "Enabled", "Disabled".
2186    :type zone_redundancy: str or
2187     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ZoneRedundancy
2188    :param anonymous_pull_enabled: Enables registry-wide pull from unauthenticated clients.
2189    :type anonymous_pull_enabled: bool
2190    """
2191
2192    _validation = {
2193        'id': {'readonly': True},
2194        'name': {'readonly': True},
2195        'type': {'readonly': True},
2196        'location': {'required': True},
2197        'system_data': {'readonly': True},
2198        'sku': {'required': True},
2199        'login_server': {'readonly': True},
2200        'creation_date': {'readonly': True},
2201        'provisioning_state': {'readonly': True},
2202        'status': {'readonly': True},
2203        'data_endpoint_host_names': {'readonly': True},
2204        'private_endpoint_connections': {'readonly': True},
2205    }
2206
2207    _attribute_map = {
2208        'id': {'key': 'id', 'type': 'str'},
2209        'name': {'key': 'name', 'type': 'str'},
2210        'type': {'key': 'type', 'type': 'str'},
2211        'location': {'key': 'location', 'type': 'str'},
2212        'tags': {'key': 'tags', 'type': '{str}'},
2213        'system_data': {'key': 'systemData', 'type': 'SystemData'},
2214        'sku': {'key': 'sku', 'type': 'Sku'},
2215        'identity': {'key': 'identity', 'type': 'IdentityProperties'},
2216        'login_server': {'key': 'properties.loginServer', 'type': 'str'},
2217        'creation_date': {'key': 'properties.creationDate', 'type': 'iso-8601'},
2218        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
2219        'status': {'key': 'properties.status', 'type': 'Status'},
2220        'admin_user_enabled': {'key': 'properties.adminUserEnabled', 'type': 'bool'},
2221        'network_rule_set': {'key': 'properties.networkRuleSet', 'type': 'NetworkRuleSet'},
2222        'policies': {'key': 'properties.policies', 'type': 'Policies'},
2223        'encryption': {'key': 'properties.encryption', 'type': 'EncryptionProperty'},
2224        'data_endpoint_enabled': {'key': 'properties.dataEndpointEnabled', 'type': 'bool'},
2225        'data_endpoint_host_names': {'key': 'properties.dataEndpointHostNames', 'type': '[str]'},
2226        'private_endpoint_connections': {'key': 'properties.privateEndpointConnections', 'type': '[PrivateEndpointConnection]'},
2227        'public_network_access': {'key': 'properties.publicNetworkAccess', 'type': 'str'},
2228        'network_rule_bypass_options': {'key': 'properties.networkRuleBypassOptions', 'type': 'str'},
2229        'zone_redundancy': {'key': 'properties.zoneRedundancy', 'type': 'str'},
2230        'anonymous_pull_enabled': {'key': 'properties.anonymousPullEnabled', 'type': 'bool'},
2231    }
2232
2233    def __init__(
2234        self,
2235        **kwargs
2236    ):
2237        super(Registry, self).__init__(**kwargs)
2238        self.sku = kwargs['sku']
2239        self.identity = kwargs.get('identity', None)
2240        self.login_server = None
2241        self.creation_date = None
2242        self.provisioning_state = None
2243        self.status = None
2244        self.admin_user_enabled = kwargs.get('admin_user_enabled', False)
2245        self.network_rule_set = kwargs.get('network_rule_set', None)
2246        self.policies = kwargs.get('policies', None)
2247        self.encryption = kwargs.get('encryption', None)
2248        self.data_endpoint_enabled = kwargs.get('data_endpoint_enabled', None)
2249        self.data_endpoint_host_names = None
2250        self.private_endpoint_connections = None
2251        self.public_network_access = kwargs.get('public_network_access', None)
2252        self.network_rule_bypass_options = kwargs.get('network_rule_bypass_options', None)
2253        self.zone_redundancy = kwargs.get('zone_redundancy', None)
2254        self.anonymous_pull_enabled = kwargs.get('anonymous_pull_enabled', False)
2255
2256
2257class RegistryListCredentialsResult(msrest.serialization.Model):
2258    """The response from the ListCredentials operation.
2259
2260    :param username: The username for a container registry.
2261    :type username: str
2262    :param passwords: The list of passwords for a container registry.
2263    :type passwords:
2264     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.RegistryPassword]
2265    """
2266
2267    _attribute_map = {
2268        'username': {'key': 'username', 'type': 'str'},
2269        'passwords': {'key': 'passwords', 'type': '[RegistryPassword]'},
2270    }
2271
2272    def __init__(
2273        self,
2274        **kwargs
2275    ):
2276        super(RegistryListCredentialsResult, self).__init__(**kwargs)
2277        self.username = kwargs.get('username', None)
2278        self.passwords = kwargs.get('passwords', None)
2279
2280
2281class RegistryListResult(msrest.serialization.Model):
2282    """The result of a request to list container registries.
2283
2284    :param value: The list of container registries. Since this list may be incomplete, the nextLink
2285     field should be used to request the next list of container registries.
2286    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.Registry]
2287    :param next_link: The URI that can be used to request the next list of container registries.
2288    :type next_link: str
2289    """
2290
2291    _attribute_map = {
2292        'value': {'key': 'value', 'type': '[Registry]'},
2293        'next_link': {'key': 'nextLink', 'type': 'str'},
2294    }
2295
2296    def __init__(
2297        self,
2298        **kwargs
2299    ):
2300        super(RegistryListResult, self).__init__(**kwargs)
2301        self.value = kwargs.get('value', None)
2302        self.next_link = kwargs.get('next_link', None)
2303
2304
2305class RegistryNameCheckRequest(msrest.serialization.Model):
2306    """A request to check whether a container registry name is available.
2307
2308    Variables are only populated by the server, and will be ignored when sending a request.
2309
2310    All required parameters must be populated in order to send to Azure.
2311
2312    :param name: Required. The name of the container registry.
2313    :type name: str
2314    :ivar type: The resource type of the container registry. This field must be set to
2315     'Microsoft.ContainerRegistry/registries'. Has constant value:
2316     "Microsoft.ContainerRegistry/registries".
2317    :vartype type: str
2318    """
2319
2320    _validation = {
2321        'name': {'required': True, 'max_length': 50, 'min_length': 5, 'pattern': r'^[a-zA-Z0-9]*$'},
2322        'type': {'required': True, 'constant': True},
2323    }
2324
2325    _attribute_map = {
2326        'name': {'key': 'name', 'type': 'str'},
2327        'type': {'key': 'type', 'type': 'str'},
2328    }
2329
2330    type = "Microsoft.ContainerRegistry/registries"
2331
2332    def __init__(
2333        self,
2334        **kwargs
2335    ):
2336        super(RegistryNameCheckRequest, self).__init__(**kwargs)
2337        self.name = kwargs['name']
2338
2339
2340class RegistryNameStatus(msrest.serialization.Model):
2341    """The result of a request to check the availability of a container registry name.
2342
2343    :param name_available: The value that indicates whether the name is available.
2344    :type name_available: bool
2345    :param reason: If any, the reason that the name is not available.
2346    :type reason: str
2347    :param message: If any, the error message that provides more detail for the reason that the
2348     name is not available.
2349    :type message: str
2350    """
2351
2352    _attribute_map = {
2353        'name_available': {'key': 'nameAvailable', 'type': 'bool'},
2354        'reason': {'key': 'reason', 'type': 'str'},
2355        'message': {'key': 'message', 'type': 'str'},
2356    }
2357
2358    def __init__(
2359        self,
2360        **kwargs
2361    ):
2362        super(RegistryNameStatus, self).__init__(**kwargs)
2363        self.name_available = kwargs.get('name_available', None)
2364        self.reason = kwargs.get('reason', None)
2365        self.message = kwargs.get('message', None)
2366
2367
2368class RegistryPassword(msrest.serialization.Model):
2369    """The login password for the container registry.
2370
2371    :param name: The password name. Possible values include: "password", "password2".
2372    :type name: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PasswordName
2373    :param value: The password value.
2374    :type value: str
2375    """
2376
2377    _attribute_map = {
2378        'name': {'key': 'name', 'type': 'str'},
2379        'value': {'key': 'value', 'type': 'str'},
2380    }
2381
2382    def __init__(
2383        self,
2384        **kwargs
2385    ):
2386        super(RegistryPassword, self).__init__(**kwargs)
2387        self.name = kwargs.get('name', None)
2388        self.value = kwargs.get('value', None)
2389
2390
2391class RegistryUpdateParameters(msrest.serialization.Model):
2392    """The parameters for updating a container registry.
2393
2394    :param identity: The identity of the container registry.
2395    :type identity: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.IdentityProperties
2396    :param tags: A set of tags. The tags for the container registry.
2397    :type tags: dict[str, str]
2398    :param sku: The SKU of the container registry.
2399    :type sku: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Sku
2400    :param admin_user_enabled: The value that indicates whether the admin user is enabled.
2401    :type admin_user_enabled: bool
2402    :param network_rule_set: The network rule set for a container registry.
2403    :type network_rule_set: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.NetworkRuleSet
2404    :param policies: The policies for a container registry.
2405    :type policies: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Policies
2406    :param encryption: The encryption settings of container registry.
2407    :type encryption: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.EncryptionProperty
2408    :param data_endpoint_enabled: Enable a single data endpoint per region for serving data.
2409    :type data_endpoint_enabled: bool
2410    :param public_network_access: Whether or not public network access is allowed for the container
2411     registry. Possible values include: "Enabled", "Disabled".
2412    :type public_network_access: str or
2413     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PublicNetworkAccess
2414    :param network_rule_bypass_options: Whether to allow trusted Azure services to access a network
2415     restricted registry. Possible values include: "AzureServices", "None".
2416    :type network_rule_bypass_options: str or
2417     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.NetworkRuleBypassOptions
2418    :param anonymous_pull_enabled: Enables registry-wide pull from unauthenticated clients.
2419    :type anonymous_pull_enabled: bool
2420    """
2421
2422    _attribute_map = {
2423        'identity': {'key': 'identity', 'type': 'IdentityProperties'},
2424        'tags': {'key': 'tags', 'type': '{str}'},
2425        'sku': {'key': 'sku', 'type': 'Sku'},
2426        'admin_user_enabled': {'key': 'properties.adminUserEnabled', 'type': 'bool'},
2427        'network_rule_set': {'key': 'properties.networkRuleSet', 'type': 'NetworkRuleSet'},
2428        'policies': {'key': 'properties.policies', 'type': 'Policies'},
2429        'encryption': {'key': 'properties.encryption', 'type': 'EncryptionProperty'},
2430        'data_endpoint_enabled': {'key': 'properties.dataEndpointEnabled', 'type': 'bool'},
2431        'public_network_access': {'key': 'properties.publicNetworkAccess', 'type': 'str'},
2432        'network_rule_bypass_options': {'key': 'properties.networkRuleBypassOptions', 'type': 'str'},
2433        'anonymous_pull_enabled': {'key': 'properties.anonymousPullEnabled', 'type': 'bool'},
2434    }
2435
2436    def __init__(
2437        self,
2438        **kwargs
2439    ):
2440        super(RegistryUpdateParameters, self).__init__(**kwargs)
2441        self.identity = kwargs.get('identity', None)
2442        self.tags = kwargs.get('tags', None)
2443        self.sku = kwargs.get('sku', None)
2444        self.admin_user_enabled = kwargs.get('admin_user_enabled', None)
2445        self.network_rule_set = kwargs.get('network_rule_set', None)
2446        self.policies = kwargs.get('policies', None)
2447        self.encryption = kwargs.get('encryption', None)
2448        self.data_endpoint_enabled = kwargs.get('data_endpoint_enabled', None)
2449        self.public_network_access = kwargs.get('public_network_access', None)
2450        self.network_rule_bypass_options = kwargs.get('network_rule_bypass_options', None)
2451        self.anonymous_pull_enabled = kwargs.get('anonymous_pull_enabled', None)
2452
2453
2454class RegistryUsage(msrest.serialization.Model):
2455    """The quota usage for a container registry.
2456
2457    :param name: The name of the usage.
2458    :type name: str
2459    :param limit: The limit of the usage.
2460    :type limit: long
2461    :param current_value: The current value of the usage.
2462    :type current_value: long
2463    :param unit: The unit of measurement. Possible values include: "Count", "Bytes".
2464    :type unit: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.RegistryUsageUnit
2465    """
2466
2467    _attribute_map = {
2468        'name': {'key': 'name', 'type': 'str'},
2469        'limit': {'key': 'limit', 'type': 'long'},
2470        'current_value': {'key': 'currentValue', 'type': 'long'},
2471        'unit': {'key': 'unit', 'type': 'str'},
2472    }
2473
2474    def __init__(
2475        self,
2476        **kwargs
2477    ):
2478        super(RegistryUsage, self).__init__(**kwargs)
2479        self.name = kwargs.get('name', None)
2480        self.limit = kwargs.get('limit', None)
2481        self.current_value = kwargs.get('current_value', None)
2482        self.unit = kwargs.get('unit', None)
2483
2484
2485class RegistryUsageListResult(msrest.serialization.Model):
2486    """The result of a request to get container registry quota usages.
2487
2488    :param value: The list of container registry quota usages.
2489    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.RegistryUsage]
2490    """
2491
2492    _attribute_map = {
2493        'value': {'key': 'value', 'type': '[RegistryUsage]'},
2494    }
2495
2496    def __init__(
2497        self,
2498        **kwargs
2499    ):
2500        super(RegistryUsageListResult, self).__init__(**kwargs)
2501        self.value = kwargs.get('value', None)
2502
2503
2504class Replication(Resource):
2505    """An object that represents a replication for a container registry.
2506
2507    Variables are only populated by the server, and will be ignored when sending a request.
2508
2509    All required parameters must be populated in order to send to Azure.
2510
2511    :ivar id: The resource ID.
2512    :vartype id: str
2513    :ivar name: The name of the resource.
2514    :vartype name: str
2515    :ivar type: The type of the resource.
2516    :vartype type: str
2517    :param location: Required. The location of the resource. This cannot be changed after the
2518     resource is created.
2519    :type location: str
2520    :param tags: A set of tags. The tags of the resource.
2521    :type tags: dict[str, str]
2522    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
2523    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
2524    :ivar provisioning_state: The provisioning state of the replication at the time the operation
2525     was called. Possible values include: "Creating", "Updating", "Deleting", "Succeeded", "Failed",
2526     "Canceled".
2527    :vartype provisioning_state: str or
2528     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
2529    :ivar status: The status of the replication at the time the operation was called.
2530    :vartype status: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Status
2531    :param region_endpoint_enabled: Specifies whether the replication's regional endpoint is
2532     enabled. Requests will not be routed to a replication whose regional endpoint is disabled,
2533     however its data will continue to be synced with other replications.
2534    :type region_endpoint_enabled: bool
2535    :param zone_redundancy: Whether or not zone redundancy is enabled for this container registry
2536     replication. Possible values include: "Enabled", "Disabled".
2537    :type zone_redundancy: str or
2538     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ZoneRedundancy
2539    """
2540
2541    _validation = {
2542        'id': {'readonly': True},
2543        'name': {'readonly': True},
2544        'type': {'readonly': True},
2545        'location': {'required': True},
2546        'system_data': {'readonly': True},
2547        'provisioning_state': {'readonly': True},
2548        'status': {'readonly': True},
2549    }
2550
2551    _attribute_map = {
2552        'id': {'key': 'id', 'type': 'str'},
2553        'name': {'key': 'name', 'type': 'str'},
2554        'type': {'key': 'type', 'type': 'str'},
2555        'location': {'key': 'location', 'type': 'str'},
2556        'tags': {'key': 'tags', 'type': '{str}'},
2557        'system_data': {'key': 'systemData', 'type': 'SystemData'},
2558        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
2559        'status': {'key': 'properties.status', 'type': 'Status'},
2560        'region_endpoint_enabled': {'key': 'properties.regionEndpointEnabled', 'type': 'bool'},
2561        'zone_redundancy': {'key': 'properties.zoneRedundancy', 'type': 'str'},
2562    }
2563
2564    def __init__(
2565        self,
2566        **kwargs
2567    ):
2568        super(Replication, self).__init__(**kwargs)
2569        self.provisioning_state = None
2570        self.status = None
2571        self.region_endpoint_enabled = kwargs.get('region_endpoint_enabled', True)
2572        self.zone_redundancy = kwargs.get('zone_redundancy', None)
2573
2574
2575class ReplicationListResult(msrest.serialization.Model):
2576    """The result of a request to list replications for a container registry.
2577
2578    :param value: The list of replications. Since this list may be incomplete, the nextLink field
2579     should be used to request the next list of replications.
2580    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.Replication]
2581    :param next_link: The URI that can be used to request the next list of replications.
2582    :type next_link: str
2583    """
2584
2585    _attribute_map = {
2586        'value': {'key': 'value', 'type': '[Replication]'},
2587        'next_link': {'key': 'nextLink', 'type': 'str'},
2588    }
2589
2590    def __init__(
2591        self,
2592        **kwargs
2593    ):
2594        super(ReplicationListResult, self).__init__(**kwargs)
2595        self.value = kwargs.get('value', None)
2596        self.next_link = kwargs.get('next_link', None)
2597
2598
2599class ReplicationUpdateParameters(msrest.serialization.Model):
2600    """The parameters for updating a replication.
2601
2602    :param tags: A set of tags. The tags for the replication.
2603    :type tags: dict[str, str]
2604    :param region_endpoint_enabled: Specifies whether the replication's regional endpoint is
2605     enabled. Requests will not be routed to a replication whose regional endpoint is disabled,
2606     however its data will continue to be synced with other replications.
2607    :type region_endpoint_enabled: bool
2608    """
2609
2610    _attribute_map = {
2611        'tags': {'key': 'tags', 'type': '{str}'},
2612        'region_endpoint_enabled': {'key': 'properties.regionEndpointEnabled', 'type': 'bool'},
2613    }
2614
2615    def __init__(
2616        self,
2617        **kwargs
2618    ):
2619        super(ReplicationUpdateParameters, self).__init__(**kwargs)
2620        self.tags = kwargs.get('tags', None)
2621        self.region_endpoint_enabled = kwargs.get('region_endpoint_enabled', None)
2622
2623
2624class Request(msrest.serialization.Model):
2625    """The request that generated the event.
2626
2627    :param id: The ID of the request that initiated the event.
2628    :type id: str
2629    :param addr: The IP or hostname and possibly port of the client connection that initiated the
2630     event. This is the RemoteAddr from the standard http request.
2631    :type addr: str
2632    :param host: The externally accessible hostname of the registry instance, as specified by the
2633     http host header on incoming requests.
2634    :type host: str
2635    :param method: The request method that generated the event.
2636    :type method: str
2637    :param useragent: The user agent header of the request.
2638    :type useragent: str
2639    """
2640
2641    _attribute_map = {
2642        'id': {'key': 'id', 'type': 'str'},
2643        'addr': {'key': 'addr', 'type': 'str'},
2644        'host': {'key': 'host', 'type': 'str'},
2645        'method': {'key': 'method', 'type': 'str'},
2646        'useragent': {'key': 'useragent', 'type': 'str'},
2647    }
2648
2649    def __init__(
2650        self,
2651        **kwargs
2652    ):
2653        super(Request, self).__init__(**kwargs)
2654        self.id = kwargs.get('id', None)
2655        self.addr = kwargs.get('addr', None)
2656        self.host = kwargs.get('host', None)
2657        self.method = kwargs.get('method', None)
2658        self.useragent = kwargs.get('useragent', None)
2659
2660
2661class RetentionPolicy(msrest.serialization.Model):
2662    """The retention policy for a container registry.
2663
2664    Variables are only populated by the server, and will be ignored when sending a request.
2665
2666    :param days: The number of days to retain an untagged manifest after which it gets purged.
2667    :type days: int
2668    :ivar last_updated_time: The timestamp when the policy was last updated.
2669    :vartype last_updated_time: ~datetime.datetime
2670    :param status: The value that indicates whether the policy is enabled or not. Possible values
2671     include: "enabled", "disabled".
2672    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PolicyStatus
2673    """
2674
2675    _validation = {
2676        'last_updated_time': {'readonly': True},
2677    }
2678
2679    _attribute_map = {
2680        'days': {'key': 'days', 'type': 'int'},
2681        'last_updated_time': {'key': 'lastUpdatedTime', 'type': 'iso-8601'},
2682        'status': {'key': 'status', 'type': 'str'},
2683    }
2684
2685    def __init__(
2686        self,
2687        **kwargs
2688    ):
2689        super(RetentionPolicy, self).__init__(**kwargs)
2690        self.days = kwargs.get('days', 7)
2691        self.last_updated_time = None
2692        self.status = kwargs.get('status', None)
2693
2694
2695class ScopeMap(ProxyResource):
2696    """An object that represents a scope map for a container registry.
2697
2698    Variables are only populated by the server, and will be ignored when sending a request.
2699
2700    :ivar id: The resource ID.
2701    :vartype id: str
2702    :ivar name: The name of the resource.
2703    :vartype name: str
2704    :ivar type: The type of the resource.
2705    :vartype type: str
2706    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
2707    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
2708    :param description: The user friendly description of the scope map.
2709    :type description: str
2710    :ivar type_properties_type: The type of the scope map. E.g. BuildIn scope map.
2711    :vartype type_properties_type: str
2712    :ivar creation_date: The creation date of scope map.
2713    :vartype creation_date: ~datetime.datetime
2714    :ivar provisioning_state: Provisioning state of the resource. Possible values include:
2715     "Creating", "Updating", "Deleting", "Succeeded", "Failed", "Canceled".
2716    :vartype provisioning_state: str or
2717     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
2718    :param actions: The list of scoped permissions for registry artifacts.
2719     E.g. repositories/repository-name/content/read,
2720     repositories/repository-name/metadata/write.
2721    :type actions: list[str]
2722    """
2723
2724    _validation = {
2725        'id': {'readonly': True},
2726        'name': {'readonly': True},
2727        'type': {'readonly': True},
2728        'system_data': {'readonly': True},
2729        'type_properties_type': {'readonly': True},
2730        'creation_date': {'readonly': True},
2731        'provisioning_state': {'readonly': True},
2732    }
2733
2734    _attribute_map = {
2735        'id': {'key': 'id', 'type': 'str'},
2736        'name': {'key': 'name', 'type': 'str'},
2737        'type': {'key': 'type', 'type': 'str'},
2738        'system_data': {'key': 'systemData', 'type': 'SystemData'},
2739        'description': {'key': 'properties.description', 'type': 'str'},
2740        'type_properties_type': {'key': 'properties.type', 'type': 'str'},
2741        'creation_date': {'key': 'properties.creationDate', 'type': 'iso-8601'},
2742        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
2743        'actions': {'key': 'properties.actions', 'type': '[str]'},
2744    }
2745
2746    def __init__(
2747        self,
2748        **kwargs
2749    ):
2750        super(ScopeMap, self).__init__(**kwargs)
2751        self.description = kwargs.get('description', None)
2752        self.type_properties_type = None
2753        self.creation_date = None
2754        self.provisioning_state = None
2755        self.actions = kwargs.get('actions', None)
2756
2757
2758class ScopeMapListResult(msrest.serialization.Model):
2759    """The result of a request to list scope maps for a container registry.
2760
2761    :param value: The list of scope maps. Since this list may be incomplete, the nextLink field
2762     should be used to request the next list of scope maps.
2763    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.ScopeMap]
2764    :param next_link: The URI that can be used to request the next list of scope maps.
2765    :type next_link: str
2766    """
2767
2768    _attribute_map = {
2769        'value': {'key': 'value', 'type': '[ScopeMap]'},
2770        'next_link': {'key': 'nextLink', 'type': 'str'},
2771    }
2772
2773    def __init__(
2774        self,
2775        **kwargs
2776    ):
2777        super(ScopeMapListResult, self).__init__(**kwargs)
2778        self.value = kwargs.get('value', None)
2779        self.next_link = kwargs.get('next_link', None)
2780
2781
2782class ScopeMapUpdateParameters(msrest.serialization.Model):
2783    """The properties for updating the scope map.
2784
2785    :param description: The user friendly description of the scope map.
2786    :type description: str
2787    :param actions: The list of scope permissions for registry artifacts.
2788     E.g. repositories/repository-name/pull,
2789     repositories/repository-name/delete.
2790    :type actions: list[str]
2791    """
2792
2793    _attribute_map = {
2794        'description': {'key': 'properties.description', 'type': 'str'},
2795        'actions': {'key': 'properties.actions', 'type': '[str]'},
2796    }
2797
2798    def __init__(
2799        self,
2800        **kwargs
2801    ):
2802        super(ScopeMapUpdateParameters, self).__init__(**kwargs)
2803        self.description = kwargs.get('description', None)
2804        self.actions = kwargs.get('actions', None)
2805
2806
2807class Sku(msrest.serialization.Model):
2808    """The SKU of a container registry.
2809
2810    Variables are only populated by the server, and will be ignored when sending a request.
2811
2812    All required parameters must be populated in order to send to Azure.
2813
2814    :param name: Required. The SKU name of the container registry. Required for registry creation.
2815     Possible values include: "Classic", "Basic", "Standard", "Premium".
2816    :type name: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SkuName
2817    :ivar tier: The SKU tier based on the SKU name. Possible values include: "Classic", "Basic",
2818     "Standard", "Premium".
2819    :vartype tier: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SkuTier
2820    """
2821
2822    _validation = {
2823        'name': {'required': True},
2824        'tier': {'readonly': True},
2825    }
2826
2827    _attribute_map = {
2828        'name': {'key': 'name', 'type': 'str'},
2829        'tier': {'key': 'tier', 'type': 'str'},
2830    }
2831
2832    def __init__(
2833        self,
2834        **kwargs
2835    ):
2836        super(Sku, self).__init__(**kwargs)
2837        self.name = kwargs['name']
2838        self.tier = None
2839
2840
2841class Source(msrest.serialization.Model):
2842    """The registry node that generated the event. Put differently, while the actor initiates the event, the source generates it.
2843
2844    :param addr: The IP or hostname and the port of the registry node that generated the event.
2845     Generally, this will be resolved by os.Hostname() along with the running port.
2846    :type addr: str
2847    :param instance_id: The running instance of an application. Changes after each restart.
2848    :type instance_id: str
2849    """
2850
2851    _attribute_map = {
2852        'addr': {'key': 'addr', 'type': 'str'},
2853        'instance_id': {'key': 'instanceID', 'type': 'str'},
2854    }
2855
2856    def __init__(
2857        self,
2858        **kwargs
2859    ):
2860        super(Source, self).__init__(**kwargs)
2861        self.addr = kwargs.get('addr', None)
2862        self.instance_id = kwargs.get('instance_id', None)
2863
2864
2865class Status(msrest.serialization.Model):
2866    """The status of an Azure resource at the time the operation was called.
2867
2868    Variables are only populated by the server, and will be ignored when sending a request.
2869
2870    :ivar display_status: The short label for the status.
2871    :vartype display_status: str
2872    :ivar message: The detailed message for the status, including alerts and error messages.
2873    :vartype message: str
2874    :ivar timestamp: The timestamp when the status was changed to the current value.
2875    :vartype timestamp: ~datetime.datetime
2876    """
2877
2878    _validation = {
2879        'display_status': {'readonly': True},
2880        'message': {'readonly': True},
2881        'timestamp': {'readonly': True},
2882    }
2883
2884    _attribute_map = {
2885        'display_status': {'key': 'displayStatus', 'type': 'str'},
2886        'message': {'key': 'message', 'type': 'str'},
2887        'timestamp': {'key': 'timestamp', 'type': 'iso-8601'},
2888    }
2889
2890    def __init__(
2891        self,
2892        **kwargs
2893    ):
2894        super(Status, self).__init__(**kwargs)
2895        self.display_status = None
2896        self.message = None
2897        self.timestamp = None
2898
2899
2900class StatusDetailProperties(msrest.serialization.Model):
2901    """The status detail properties of the connected registry.
2902
2903    Variables are only populated by the server, and will be ignored when sending a request.
2904
2905    :ivar type: The component of the connected registry corresponding to the status.
2906    :vartype type: str
2907    :ivar code: The code of the status.
2908    :vartype code: str
2909    :ivar description: The description of the status.
2910    :vartype description: str
2911    :ivar timestamp: The timestamp of the status.
2912    :vartype timestamp: ~datetime.datetime
2913    :ivar correlation_id: The correlation ID of the status.
2914    :vartype correlation_id: str
2915    """
2916
2917    _validation = {
2918        'type': {'readonly': True},
2919        'code': {'readonly': True},
2920        'description': {'readonly': True},
2921        'timestamp': {'readonly': True},
2922        'correlation_id': {'readonly': True},
2923    }
2924
2925    _attribute_map = {
2926        'type': {'key': 'type', 'type': 'str'},
2927        'code': {'key': 'code', 'type': 'str'},
2928        'description': {'key': 'description', 'type': 'str'},
2929        'timestamp': {'key': 'timestamp', 'type': 'iso-8601'},
2930        'correlation_id': {'key': 'correlationId', 'type': 'str'},
2931    }
2932
2933    def __init__(
2934        self,
2935        **kwargs
2936    ):
2937        super(StatusDetailProperties, self).__init__(**kwargs)
2938        self.type = None
2939        self.code = None
2940        self.description = None
2941        self.timestamp = None
2942        self.correlation_id = None
2943
2944
2945class SyncProperties(msrest.serialization.Model):
2946    """The sync properties of the connected registry with its parent.
2947
2948    Variables are only populated by the server, and will be ignored when sending a request.
2949
2950    All required parameters must be populated in order to send to Azure.
2951
2952    :param token_id: Required. The resource ID of the ACR token used to authenticate the connected
2953     registry to its parent during sync.
2954    :type token_id: str
2955    :param schedule: The cron expression indicating the schedule that the connected registry will
2956     sync with its parent.
2957    :type schedule: str
2958    :param sync_window: The time window during which sync is enabled for each schedule occurrence.
2959     Specify the duration using the format P[n]Y[n]M[n]DT[n]H[n]M[n]S as per ISO8601.
2960    :type sync_window: ~datetime.timedelta
2961    :param message_ttl: Required. The period of time for which a message is available to sync
2962     before it is expired. Specify the duration using the format P[n]Y[n]M[n]DT[n]H[n]M[n]S as per
2963     ISO8601.
2964    :type message_ttl: ~datetime.timedelta
2965    :ivar last_sync_time: The last time a sync occurred between the connected registry and its
2966     parent.
2967    :vartype last_sync_time: ~datetime.datetime
2968    :ivar gateway_endpoint: The gateway endpoint used by the connected registry to communicate with
2969     its parent.
2970    :vartype gateway_endpoint: str
2971    """
2972
2973    _validation = {
2974        'token_id': {'required': True},
2975        'message_ttl': {'required': True},
2976        'last_sync_time': {'readonly': True},
2977        'gateway_endpoint': {'readonly': True},
2978    }
2979
2980    _attribute_map = {
2981        'token_id': {'key': 'tokenId', 'type': 'str'},
2982        'schedule': {'key': 'schedule', 'type': 'str'},
2983        'sync_window': {'key': 'syncWindow', 'type': 'duration'},
2984        'message_ttl': {'key': 'messageTtl', 'type': 'duration'},
2985        'last_sync_time': {'key': 'lastSyncTime', 'type': 'iso-8601'},
2986        'gateway_endpoint': {'key': 'gatewayEndpoint', 'type': 'str'},
2987    }
2988
2989    def __init__(
2990        self,
2991        **kwargs
2992    ):
2993        super(SyncProperties, self).__init__(**kwargs)
2994        self.token_id = kwargs['token_id']
2995        self.schedule = kwargs.get('schedule', None)
2996        self.sync_window = kwargs.get('sync_window', None)
2997        self.message_ttl = kwargs['message_ttl']
2998        self.last_sync_time = None
2999        self.gateway_endpoint = None
3000
3001
3002class SyncUpdateProperties(msrest.serialization.Model):
3003    """The parameters for updating the sync properties of the connected registry with its parent.
3004
3005    :param schedule: The cron expression indicating the schedule that the connected registry will
3006     sync with its parent.
3007    :type schedule: str
3008    :param sync_window: The time window during which sync is enabled for each schedule occurrence.
3009     Specify the duration using the format P[n]Y[n]M[n]DT[n]H[n]M[n]S as per ISO8601.
3010    :type sync_window: ~datetime.timedelta
3011    :param message_ttl: The period of time for which a message is available to sync before it is
3012     expired. Specify the duration using the format P[n]Y[n]M[n]DT[n]H[n]M[n]S as per ISO8601.
3013    :type message_ttl: ~datetime.timedelta
3014    """
3015
3016    _attribute_map = {
3017        'schedule': {'key': 'schedule', 'type': 'str'},
3018        'sync_window': {'key': 'syncWindow', 'type': 'duration'},
3019        'message_ttl': {'key': 'messageTtl', 'type': 'duration'},
3020    }
3021
3022    def __init__(
3023        self,
3024        **kwargs
3025    ):
3026        super(SyncUpdateProperties, self).__init__(**kwargs)
3027        self.schedule = kwargs.get('schedule', None)
3028        self.sync_window = kwargs.get('sync_window', None)
3029        self.message_ttl = kwargs.get('message_ttl', None)
3030
3031
3032class SystemData(msrest.serialization.Model):
3033    """Metadata pertaining to creation and last modification of the resource.
3034
3035    :param created_by: The identity that created the resource.
3036    :type created_by: str
3037    :param created_by_type: The type of identity that created the resource. Possible values
3038     include: "User", "Application", "ManagedIdentity", "Key".
3039    :type created_by_type: str or
3040     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.CreatedByType
3041    :param created_at: The timestamp of resource creation (UTC).
3042    :type created_at: ~datetime.datetime
3043    :param last_modified_by: The identity that last modified the resource.
3044    :type last_modified_by: str
3045    :param last_modified_by_type: The type of identity that last modified the resource. Possible
3046     values include: "User", "Application", "ManagedIdentity", "Key".
3047    :type last_modified_by_type: str or
3048     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.LastModifiedByType
3049    :param last_modified_at: The timestamp of resource modification (UTC).
3050    :type last_modified_at: ~datetime.datetime
3051    """
3052
3053    _attribute_map = {
3054        'created_by': {'key': 'createdBy', 'type': 'str'},
3055        'created_by_type': {'key': 'createdByType', 'type': 'str'},
3056        'created_at': {'key': 'createdAt', 'type': 'iso-8601'},
3057        'last_modified_by': {'key': 'lastModifiedBy', 'type': 'str'},
3058        'last_modified_by_type': {'key': 'lastModifiedByType', 'type': 'str'},
3059        'last_modified_at': {'key': 'lastModifiedAt', 'type': 'iso-8601'},
3060    }
3061
3062    def __init__(
3063        self,
3064        **kwargs
3065    ):
3066        super(SystemData, self).__init__(**kwargs)
3067        self.created_by = kwargs.get('created_by', None)
3068        self.created_by_type = kwargs.get('created_by_type', None)
3069        self.created_at = kwargs.get('created_at', None)
3070        self.last_modified_by = kwargs.get('last_modified_by', None)
3071        self.last_modified_by_type = kwargs.get('last_modified_by_type', None)
3072        self.last_modified_at = kwargs.get('last_modified_at', None)
3073
3074
3075class Target(msrest.serialization.Model):
3076    """The target of the event.
3077
3078    :param media_type: The MIME type of the referenced object.
3079    :type media_type: str
3080    :param size: The number of bytes of the content. Same as Length field.
3081    :type size: long
3082    :param digest: The digest of the content, as defined by the Registry V2 HTTP API Specification.
3083    :type digest: str
3084    :param length: The number of bytes of the content. Same as Size field.
3085    :type length: long
3086    :param repository: The repository name.
3087    :type repository: str
3088    :param url: The direct URL to the content.
3089    :type url: str
3090    :param tag: The tag name.
3091    :type tag: str
3092    :param name: The name of the artifact.
3093    :type name: str
3094    :param version: The version of the artifact.
3095    :type version: str
3096    """
3097
3098    _attribute_map = {
3099        'media_type': {'key': 'mediaType', 'type': 'str'},
3100        'size': {'key': 'size', 'type': 'long'},
3101        'digest': {'key': 'digest', 'type': 'str'},
3102        'length': {'key': 'length', 'type': 'long'},
3103        'repository': {'key': 'repository', 'type': 'str'},
3104        'url': {'key': 'url', 'type': 'str'},
3105        'tag': {'key': 'tag', 'type': 'str'},
3106        'name': {'key': 'name', 'type': 'str'},
3107        'version': {'key': 'version', 'type': 'str'},
3108    }
3109
3110    def __init__(
3111        self,
3112        **kwargs
3113    ):
3114        super(Target, self).__init__(**kwargs)
3115        self.media_type = kwargs.get('media_type', None)
3116        self.size = kwargs.get('size', None)
3117        self.digest = kwargs.get('digest', None)
3118        self.length = kwargs.get('length', None)
3119        self.repository = kwargs.get('repository', None)
3120        self.url = kwargs.get('url', None)
3121        self.tag = kwargs.get('tag', None)
3122        self.name = kwargs.get('name', None)
3123        self.version = kwargs.get('version', None)
3124
3125
3126class TlsCertificateProperties(msrest.serialization.Model):
3127    """The TLS certificate properties of the connected registry login server.
3128
3129    Variables are only populated by the server, and will be ignored when sending a request.
3130
3131    :ivar type: The type of certificate location. Possible values include: "LocalDirectory".
3132    :vartype type: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.CertificateType
3133    :ivar location: Indicates the location of the certificates.
3134    :vartype location: str
3135    """
3136
3137    _validation = {
3138        'type': {'readonly': True},
3139        'location': {'readonly': True},
3140    }
3141
3142    _attribute_map = {
3143        'type': {'key': 'type', 'type': 'str'},
3144        'location': {'key': 'location', 'type': 'str'},
3145    }
3146
3147    def __init__(
3148        self,
3149        **kwargs
3150    ):
3151        super(TlsCertificateProperties, self).__init__(**kwargs)
3152        self.type = None
3153        self.location = None
3154
3155
3156class TlsProperties(msrest.serialization.Model):
3157    """The TLS properties of the connected registry login server.
3158
3159    Variables are only populated by the server, and will be ignored when sending a request.
3160
3161    :ivar status: Indicates whether HTTPS is enabled for the login server. Possible values include:
3162     "Enabled", "Disabled".
3163    :vartype status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TlsStatus
3164    :ivar certificate: The certificate used to configure HTTPS for the login server.
3165    :vartype certificate:
3166     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TlsCertificateProperties
3167    """
3168
3169    _validation = {
3170        'status': {'readonly': True},
3171        'certificate': {'readonly': True},
3172    }
3173
3174    _attribute_map = {
3175        'status': {'key': 'status', 'type': 'str'},
3176        'certificate': {'key': 'certificate', 'type': 'TlsCertificateProperties'},
3177    }
3178
3179    def __init__(
3180        self,
3181        **kwargs
3182    ):
3183        super(TlsProperties, self).__init__(**kwargs)
3184        self.status = None
3185        self.certificate = None
3186
3187
3188class Token(ProxyResource):
3189    """An object that represents a token for a container registry.
3190
3191    Variables are only populated by the server, and will be ignored when sending a request.
3192
3193    :ivar id: The resource ID.
3194    :vartype id: str
3195    :ivar name: The name of the resource.
3196    :vartype name: str
3197    :ivar type: The type of the resource.
3198    :vartype type: str
3199    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
3200    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
3201    :ivar creation_date: The creation date of scope map.
3202    :vartype creation_date: ~datetime.datetime
3203    :ivar provisioning_state: Provisioning state of the resource. Possible values include:
3204     "Creating", "Updating", "Deleting", "Succeeded", "Failed", "Canceled".
3205    :vartype provisioning_state: str or
3206     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
3207    :param scope_map_id: The resource ID of the scope map to which the token will be associated
3208     with.
3209    :type scope_map_id: str
3210    :param credentials: The credentials that can be used for authenticating the token.
3211    :type credentials:
3212     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenCredentialsProperties
3213    :param status: The status of the token example enabled or disabled. Possible values include:
3214     "enabled", "disabled".
3215    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenStatus
3216    """
3217
3218    _validation = {
3219        'id': {'readonly': True},
3220        'name': {'readonly': True},
3221        'type': {'readonly': True},
3222        'system_data': {'readonly': True},
3223        'creation_date': {'readonly': True},
3224        'provisioning_state': {'readonly': True},
3225    }
3226
3227    _attribute_map = {
3228        'id': {'key': 'id', 'type': 'str'},
3229        'name': {'key': 'name', 'type': 'str'},
3230        'type': {'key': 'type', 'type': 'str'},
3231        'system_data': {'key': 'systemData', 'type': 'SystemData'},
3232        'creation_date': {'key': 'properties.creationDate', 'type': 'iso-8601'},
3233        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
3234        'scope_map_id': {'key': 'properties.scopeMapId', 'type': 'str'},
3235        'credentials': {'key': 'properties.credentials', 'type': 'TokenCredentialsProperties'},
3236        'status': {'key': 'properties.status', 'type': 'str'},
3237    }
3238
3239    def __init__(
3240        self,
3241        **kwargs
3242    ):
3243        super(Token, self).__init__(**kwargs)
3244        self.creation_date = None
3245        self.provisioning_state = None
3246        self.scope_map_id = kwargs.get('scope_map_id', None)
3247        self.credentials = kwargs.get('credentials', None)
3248        self.status = kwargs.get('status', None)
3249
3250
3251class TokenCertificate(msrest.serialization.Model):
3252    """The properties of a certificate used for authenticating a token.
3253
3254    :param name:  Possible values include: "certificate1", "certificate2".
3255    :type name: str or
3256     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenCertificateName
3257    :param expiry: The expiry datetime of the certificate.
3258    :type expiry: ~datetime.datetime
3259    :param thumbprint: The thumbprint of the certificate.
3260    :type thumbprint: str
3261    :param encoded_pem_certificate: Base 64 encoded string of the public certificate1 in PEM format
3262     that will be used for authenticating the token.
3263    :type encoded_pem_certificate: str
3264    """
3265
3266    _attribute_map = {
3267        'name': {'key': 'name', 'type': 'str'},
3268        'expiry': {'key': 'expiry', 'type': 'iso-8601'},
3269        'thumbprint': {'key': 'thumbprint', 'type': 'str'},
3270        'encoded_pem_certificate': {'key': 'encodedPemCertificate', 'type': 'str'},
3271    }
3272
3273    def __init__(
3274        self,
3275        **kwargs
3276    ):
3277        super(TokenCertificate, self).__init__(**kwargs)
3278        self.name = kwargs.get('name', None)
3279        self.expiry = kwargs.get('expiry', None)
3280        self.thumbprint = kwargs.get('thumbprint', None)
3281        self.encoded_pem_certificate = kwargs.get('encoded_pem_certificate', None)
3282
3283
3284class TokenCredentialsProperties(msrest.serialization.Model):
3285    """The properties of the credentials that can be used for authenticating the token.
3286
3287    :param certificates:
3288    :type certificates:
3289     list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenCertificate]
3290    :param passwords:
3291    :type passwords: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenPassword]
3292    """
3293
3294    _attribute_map = {
3295        'certificates': {'key': 'certificates', 'type': '[TokenCertificate]'},
3296        'passwords': {'key': 'passwords', 'type': '[TokenPassword]'},
3297    }
3298
3299    def __init__(
3300        self,
3301        **kwargs
3302    ):
3303        super(TokenCredentialsProperties, self).__init__(**kwargs)
3304        self.certificates = kwargs.get('certificates', None)
3305        self.passwords = kwargs.get('passwords', None)
3306
3307
3308class TokenListResult(msrest.serialization.Model):
3309    """The result of a request to list tokens for a container registry.
3310
3311    :param value: The list of tokens. Since this list may be incomplete, the nextLink field should
3312     be used to request the next list of tokens.
3313    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.Token]
3314    :param next_link: The URI that can be used to request the next list of tokens.
3315    :type next_link: str
3316    """
3317
3318    _attribute_map = {
3319        'value': {'key': 'value', 'type': '[Token]'},
3320        'next_link': {'key': 'nextLink', 'type': 'str'},
3321    }
3322
3323    def __init__(
3324        self,
3325        **kwargs
3326    ):
3327        super(TokenListResult, self).__init__(**kwargs)
3328        self.value = kwargs.get('value', None)
3329        self.next_link = kwargs.get('next_link', None)
3330
3331
3332class TokenPassword(msrest.serialization.Model):
3333    """The password that will be used for authenticating the token of a container registry.
3334
3335    Variables are only populated by the server, and will be ignored when sending a request.
3336
3337    :param creation_time: The creation datetime of the password.
3338    :type creation_time: ~datetime.datetime
3339    :param expiry: The expiry datetime of the password.
3340    :type expiry: ~datetime.datetime
3341    :param name: The password name "password1" or "password2". Possible values include:
3342     "password1", "password2".
3343    :type name: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenPasswordName
3344    :ivar value: The password value.
3345    :vartype value: str
3346    """
3347
3348    _validation = {
3349        'value': {'readonly': True},
3350    }
3351
3352    _attribute_map = {
3353        'creation_time': {'key': 'creationTime', 'type': 'iso-8601'},
3354        'expiry': {'key': 'expiry', 'type': 'iso-8601'},
3355        'name': {'key': 'name', 'type': 'str'},
3356        'value': {'key': 'value', 'type': 'str'},
3357    }
3358
3359    def __init__(
3360        self,
3361        **kwargs
3362    ):
3363        super(TokenPassword, self).__init__(**kwargs)
3364        self.creation_time = kwargs.get('creation_time', None)
3365        self.expiry = kwargs.get('expiry', None)
3366        self.name = kwargs.get('name', None)
3367        self.value = None
3368
3369
3370class TokenUpdateParameters(msrest.serialization.Model):
3371    """The parameters for updating a token.
3372
3373    :param scope_map_id: The resource ID of the scope map to which the token will be associated
3374     with.
3375    :type scope_map_id: str
3376    :param status: The status of the token example enabled or disabled. Possible values include:
3377     "enabled", "disabled".
3378    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenStatus
3379    :param credentials: The credentials that can be used for authenticating the token.
3380    :type credentials:
3381     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TokenCredentialsProperties
3382    """
3383
3384    _attribute_map = {
3385        'scope_map_id': {'key': 'properties.scopeMapId', 'type': 'str'},
3386        'status': {'key': 'properties.status', 'type': 'str'},
3387        'credentials': {'key': 'properties.credentials', 'type': 'TokenCredentialsProperties'},
3388    }
3389
3390    def __init__(
3391        self,
3392        **kwargs
3393    ):
3394        super(TokenUpdateParameters, self).__init__(**kwargs)
3395        self.scope_map_id = kwargs.get('scope_map_id', None)
3396        self.status = kwargs.get('status', None)
3397        self.credentials = kwargs.get('credentials', None)
3398
3399
3400class TrustPolicy(msrest.serialization.Model):
3401    """The content trust policy for a container registry.
3402
3403    :param type: The type of trust policy. Possible values include: "Notary". Default value:
3404     "Notary".
3405    :type type: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.TrustPolicyType
3406    :param status: The value that indicates whether the policy is enabled or not. Possible values
3407     include: "enabled", "disabled".
3408    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.PolicyStatus
3409    """
3410
3411    _attribute_map = {
3412        'type': {'key': 'type', 'type': 'str'},
3413        'status': {'key': 'status', 'type': 'str'},
3414    }
3415
3416    def __init__(
3417        self,
3418        **kwargs
3419    ):
3420        super(TrustPolicy, self).__init__(**kwargs)
3421        self.type = kwargs.get('type', "Notary")
3422        self.status = kwargs.get('status', None)
3423
3424
3425class UserIdentityProperties(msrest.serialization.Model):
3426    """UserIdentityProperties.
3427
3428    :param principal_id: The principal id of user assigned identity.
3429    :type principal_id: str
3430    :param client_id: The client id of user assigned identity.
3431    :type client_id: str
3432    """
3433
3434    _attribute_map = {
3435        'principal_id': {'key': 'principalId', 'type': 'str'},
3436        'client_id': {'key': 'clientId', 'type': 'str'},
3437    }
3438
3439    def __init__(
3440        self,
3441        **kwargs
3442    ):
3443        super(UserIdentityProperties, self).__init__(**kwargs)
3444        self.principal_id = kwargs.get('principal_id', None)
3445        self.client_id = kwargs.get('client_id', None)
3446
3447
3448class VirtualNetworkRule(msrest.serialization.Model):
3449    """Virtual network rule.
3450
3451    All required parameters must be populated in order to send to Azure.
3452
3453    :param action: The action of virtual network rule. Possible values include: "Allow".
3454    :type action: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.Action
3455    :param virtual_network_resource_id: Required. Resource ID of a subnet, for example:
3456     /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{vnetName}/subnets/{subnetName}.
3457    :type virtual_network_resource_id: str
3458    """
3459
3460    _validation = {
3461        'virtual_network_resource_id': {'required': True},
3462    }
3463
3464    _attribute_map = {
3465        'action': {'key': 'action', 'type': 'str'},
3466        'virtual_network_resource_id': {'key': 'id', 'type': 'str'},
3467    }
3468
3469    def __init__(
3470        self,
3471        **kwargs
3472    ):
3473        super(VirtualNetworkRule, self).__init__(**kwargs)
3474        self.action = kwargs.get('action', None)
3475        self.virtual_network_resource_id = kwargs['virtual_network_resource_id']
3476
3477
3478class Webhook(Resource):
3479    """An object that represents a webhook for a container registry.
3480
3481    Variables are only populated by the server, and will be ignored when sending a request.
3482
3483    All required parameters must be populated in order to send to Azure.
3484
3485    :ivar id: The resource ID.
3486    :vartype id: str
3487    :ivar name: The name of the resource.
3488    :vartype name: str
3489    :ivar type: The type of the resource.
3490    :vartype type: str
3491    :param location: Required. The location of the resource. This cannot be changed after the
3492     resource is created.
3493    :type location: str
3494    :param tags: A set of tags. The tags of the resource.
3495    :type tags: dict[str, str]
3496    :ivar system_data: Metadata pertaining to creation and last modification of the resource.
3497    :vartype system_data: ~azure.mgmt.containerregistry.v2021_06_01_preview.models.SystemData
3498    :param status: The status of the webhook at the time the operation was called. Possible values
3499     include: "enabled", "disabled".
3500    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.WebhookStatus
3501    :param scope: The scope of repositories where the event can be triggered. For example, 'foo:*'
3502     means events for all tags under repository 'foo'. 'foo:bar' means events for 'foo:bar' only.
3503     'foo' is equivalent to 'foo:latest'. Empty means all events.
3504    :type scope: str
3505    :param actions: The list of actions that trigger the webhook to post notifications.
3506    :type actions: list[str or
3507     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.WebhookAction]
3508    :ivar provisioning_state: The provisioning state of the webhook at the time the operation was
3509     called. Possible values include: "Creating", "Updating", "Deleting", "Succeeded", "Failed",
3510     "Canceled".
3511    :vartype provisioning_state: str or
3512     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.ProvisioningState
3513    """
3514
3515    _validation = {
3516        'id': {'readonly': True},
3517        'name': {'readonly': True},
3518        'type': {'readonly': True},
3519        'location': {'required': True},
3520        'system_data': {'readonly': True},
3521        'provisioning_state': {'readonly': True},
3522    }
3523
3524    _attribute_map = {
3525        'id': {'key': 'id', 'type': 'str'},
3526        'name': {'key': 'name', 'type': 'str'},
3527        'type': {'key': 'type', 'type': 'str'},
3528        'location': {'key': 'location', 'type': 'str'},
3529        'tags': {'key': 'tags', 'type': '{str}'},
3530        'system_data': {'key': 'systemData', 'type': 'SystemData'},
3531        'status': {'key': 'properties.status', 'type': 'str'},
3532        'scope': {'key': 'properties.scope', 'type': 'str'},
3533        'actions': {'key': 'properties.actions', 'type': '[str]'},
3534        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
3535    }
3536
3537    def __init__(
3538        self,
3539        **kwargs
3540    ):
3541        super(Webhook, self).__init__(**kwargs)
3542        self.status = kwargs.get('status', None)
3543        self.scope = kwargs.get('scope', None)
3544        self.actions = kwargs.get('actions', None)
3545        self.provisioning_state = None
3546
3547
3548class WebhookCreateParameters(msrest.serialization.Model):
3549    """The parameters for creating a webhook.
3550
3551    All required parameters must be populated in order to send to Azure.
3552
3553    :param tags: A set of tags. The tags for the webhook.
3554    :type tags: dict[str, str]
3555    :param location: Required. The location of the webhook. This cannot be changed after the
3556     resource is created.
3557    :type location: str
3558    :param service_uri: The service URI for the webhook to post notifications.
3559    :type service_uri: str
3560    :param custom_headers: Custom headers that will be added to the webhook notifications.
3561    :type custom_headers: dict[str, str]
3562    :param status: The status of the webhook at the time the operation was called. Possible values
3563     include: "enabled", "disabled".
3564    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.WebhookStatus
3565    :param scope: The scope of repositories where the event can be triggered. For example, 'foo:*'
3566     means events for all tags under repository 'foo'. 'foo:bar' means events for 'foo:bar' only.
3567     'foo' is equivalent to 'foo:latest'. Empty means all events.
3568    :type scope: str
3569    :param actions: The list of actions that trigger the webhook to post notifications.
3570    :type actions: list[str or
3571     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.WebhookAction]
3572    """
3573
3574    _validation = {
3575        'location': {'required': True},
3576    }
3577
3578    _attribute_map = {
3579        'tags': {'key': 'tags', 'type': '{str}'},
3580        'location': {'key': 'location', 'type': 'str'},
3581        'service_uri': {'key': 'properties.serviceUri', 'type': 'str'},
3582        'custom_headers': {'key': 'properties.customHeaders', 'type': '{str}'},
3583        'status': {'key': 'properties.status', 'type': 'str'},
3584        'scope': {'key': 'properties.scope', 'type': 'str'},
3585        'actions': {'key': 'properties.actions', 'type': '[str]'},
3586    }
3587
3588    def __init__(
3589        self,
3590        **kwargs
3591    ):
3592        super(WebhookCreateParameters, self).__init__(**kwargs)
3593        self.tags = kwargs.get('tags', None)
3594        self.location = kwargs['location']
3595        self.service_uri = kwargs.get('service_uri', None)
3596        self.custom_headers = kwargs.get('custom_headers', None)
3597        self.status = kwargs.get('status', None)
3598        self.scope = kwargs.get('scope', None)
3599        self.actions = kwargs.get('actions', None)
3600
3601
3602class WebhookListResult(msrest.serialization.Model):
3603    """The result of a request to list webhooks for a container registry.
3604
3605    :param value: The list of webhooks. Since this list may be incomplete, the nextLink field
3606     should be used to request the next list of webhooks.
3607    :type value: list[~azure.mgmt.containerregistry.v2021_06_01_preview.models.Webhook]
3608    :param next_link: The URI that can be used to request the next list of webhooks.
3609    :type next_link: str
3610    """
3611
3612    _attribute_map = {
3613        'value': {'key': 'value', 'type': '[Webhook]'},
3614        'next_link': {'key': 'nextLink', 'type': 'str'},
3615    }
3616
3617    def __init__(
3618        self,
3619        **kwargs
3620    ):
3621        super(WebhookListResult, self).__init__(**kwargs)
3622        self.value = kwargs.get('value', None)
3623        self.next_link = kwargs.get('next_link', None)
3624
3625
3626class WebhookUpdateParameters(msrest.serialization.Model):
3627    """The parameters for updating a webhook.
3628
3629    :param tags: A set of tags. The tags for the webhook.
3630    :type tags: dict[str, str]
3631    :param service_uri: The service URI for the webhook to post notifications.
3632    :type service_uri: str
3633    :param custom_headers: Custom headers that will be added to the webhook notifications.
3634    :type custom_headers: dict[str, str]
3635    :param status: The status of the webhook at the time the operation was called. Possible values
3636     include: "enabled", "disabled".
3637    :type status: str or ~azure.mgmt.containerregistry.v2021_06_01_preview.models.WebhookStatus
3638    :param scope: The scope of repositories where the event can be triggered. For example, 'foo:*'
3639     means events for all tags under repository 'foo'. 'foo:bar' means events for 'foo:bar' only.
3640     'foo' is equivalent to 'foo:latest'. Empty means all events.
3641    :type scope: str
3642    :param actions: The list of actions that trigger the webhook to post notifications.
3643    :type actions: list[str or
3644     ~azure.mgmt.containerregistry.v2021_06_01_preview.models.WebhookAction]
3645    """
3646
3647    _attribute_map = {
3648        'tags': {'key': 'tags', 'type': '{str}'},
3649        'service_uri': {'key': 'properties.serviceUri', 'type': 'str'},
3650        'custom_headers': {'key': 'properties.customHeaders', 'type': '{str}'},
3651        'status': {'key': 'properties.status', 'type': 'str'},
3652        'scope': {'key': 'properties.scope', 'type': 'str'},
3653        'actions': {'key': 'properties.actions', 'type': '[str]'},
3654    }
3655
3656    def __init__(
3657        self,
3658        **kwargs
3659    ):
3660        super(WebhookUpdateParameters, self).__init__(**kwargs)
3661        self.tags = kwargs.get('tags', None)
3662        self.service_uri = kwargs.get('service_uri', None)
3663        self.custom_headers = kwargs.get('custom_headers', None)
3664        self.status = kwargs.get('status', None)
3665        self.scope = kwargs.get('scope', None)
3666        self.actions = kwargs.get('actions', None)
3667