Reporting Kubernetes Version

Hello Kubernetes,
For a business need we need to report the Kubernetes version through C# development.
Based on my search and tries I cannot find a proper way to get that version.
Is there any DotNet Api for that or even a way to run the cmd “kubectl version” via pod?

Not sure if there is something built-in in the SDK, but you can probably do an equivalent of the following using a standard HTTP client:

curl --cacert /var/run/secrets/kubernetes.io/serviceaccount/ca.crt -X GET https://kubernetes.default.svc/version