I have a C# application that writes traces and exceptions to Azure Application Insights using Microsoft.ApplicationInsights and the TelemetryClient class.
I want to programmatically search the AI trace and exception logs using C#, as opposed to having to use Kusto queries. Every article I've read on how to do this seems to require that I know the Client Secret for the resource. But I am unable to obtain this, as I don't have authorization to create certificates and secrets in our environment. (I do, however, possess the InstrumentationKey from the ApplicationInsights.config file).
I'm sure there has to be a way to do this without using a secret - right? After all, TelemetryClient doesn't require a secret to write to AI logs (it just needs the aforementioned InstrumentationKey); therefore (since reading is a less risky operation security-wise than writing), I would assume that there's a way to programmatically read the logs with just an InstrumentationKey and without a client secret. Can you please tell me how to do this?