I was struggling to make a dedicated sql pool pause automatically through a pipeline on non working hours. Although there are some options that you can use with az cli, it seemed that they could not work with an error that indicated resource could not be found.
Searching further I found that this action can be performed through the azure management API an example of which is shown below.
In order to stop a dedicated sql pool (formerly SQL DW) you can follow the below guide that uses az cli to get an access token.
az account get-access-token
Add this token on Authorization tab with Bearer type and make your request.
By checking the result you can see that pause is completed sucesfully.
You can also automate the procedure using an Azure DevOps pipeline.