Skip to content
Original file line number Diff line number Diff line change
@@ -0,0 +1,356 @@
{
"swagger": "2.0",
"info": {
"title": "NetworkManagementClient",
"description": "The Microsoft Azure Network management API provides a RESTful set of web services that interact with Microsoft Azure Networks service to manage your network resources. The API has entities that capture the relationship between an end user and the Microsoft Azure Networks service.",
"version": "2018-11-01"
},
"host": "management.azure.com",
"schemes": [
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"security": [
{
"azure_auth": [
"user_impersonation"
]
}
],
"securityDefinitions": {
"azure_auth": {
"type": "oauth2",
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
"flow": "implicit",
"description": "Azure Active Directory OAuth2 Flow",
"scopes": {
"user_impersonation": "impersonate your user account"
}
}
},
"paths": {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PATCH missing. Looks like this is a tracked resource and so PATCH support is required.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you clarify please?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@seyedfayaz all tracked resources (that support tags) need a PATCH api that supports granular property update, at least covering the tags property. See the RPC

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have added the PATCH API to update the tags

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

List API to list all ddosCustomPOlicies under the resource group and under the subscription are missing.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are not currently supporting the list API. We are planning to add this as a part of next version.

"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/ddosCustomPolicies/{ddosCustomPolicyName}": {
"delete": {
"tags": [
"ddosCustomPolicies"
],
"operationId": "DdosCustomPolicies_Delete",
"description": "Deletes the specified DDoS custom policy.",
"parameters": [
{
"name": "resourceGroupName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the resource group."
},
{
"name": "ddosCustomPolicyName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the DDoS custom policy."
},
{
"$ref": "./network.json#/parameters/ApiVersionParameter"
},
{
"$ref": "./network.json#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"204": {
"description": "Request successful. Resource does not exist."
},
"202": {
"description": "Accepted and the operation will complete asynchronously."
},
"200": {
"description": "Delete successful."
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-long-running-operation": true,
"x-ms-examples": {
"Delete DDoS custom policy": {
"$ref": "./examples/DdosCustomPolicyDelete.json"
}
}
},
"get": {
"tags": [
"ddosCustomPolicies"
],
"operationId": "DdosCustomPolicies_Get",
"description": "Gets information about the specified DDoS custom policy.",
"parameters": [
{
"name": "resourceGroupName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the resource group."
},
{
"name": "ddosCustomPolicyName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the DDoS custom policy."
},
{
"$ref": "./network.json#/parameters/ApiVersionParameter"
},
{
"$ref": "./network.json#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "Request successful. The operation returns the specified DDoS custom policy resource.",
"schema": {
"$ref": "#/definitions/DdosCustomPolicy"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-examples": {
"Get DDoS custom policy": { "$ref": "./examples/DdosCustomPolicyGet.json" }
}
},
"put": {
"tags": [
"ddosCustomPolicies"
],
"operationId": "DdosCustomPolicies_CreateOrUpdate",
"description": "Creates or updates a DDoS custom policy.",
"parameters": [
{
"name": "resourceGroupName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the resource group."
},
{
"name": "ddosCustomPolicyName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the DDoS custom policy."
},
{
"name": "parameters",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/DdosCustomPolicy"
},
"description": "Parameters supplied to the create or update operation."
},
{
"$ref": "./network.json#/parameters/ApiVersionParameter"
},
{
"$ref": "./network.json#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"201": {
"description": "Create successful. The operation returns the resulting DDoS custom policy resource.",
"schema": {
"$ref": "#/definitions/DdosCustomPolicy"
}
},
"200": {
"description": "Update successful. The operation returns the resulting DDoS custom policy resource.",
"schema": {
"$ref": "#/definitions/DdosCustomPolicy"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-long-running-operation": true,
"x-ms-examples": {
"Create DDoS custom policy": {
"$ref": "./examples/DdosCustomPolicyCreate.json"
}
}
}
}
},
"definitions": {
"DdosCustomPolicy": {
"description": "A DDoS custom policy in a resource group.",
"x-ms-azure-resource": true,
"properties": {
"id": {
"readOnly": true,
"type": "string",
"description": "Resource ID."
},
"name": {
"readOnly": true,
"type": "string",
"description": "Resource name."
},
"type": {
"readOnly": true,
"type": "string",
"description": "Resource type."
},
"tags": {
"type": "object",
"additionalProperties": {
"type": "string"
},
"description": "Resource tags."
},
"properties": {
"x-ms-client-flatten": true,
"$ref": "#/definitions/DdosCustomPolicyPropertiesFormat",
"description": "Properties of the DDoS custom policy."
},
"etag": {
"readOnly": true,
"type": "string",
"description": "A unique read-only string that changes whenever the resource is updated."
}
},
"allOf":[
{
"$ref":"./network.json#/definitions/Resource"
}
]
},
"DdosCustomPolicyPropertiesFormat": {
"properties": {
"resourceGuid": {
"readOnly": true,
"type": "string",
"description": "The resource GUID property of the DDoS custom policy resource. It uniquely identifies the resource, even if the user changes its name or migrate the resource across subscriptions or resource groups."
},
"provisioningState": {
"readOnly": true,
"type": "string",
"description": "The provisioning state of the DDoS custom policy resource. Possible values are: 'Succeeded', 'Updating', 'Deleting', and 'Failed'."
},
"publicIPAddresses": {
"readOnly": true,
"type": "array",
"items": {
"$ref": "./network.json#/definitions/SubResource"
},
"description": "The list of public IPs associated with the DDoS custom policy resource. This list is read-only."
},
"protocolCustomSettings": {
"readOnly": false,
"type": "array",
"items": {
"$ref": "#/definitions/ProtocolCustomSettingsFormat"
},
"description": "The protocol-specific DDoS policy customization parameters."
}
},
"description": "DDoS custom policy properties."
},
"ProtocolCustomSettingsFormat": {
"properties": {
"protocol": {
"readOnly": false,
"type": "string",
"enum": [
"Tcp",
"Udp",
"Syn"
],
"x-ms-enum": {
"name": "The protocol for which the DDoS protection policy is being customized.",
"modelAsString": true
},
"description": "The protocol for which the DDoS protection policy is being customized."
},
"triggerRateOverride": {
"readOnly": false,
"type": "string",
"description": "The customized DDoS protection trigger rate."
},
"sourceRateOverride": {
"readOnly": false,
"type": "string",
"description": "The customized DDoS protection source rate."
},
"triggerSensitivityOverride": {
"readOnly": false,
"type": "string",
"enum": [
"Relaxed",
"Low",
"Default",
"High"
],
"x-ms-enum": {
"name": "The customized DDoS protection trigger rate sensitivity degrees. High: Trigger rate set with most sensitivity w.r.t. normal traffic. Default: Trigger rate set with moderate sensitivity w.r.t. normal traffic. Low: Trigger rate set with less sensitivity w.r.t. normal traffic. Relaxed: Trigger rate set with least sensitivity w.r.t. normal traffic.",
"modelAsString": true
},
"description": "The customized DDoS protection trigger rate sensitivity degrees. High: Trigger rate set with most sensitivity w.r.t. normal traffic. Default: Trigger rate set with moderate sensitivity w.r.t. normal traffic. Low: Trigger rate set with less sensitivity w.r.t. normal traffic. Relaxed: Trigger rate set with least sensitivity w.r.t. normal traffic."
}
},
"description": "DDoS custom policy properties."
},
"CloudError": {
"x-ms-external": true,
"properties": {
"error": {
"$ref": "#/definitions/CloudErrorBody"
}
},
"description": "An error response from the Batch service."
},
"CloudErrorBody": {
"x-ms-external": true,
"properties": {
"code": {
"type": "string",
"description": "An identifier for the error. Codes are invariant and are intended to be consumed programmatically."
},
"message": {
"type": "string",
"description": "A message describing the error, intended to be suitable for display in a user interface."
},
"target": {
"type": "string",
"description": "The target of the particular error. For example, the name of the property in error."
},
"details": {
"type": "array",
"items": {
"$ref": "#/definitions/CloudErrorBody"
},
"description": "A list of additional details about the error."
}
},
"description": "An error response from the Batch service."
}
}
}
Loading