{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/microsoft-azure-key-vault/json-schema/microsoft-azure-key-vault-vault-create-or-update-parameters-schema.json",
  "title": "VaultCreateOrUpdateParameters",
  "description": "Parameters for creating or updating a vault",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/microsoft-azure-key-vault-vaults-api-openapi.yml#/components/schemas/VaultCreateOrUpdateParameters",
  "type": "object",
  "properties": {
    "location": {
      "type": "string",
      "description": "The supported Azure location where the key vault should be created."
    },
    "tags": {
      "type": "object",
      "description": "The tags that will be assigned to the key vault.",
      "additionalProperties": {
        "type": "string"
      }
    },
    "properties": {
      "$ref": "#/$defs/VaultProperties",
      "description": "Properties of the vault"
    }
  },
  "required": [
    "location",
    "properties"
  ],
  "$defs": {
    "AccessPolicyEntry": {
      "type": "object",
      "description": "An identity that have access to the key vault. All identities in the array must use the same tenant ID as the key vault's tenant ID.",
      "properties": {
        "tenantId": {
          "$ref": "#/$defs/Azure.Core.uuid",
          "description": "The Azure Active Directory tenant ID that should be used for authenticating requests to the key vault."
        },
        "objectId": {
          "type": "string",
          "description": "The object ID of a user, service principal or security group in the Azure Active Directory tenant for the vault. The object ID must be unique for the list of access policies."
        },
        "applicationId": {
          "$ref": "#/$defs/Azure.Core.uuid",
          "description": "Application ID of the client making request on behalf of a principal"
        },
        "permissions": {
          "$ref": "#/$defs/Permissions",
          "description": "Permissions the identity has for keys, secrets and certificates."
        }
      },
      "required": [
        "tenantId",
        "objectId",
        "permissions"
      ]
    },
    "ActionsRequired": {
      "type": "string",
      "description": "A message indicating if changes on the service provider require any updates on the consumer.",
      "enum": [
        "None"
      ],
      "x-ms-enum": {
        "name": "ActionsRequired",
        "modelAsString": true,
        "values": [
          {
            "name": "None",
            "value": "None"
          }
        ]
      }
    },
    "Azure.Core.eTag": {
      "type": "string",
      "description": "The ETag (or entity tag) HTTP response header is an identifier for a specific version of a resource.\nIt lets caches be more efficient and save bandwidth, as a web server does not need to resend a full response if the content was not changed.\n\nIt is a string of ASCII characters placed between double quotes, like \"675af34563dc-tr34\"."
    },
    "Azure.Core.uuid": {
      "type": "string",
      "format": "uuid",
      "description": "Universally Unique Identifier"
    },
    "CertificatePermissions": {
      "type": "string",
      "enum": [
        "all",
        "get",
        "list",
        "delete",
        "create",
        "import",
        "update",
        "managecontacts",
        "getissuers",
        "listissuers",
        "setissuers",
        "deleteissuers",
        "manageissuers",
        "recover",
        "purge",
        "backup",
        "restore"
      ],
      "x-ms-enum": {
        "name": "CertificatePermissions",
        "modelAsString": true,
        "values": [
          {
            "name": "all",
            "value": "all"
          },
          {
            "name": "get",
            "value": "get"
          },
          {
            "name": "list",
            "value": "list"
          },
          {
            "name": "delete",
            "value": "delete"
          },
          {
            "name": "create",
            "value": "create"
          },
          {
            "name": "import",
            "value": "import"
          },
          {
            "name": "update",
            "value": "update"
          },
          {
            "name": "managecontacts",
            "value": "managecontacts"
          },
          {
            "name": "getissuers",
            "value": "getissuers"
          },
          {
            "name": "listissuers",
            "value": "listissuers"
          },
          {
            "name": "setissuers",
            "value": "setissuers"
          },
          {
            "name": "deleteissuers",
            "value": "deleteissuers"
          },
          {
            "name": "manageissuers",
            "value": "manageissuers"
          },
          {
            "name": "recover",
            "value": "recover"
          },
          {
            "name": "purge",
            "value": "purge"
          },
          {
            "name": "backup",
            "value": "backup"
          },
          {
            "name": "restore",
            "value": "restore"
          }
        ]
      }
    },
    "CreateMode": {
      "type": "string",
      "description": "The vault's create mode to indicate whether the vault need to be recovered or not.",
      "enum": [
        "recover",
        "default"
      ],
      "x-ms-enum": {
        "name": "CreateMode",
        "modelAsString": false
      }
    },
    "IPRule": {
      "type": "object",
      "description": "A rule governing the accessibility of a vault from a specific ip address or ip range.",
      "properties": {
        "value": {
          "type": "string",
          "description": "An IPv4 address range in CIDR notation, such as '124.56.78.91' (simple IP address) or '124.56.78.0/24' (all addresses that start with 124.56.78)."
        }
      },
      "required": [
        "value"
      ]
    },
    "KeyPermissions": {
      "type": "string",
      "enum": [
        "all",
        "encrypt",
        "decrypt",
        "wrapKey",
        "unwrapKey",
        "sign",
        "verify",
        "get",
        "list",
        "create",
        "update",
        "import",
        "delete",
        "backup",
        "restore",
        "recover",
        "purge",
        "release",
        "rotate",
        "getrotationpolicy",
        "setrotationpolicy"
      ],
      "x-ms-enum": {
        "name": "KeyPermissions",
        "modelAsString": true,
        "values": [
          {
            "name": "all",
            "value": "all"
          },
          {
            "name": "encrypt",
            "value": "encrypt"
          },
          {
            "name": "decrypt",
            "value": "decrypt"
          },
          {
            "name": "wrapKey",
            "value": "wrapKey"
          },
          {
            "name": "unwrapKey",
            "value": "unwrapKey"
          },
          {
            "name": "sign",
            "value": "sign"
          },
          {
            "name": "verify",
            "value": "verify"
          },
          {
            "name": "get",
            "value": "get"
          },
          {
            "name": "list",
            "value": "list"
          },
          {
            "name": "create",
            "value": "create"
          },
          {
            "name": "update",
            "value": "update"
          },
          {
            "name": "import",
            "value": "import"
          },
          {
            "name": "delete",
            "value": "delete"
          },
          {
            "name": "backup",
            "value": "backup"
          },
          {
            "name": "restore",
            "value": "restore"
          },
          {
            "name": "recover",
            "value": "recover"
          },
          {
            "name": "purge",
            "value": "purge"
          },
          {
            "name": "release",
            "value": "release"
          },
          {
            "name": "rotate",
            "value": "rotate"
          },
          {
            "name": "getrotationpolicy",
            "value": "getrotationpolicy"
          },
          {
            "name": "setrotationpolicy",
            "value": "setrotationpolicy"
          }
        ]
      }
    },
    "NetworkRuleAction": {
      "type": "string",
      "description": "The default action when no rule from ipRules and from virtualNetworkRules match. This is only used after the bypass property has been evaluated.",
      "enum": [
        "Allow",
        "Deny"
      ],
      "x-ms-enum": {
        "name": "NetworkRuleAction",
        "modelAsString": true,
        "values": [
          {
            "name": "Allow",
            "value": "Allow"
          },
          {
            "name": "Deny",
            "value": "Deny"
          }
        ]
      }
    },
    "NetworkRuleBypassOptions": {
      "type": "string",
      "description": "Tells what traffic can bypass network rules. This can be 'AzureServices' or 'None'.  If not specified the default is 'AzureServices'.",
      "enum": [
        "AzureServices",
        "None"
      ],
      "x-ms-enum": {
        "name": "NetworkRuleBypassOptions",
        "modelAsString": true,
        "values": [
          {
            "name": "AzureServices",
            "value": "AzureServices"
          },
          {
            "name": "None",
            "value": "None"
          }
        ]
      }
    },
    "NetworkRuleSet": {
      "type": "object",
      "description": "A set of rules governing the network accessibility of a vault.",
      "properties": {
        "bypass": {
          "$ref": "#/$defs/NetworkRuleBypassOptions",
          "description": "Tells what traffic can bypass network rules. This can be 'AzureServices' or 'None'.  If not specified the default is 'AzureServices'."
        },
        "defaultAction": {
          "$ref": "#/$defs/NetworkRuleAction",
          "description": "The default action when no rule from ipRules and from virtualNetworkRules match. This is only used after the bypass property has been evaluated."
        },
        "ipRules": {
          "type": "array",
          "description": "The list of IP address rules.",
          "items": {
            "$ref": "#/$defs/IPRule"
          },
          "x-ms-identifiers": []
        },
        "virtualNetworkRules": {
          "type": "array",
          "description": "The list of virtual network rules.",
          "items": {
            "$ref": "#/$defs/VirtualNetworkRule"
          },
          "x-ms-identifiers": [
            "id"
          ]
        }
      }
    },
    "Permissions": {
      "type": "object",
      "description": "Permissions the identity has for keys, secrets, certificates and storage.",
      "properties": {
        "keys": {
          "type": "array",
          "description": "Permissions to keys",
          "items": {
            "$ref": "#/$defs/KeyPermissions"
          }
        },
        "secrets": {
          "type": "array",
          "description": "Permissions to secrets",
          "items": {
            "$ref": "#/$defs/SecretPermissions"
          }
        },
        "certificates": {
          "type": "array",
          "description": "Permissions to certificates",
          "items": {
            "$ref": "#/$defs/CertificatePermissions"
          }
        },
        "storage": {
          "type": "array",
          "description": "Permissions to storage accounts",
          "items": {
            "$ref": "#/$defs/StoragePermissions"
          }
        }
      }
    },
    "PrivateEndpoint": {
      "type": "object",
      "description": "Private endpoint object properties.",
      "properties": {
        "id": {
          "type": "string",
          "description": "Full identifier of the private endpoint resource.",
          "readOnly": true
        }
      }
    },
    "PrivateEndpointConnectionItem": {
      "type": "object",
      "description": "Private endpoint connection item.",
      "properties": {
        "id": {
          "type": "string",
          "description": "Id of private endpoint connection."
        },
        "etag": {
          "$ref": "#/$defs/Azure.Core.eTag",
          "description": "Modified whenever there is a change in the state of private endpoint connection."
        },
        "properties": {
          "$ref": "#/$defs/PrivateEndpointConnectionProperties",
          "description": "Private endpoint connection properties.",
          "x-ms-client-flatten": true
        }
      }
    },
    "PrivateEndpointConnectionProperties": {
      "type": "object",
      "description": "Properties of the private endpoint connection resource.",
      "properties": {
        "privateEndpoint": {
          "$ref": "#/$defs/PrivateEndpoint",
          "description": "Properties of the private endpoint object."
        },
        "privateLinkServiceConnectionState": {
          "$ref": "#/$defs/PrivateLinkServiceConnectionState",
          "description": "Approval state of the private link connection."
        },
        "provisioningState": {
          "$ref": "#/$defs/PrivateEndpointConnectionProvisioningState",
          "description": "Provisioning state of the private endpoint connection.",
          "readOnly": true
        }
      }
    },
    "PrivateEndpointConnectionProvisioningState": {
      "type": "string",
      "description": "The current provisioning state.",
      "enum": [
        "Succeeded",
        "Creating",
        "Updating",
        "Deleting",
        "Failed",
        "Disconnected"
      ],
      "x-ms-enum": {
        "name": "PrivateEndpointConnectionProvisioningState",
        "modelAsString": true,
        "values": [
          {
            "name": "Succeeded",
            "value": "Succeeded"
          },
          {
            "name": "Creating",
            "value": "Creating"
          },
          {
            "name": "Updating",
            "value": "Updating"
          },
          {
            "name": "Deleting",
            "value": "Deleting"
          },
          {
            "name": "Failed",
            "value": "Failed"
          },
          {
            "name": "Disconnected",
            "value": "Disconnected"
          }
        ]
      },
      "readOnly": true
    },
    "PrivateEndpointServiceConnectionStatus": {
      "type": "string",
      "description": "The private endpoint connection status.",
      "enum": [
        "Pending",
        "Approved",
        "Rejected",
        "Disconnected"
      ],
      "x-ms-enum": {
        "name": "PrivateEndpointServiceConnectionStatus",
        "modelAsString": true,
        "values": [
          {
            "name": "Pending",
            "value": "Pending"
          },
          {
            "name": "Approved",
            "value": "Approved"
          },
          {
            "name": "Rejected",
            "value": "Rejected"
          },
          {
            "name": "Disconnected",
            "value": "Disconnected"
          }
        ]
      }
    },
    "PrivateLinkServiceConnectionState": {
      "type": "object",
      "description": "An object that represents the approval state of the private link connection.",
      "properties": {
        "status": {
          "$ref": "#/$defs/PrivateEndpointServiceConnectionStatus",
          "description": "Indicates whether the connection has been approved, rejected or removed by the key vault owner."
        },
        "description": {
          "type": "string",
          "description": "The reason for approval or rejection."
        },
        "actionsRequired": {
          "$ref": "#/$defs/ActionsRequired",
          "description": "A message indicating if changes on the service provider require any updates on the consumer."
        }
      }
    },
    "SecretPermissions": {
      "type": "string",
      "enum": [
        "all",
        "get",
        "list",
        "set",
        "delete",
        "backup",
        "restore",
        "recover",
        "purge"
      ],
      "x-ms-enum": {
        "name": "SecretPermissions",
        "modelAsString": true,
        "values": [
          {
            "name": "all",
            "value": "all"
          },
          {
            "name": "get",
            "value": "get"
          },
          {
            "name": "list",
            "value": "list"
          },
          {
            "name": "set",
            "value": "set"
          },
          {
            "name": "delete",
            "value": "delete"
          },
          {
            "name": "backup",
            "value": "backup"
          },
          {
            "name": "restore",
            "value": "restore"
          },
          {
            "name": "recover",
            "value": "recover"
          },
          {
            "name": "purge",
            "value": "purge"
          }
        ]
      }
    },
    "Sku": {
      "type": "object",
      "description": "SKU details",
      "properties": {
        "family": {
          "$ref": "#/$defs/SkuFamily",
          "description": "SKU family name"
        },
        "name": {
          "$ref": "#/$defs/SkuName",
          "description": "SKU name to specify whether the key vault is a standard vault or a premium vault."
        }
      },
      "required": [
        "family",
        "name"
      ]
    },
    "SkuFamily": {
      "type": "string",
      "description": "SKU family name",
      "enum": [
        "A"
      ],
      "x-ms-enum": {
        "name": "SkuFamily",
        "modelAsString": true,
        "values": [
          {
            "name": "A",
            "value": "A"
          }
        ]
      }
    },
    "SkuName": {
      "type": "string",
      "description": "SKU name to specify whether the key vault is a standard vault or a premium vault.",
      "enum": [
        "standard",
        "premium"
      ],
      "x-ms-enum": {
        "name": "SkuName",
        "modelAsString": false
      }
    },
    "StoragePermissions": {
      "type": "string",
      "enum": [
        "all",
        "get",
        "list",
        "delete",
        "set",
        "update",
        "regeneratekey",
        "recover",
        "purge",
        "backup",
        "restore",
        "setsas",
        "listsas",
        "getsas",
        "deletesas"
      ],
      "x-ms-enum": {
        "name": "StoragePermissions",
        "modelAsString": true,
        "values": [
          {
            "name": "all",
            "value": "all"
          },
          {
            "name": "get",
            "value": "get"
          },
          {
            "name": "list",
            "value": "list"
          },
          {
            "name": "delete",
            "value": "delete"
          },
          {
            "name": "set",
            "value": "set"
          },
          {
            "name": "update",
            "value": "update"
          },
          {
            "name": "regeneratekey",
            "value": "regeneratekey"
          },
          {
            "name": "recover",
            "value": "recover"
          },
          {
            "name": "purge",
            "value": "purge"
          },
          {
            "name": "backup",
            "value": "backup"
          },
          {
            "name": "restore",
            "value": "restore"
          },
          {
            "name": "setsas",
            "value": "setsas"
          },
          {
            "name": "listsas",
            "value": "listsas"
          },
          {
            "name": "getsas",
            "value": "getsas"
          },
          {
            "name": "deletesas",
            "value": "deletesas"
          }
        ]
      }
    },
    "VaultProperties": {
      "type": "object",
      "description": "Properties of the vault",
      "properties": {
        "tenantId": {
          "$ref": "#/$defs/Azure.Core.uuid",
          "description": "The Azure Active Directory tenant ID that should be used for authenticating requests to the key vault."
        },
        "sku": {
          "$ref": "#/$defs/Sku",
          "description": "SKU details"
        },
        "accessPolicies": {
          "type": "array",
          "description": "An array of 0 to 1024 identities that have access to the key vault. All identities in the array must use the same tenant ID as the key vault's tenant ID. When `createMode` is set to `recover`, access policies are not required. Otherwise, access policies are required.",
          "items": {
            "$ref": "#/$defs/AccessPolicyEntry"
          },
          "x-ms-identifiers": [
            "tenantId",
            "objectId",
            "permissions"
          ]
        },
        "vaultUri": {
          "type": "string",
          "description": "The URI of the vault for performing operations on keys and secrets."
        },
        "hsmPoolResourceId": {
          "type": "string",
          "description": "The resource id of HSM Pool.",
          "readOnly": true
        },
        "enabledForDeployment": {
          "type": "boolean",
          "description": "Property to specify whether Azure Virtual Machines are permitted to retrieve certificates stored as secrets from the key vault.",
          "default": false
        },
        "enabledForDiskEncryption": {
          "type": "boolean",
          "description": "Property to specify whether Azure Disk Encryption is permitted to retrieve secrets from the vault and unwrap keys.",
          "default": false
        },
        "enabledForTemplateDeployment": {
          "type": "boolean",
          "description": "Property to specify whether Azure Resource Manager is permitted to retrieve secrets from the key vault.",
          "default": false
        },
        "enableSoftDelete": {
          "type": "boolean",
          "description": "Property to specify whether the 'soft delete' functionality is enabled for this key vault. If it's not set to any value(true or false) when creating new key vault, it will be set to true by default. Once set to true, it cannot be reverted to false.",
          "default": true
        },
        "softDeleteRetentionInDays": {
          "type": "integer",
          "format": "int32",
          "description": "softDelete data retention days. It accepts >=7 and <=90.",
          "default": 90
        },
        "enableRbacAuthorization": {
          "type": "boolean",
          "description": "Property that controls how data actions are authorized. When true, the key vault will use Role Based Access Control (RBAC) for authorization of data actions, and the access policies specified in vault properties will be  ignored. When false, the key vault will use the access policies specified in vault properties, and any policy stored on Azure Resource Manager will be ignored. If null or not specified, the vault is created with the default value of false. Note that management actions are always authorized with RBAC.",
          "default": true
        },
        "createMode": {
          "$ref": "#/$defs/CreateMode",
          "description": "The vault's create mode to indicate whether the vault need to be recovered or not.",
          "x-ms-mutability": [
            "update",
            "create"
          ]
        },
        "enablePurgeProtection": {
          "type": "boolean",
          "description": "Property specifying whether protection against purge is enabled for this vault. Setting this property to true activates protection against purge for this vault and its content - only the Key Vault service may initiate a hard, irrecoverable deletion. The setting is effective only if soft delete is also enabled. Enabling this functionality is irreversible - that is, the property does not accept false as its value."
        },
        "networkAcls": {
          "$ref": "#/$defs/NetworkRuleSet",
          "description": "Rules governing the accessibility of the key vault from specific network locations."
        },
        "provisioningState": {
          "$ref": "#/$defs/VaultProvisioningState",
          "description": "Provisioning state of the vault."
        },
        "privateEndpointConnections": {
          "type": "array",
          "description": "List of private endpoint connections associated with the key vault.",
          "items": {
            "$ref": "#/$defs/PrivateEndpointConnectionItem"
          },
          "readOnly": true
        },
        "publicNetworkAccess": {
          "type": "string",
          "description": "Property to specify whether the vault will accept traffic from public internet. If set to 'disabled' all traffic except private endpoint traffic and that that originates from trusted services will be blocked. This will override the set firewall rules, meaning that even if the firewall rules are present we will not honor the rules.",
          "default": "enabled"
        }
      },
      "required": [
        "tenantId",
        "sku"
      ]
    },
    "VaultProvisioningState": {
      "type": "string",
      "description": "Provisioning state of the vault.",
      "enum": [
        "Succeeded",
        "RegisteringDns"
      ],
      "x-ms-enum": {
        "name": "VaultProvisioningState",
        "modelAsString": true,
        "values": [
          {
            "name": "Succeeded",
            "value": "Succeeded"
          },
          {
            "name": "RegisteringDns",
            "value": "RegisteringDns"
          }
        ]
      }
    },
    "VirtualNetworkRule": {
      "type": "object",
      "description": "A rule governing the accessibility of a vault from a specific virtual network.",
      "properties": {
        "id": {
          "type": "string",
          "description": "Full resource id of a vnet subnet, such as '/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/subnet1'."
        },
        "ignoreMissingVnetServiceEndpoint": {
          "type": "boolean",
          "description": "Property to specify whether NRP will ignore the check if parent subnet has serviceEndpoints configured."
        }
      },
      "required": [
        "id"
      ]
    }
  }
}