- Copied the exact database resource part from the ARM template from the deployment that succeeded with the portal.
- Removed the line that had to do with "publicMaintenanceConfigurations", that was because of another problem I had with access to scopes from the service principal.
- Left everything intact except:
a. the "type", because it was a nested resource in my ARM template
b. the servername, because i needed that from a parameter
c. the databasename , because i needed that from a parameter
d. the dependencies, because it was a nested resource in my ARM template
Why do I get "The api-version query parameter (?api-version=) is required for all requests." when deploying azure SQL database through portal?
Today i tried deploying an azure SQL database with an ARM template through PowerShell. The deployment didn't finish in 40 minutes and i decided to cancel.
Then i tried deploying the same (sql server and sql database) from the portal and here also the deployment didn't finish.
When i look in "operation details" there is a "bad request":
status message:
{
"status": "Failed",
"error": {
"code": "MissingApiVersionParameter",
"message": "The api-version query parameter (?api-version=) is required for all requests."
}
}
How can this be when deploying from portal?
And how to fix it?
UPDATE1:
Tried to replicate with new deployment in new resourcegroup, new server and new database.
No error.
So must be something in the first setup.
UPDATE2:
I don't know exactly why, but the problem seems to be solved. There is another issue right now with deploying my ARM template resources. But the issue with the API-version query parameter is no longer there.
UPDATE3:
Problem still persist.
I just introduced a new problem when copying lines from the complete powershell deployment to my ARM template.
UPDATE4:
I changed all the "apiVersion" instances to "2014-01-01" and got the following informative error:
{
"status": "Failed",
"error": {
"code": "BadRequest",
"message": "An error occurred while processing this request.",
"details": []
}
}
UPDATE5:
Possibly, though the portal does allow it, the error is created by using the "#" in the database name. So far I was able to create, with the portal a database called "jenkins-389". When I tried "jenkins-#389" I got the error:
{
"status": "Failed",
"error": {
"code": "MissingApiVersionParameter",
"message": "The api-version query parameter (?api-version=) is required for all requests."
}
}
UPDATE6:
The removal of the "#" from the database name only returned me to the error:
{
"status": "Failed",
"error": {
"code": "BadRequest",
"message": "An error occurred while processing this request.",
"details": []
}
}
1 answer
Sort by: Most helpful
-
mrblonde 216 Reputation points
2021-02-13T08:44:30.847+00:00