{
  "swagger": "2.0",
  "schemes": [
    "https"
  ],
  "host": "management.azure.com",
  "info": {
    "title": "ContainerRegistryManagementClient",
    "version": "2016-06-27-preview",
    "x-apisguru-categories": [
      "cloud"
    ],
    "x-logo": {
      "url": "https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png"
    },
    "x-origin": [
      {
        "format": "swagger",
        "url": "https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/containerregistry/resource-manager/Microsoft.ContainerRegistry/preview/2016-06-27-preview/containerregistry.json",
        "version": "2.0"
      }
    ],
    "x-preferred": false,
    "x-providerName": "azure.com",
    "x-serviceName": "containerregistry",
    "x-tags": [
      "Azure",
      "Microsoft"
    ]
  },
  "consumes": [
    "application/json"
  ],
  "produces": [
    "application/json"
  ],
  "parameters": {
    "ApiVersionParameter": {
      "description": "The client API version.",
      "in": "query",
      "name": "api-version",
      "required": true,
      "type": "string"
    },
    "RegistryNameParameter": {
      "description": "The name of the container registry.",
      "in": "path",
      "name": "registryName",
      "required": true,
      "type": "string",
      "x-ms-parameter-location": "method"
    },
    "ResourceGroupParameter": {
      "description": "The name of the resource group to which the container registry belongs.",
      "in": "path",
      "name": "resourceGroupName",
      "required": true,
      "type": "string",
      "x-ms-parameter-location": "method"
    },
    "SubscriptionIdParameter": {
      "description": "The Microsoft Azure subscription ID.",
      "in": "path",
      "name": "subscriptionId",
      "required": true,
      "type": "string"
    }
  },
  "paths": {
    "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerRegistry/checkNameAvailability": {
      "post": {
        "description": "Checks whether the container registry name is available for use. The name must contain only alphanumeric characters, be globally unique, and between 5 and 60 characters in length.",
        "operationId": "Registries_CheckNameAvailability",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "description": "The object containing information for the availability request.",
            "in": "body",
            "name": "registryNameCheckRequest",
            "required": true,
            "schema": {
              "$ref": "#/definitions/RegistryNameCheckRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/RegistryNameStatus"
            }
          }
        },
        "tags": [
          "Operation"
        ]
      }
    },
    "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerRegistry/registries": {
      "get": {
        "description": "Lists all the available container registries under the specified subscription.",
        "operationId": "Registries_List",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/RegistryListResult"
            }
          }
        },
        "tags": [
          "Registries"
        ],
        "x-ms-pageable": {
          "nextLinkName": "nextLink"
        }
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries": {
      "get": {
        "description": "Lists all the available container registries under the specified resource group.",
        "operationId": "Registries_ListByResourceGroup",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/RegistryListResult"
            }
          }
        },
        "tags": [
          "Registries"
        ],
        "x-ms-pageable": {
          "nextLinkName": "nextLink"
        }
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}": {
      "delete": {
        "description": "Deletes a container registry.",
        "operationId": "Registries_Delete",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          },
          {
            "$ref": "#/parameters/RegistryNameParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly."
          },
          "204": {
            "description": "The container registry does not exist in the subscription."
          }
        },
        "tags": [
          "Registries"
        ]
      },
      "get": {
        "description": "Gets the properties of the specified container registry.",
        "operationId": "Registries_GetProperties",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          },
          {
            "$ref": "#/parameters/RegistryNameParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/Registry"
            }
          }
        },
        "tags": [
          "Registries"
        ]
      },
      "patch": {
        "description": "Updates a container registry with the specified parameters.",
        "operationId": "Registries_Update",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          },
          {
            "$ref": "#/parameters/RegistryNameParameter"
          },
          {
            "description": "The parameters for updating a container registry.",
            "in": "body",
            "name": "registryUpdateParameters",
            "required": true,
            "schema": {
              "$ref": "#/definitions/RegistryUpdateParameters"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/Registry"
            }
          }
        },
        "tags": [
          "Registries"
        ]
      },
      "put": {
        "description": "Creates or updates a container registry with the specified parameters.",
        "operationId": "Registries_CreateOrUpdate",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          },
          {
            "$ref": "#/parameters/RegistryNameParameter"
          },
          {
            "description": "The parameters for creating or updating a container registry.",
            "in": "body",
            "name": "registry",
            "required": true,
            "schema": {
              "$ref": "#/definitions/Registry"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/Registry"
            }
          },
          "202": {
            "description": "The request was successful; the operation will complete asynchronously."
          }
        },
        "tags": [
          "Registries"
        ]
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/getCredentials": {
      "post": {
        "description": "Gets the administrator login credentials for the specified container registry.",
        "operationId": "Registries_GetCredentials",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          },
          {
            "$ref": "#/parameters/RegistryNameParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/RegistryCredentials"
            }
          }
        },
        "tags": [
          "Registries"
        ]
      }
    },
    "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/regenerateCredentials": {
      "post": {
        "description": "Regenerates the administrator login credentials for the specified container registry.",
        "operationId": "Registries_RegenerateCredentials",
        "parameters": [
          {
            "$ref": "#/parameters/ApiVersionParameter"
          },
          {
            "$ref": "#/parameters/SubscriptionIdParameter"
          },
          {
            "$ref": "#/parameters/ResourceGroupParameter"
          },
          {
            "$ref": "#/parameters/RegistryNameParameter"
          }
        ],
        "responses": {
          "200": {
            "description": "The request was successful; the request was well-formed and received properly.",
            "schema": {
              "$ref": "#/definitions/RegistryCredentials"
            }
          }
        },
        "tags": [
          "Registries"
        ]
      }
    }
  },
  "definitions": {
    "Registry": {
      "allOf": [
        {
          "$ref": "#/definitions/Resource"
        }
      ],
      "description": "An object that represents a container registry.",
      "properties": {
        "properties": {
          "$ref": "#/definitions/RegistryProperties",
          "description": "The properties of the container registry.",
          "x-ms-client-flatten": true
        }
      }
    },
    "RegistryCredentials": {
      "description": "The result of a request to get the administrator login credentials for a container registry.",
      "properties": {
        "password": {
          "description": "The administrator password.",
          "type": "string"
        },
        "username": {
          "description": "The administrator username.",
          "type": "string"
        }
      }
    },
    "RegistryListResult": {
      "description": "The result of a request to list container registries.",
      "properties": {
        "nextLink": {
          "description": "The URI that can be used to request the next list of container registries.",
          "type": "string"
        },
        "value": {
          "description": "The list of container registries. Since this list may be incomplete, the nextLink field should be used to request the next list of container registries.",
          "items": {
            "$ref": "#/definitions/Registry"
          },
          "type": "array"
        }
      }
    },
    "RegistryNameCheckRequest": {
      "description": "A request to check whether the container registry name is available.",
      "properties": {
        "name": {
          "description": "The name of the container registry.",
          "type": "string"
        },
        "type": {
          "description": "The resource type of the container registry. This field must be set to \"Microsoft.ContainerRegistry/registries\".",
          "enum": [
            "Microsoft.ContainerRegistry/registries"
          ],
          "type": "string",
          "x-ms-enum": {
            "modelAsString": false,
            "name": "ContainerRegistryResourceType"
          }
        }
      },
      "required": [
        "name",
        "type"
      ]
    },
    "RegistryNameStatus": {
      "description": "The result of a request to check the availability of a container registry name.",
      "properties": {
        "message": {
          "description": "If any, the error message that provides more detail for the reason that the name is not available.",
          "type": "string"
        },
        "nameAvailable": {
          "description": "The value that indicates whether the name is available.",
          "type": "boolean"
        },
        "reason": {
          "description": "If any, the reason that the name is not available.",
          "type": "string"
        }
      }
    },
    "RegistryProperties": {
      "description": "The properties of a container registry.",
      "properties": {
        "adminUserEnabled": {
          "default": false,
          "description": "The value that indicates whether the admin user is enabled. This value is false by default.",
          "type": "boolean"
        },
        "creationDate": {
          "description": "The creation date of the container registry in ISO8601 format.",
          "format": "date-time",
          "readOnly": true,
          "type": "string"
        },
        "loginServer": {
          "description": "The URL that can be used to log into the container registry.",
          "readOnly": true,
          "type": "string"
        },
        "storageAccount": {
          "$ref": "#/definitions/StorageAccountProperties",
          "description": "The properties of the storage account for the container registry. If specified, the storage account must be in the same physical location as the container registry."
        }
      },
      "required": [
        "storageAccount"
      ]
    },
    "RegistryPropertiesUpdateParameters": {
      "description": "The parameters for updating the properties of a container registry.",
      "properties": {
        "adminUserEnabled": {
          "description": "The value that indicates whether the admin user is enabled. This value is false by default.",
          "type": "boolean"
        },
        "storageAccount": {
          "$ref": "#/definitions/StorageAccountProperties",
          "description": "The properties of a storage account for the container registry. If specified, the storage account must be in the same physical location as the container registry."
        }
      }
    },
    "RegistryUpdateParameters": {
      "description": "The parameters for updating a container registry.",
      "properties": {
        "properties": {
          "$ref": "#/definitions/RegistryPropertiesUpdateParameters",
          "description": "The properties that the container registry will be updated with.",
          "x-ms-client-flatten": true
        },
        "tags": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "The resource tags for the container registry.",
          "type": "object"
        }
      }
    },
    "Resource": {
      "description": "An Azure resource.",
      "properties": {
        "id": {
          "description": "The resource ID.",
          "readOnly": true,
          "type": "string"
        },
        "location": {
          "description": "The location of the resource. This cannot be changed after the resource is created.",
          "type": "string"
        },
        "name": {
          "description": "The name of the resource.",
          "readOnly": true,
          "type": "string"
        },
        "tags": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "The tags of the resource.",
          "type": "object"
        },
        "type": {
          "description": "The type of the resource.",
          "readOnly": true,
          "type": "string"
        }
      },
      "required": [
        "location"
      ],
      "x-ms-azure-resource": true
    },
    "StorageAccountProperties": {
      "description": "The properties of a storage account for a container registry.",
      "properties": {
        "accessKey": {
          "description": "The access key to the storage account.",
          "type": "string"
        },
        "name": {
          "description": "The name of the storage account.",
          "type": "string"
        }
      },
      "required": [
        "name",
        "accessKey"
      ]
    }
  }
}