Lately I faced the following challenge. I wanted to analyze the requests sent by a .NET Web API application to the underlying Cosmos DB to get insights about the RU consumption (RU = request units, for more details see here) of the different Cosmos DB operations. Whenever you call Cosmos DB via HTTP API – what I basically do but the HTTP calls are performed by library Microsoft.EntityFrameworkCore.Cosmos
and I couldn’t find a way to intercept them – the Cosmos DB service returns a header called x-ms-request-charge
in the response which indicates the costs of the performed operation.
Telerik Fiddler Classic to the rescue I thought… but first it didn’t work and I couldn’t make it work until I changed the launch profile of the .NET Web API in Visual Studio to IIS Express
and set up a proxy according to the docs.
Briefly summarized, I had to perform the following steps:
- Change launch profile of .NET Web API in Visual Studio to
IIS Express
- Enable
Decrypt HTTPS traffic
setting in Fiddler (Tools
>Options
) - Set up proxy (see here)
Important: start cmd as administrator to successfully set up the proxy

IIS Express

Decrypt HTTPS traffic
in Fiddler optionsAfter that I could finally intercept the requests of my .NET Web API to the underlying Cosmos DB and I got some valuable insights I couldn’t get from the Cosmos DB account insights in the azure portal.

Leave a Reply