I am using azure REST and getting below response as
{
"Code": "BadRequest",
"Message": "The parameter properties has an invalid value.",
"Target": null,
"Details": [
{
"Message": "The parameter properties has an invalid value."
},
{
"Code": "BadRequest"
},
{
"ErrorEntity": {
"ExtendedCode": "51008",
"MessageTemplate": "The parameter {0} has an invalid value.",
"Parameters": [
"properties"
],
"Code": "BadRequest",
"Message": "The parameter properties has an invalid value."
}
}
],
"Innererror": null
}
unable to find invalid value.
below are my request sample
PUT https://management.azure.com/subscriptions/{subscriptionID}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}?api-version=2016-08-01
Authorization: Bearer {access_token}
Content-type: application/json
Body
{
"location":"North Europe"
}
@gauravbhavsar The error is not very intuitive. You are running into this because the body has no "properties" property.
{
"type": "Microsoft.Web/sites",
"location":"North Europe",
"properties" : {
"serverFarmId": "Server Farm Resource Id",
}
}
Most helpful comment
@gauravbhavsar The error is not very intuitive. You are running into this because the body has no "properties" property.
{
"type": "Microsoft.Web/sites",
"location":"North Europe",
"properties" : {
"serverFarmId": "Server Farm Resource Id",
}
}