In case you cant access to shared sheets via your code.
make sure to create a service account , copy the "email" for this service account.
make sure the one who shared the file, share it with your service account email.
and it should work.
working with API_KEY on shared sheets get failure.
only service account.
access to your own sheets could be done via api_key or service account.
links:
https://developers.google.com/api-client-library/dotnet/guide/aaa_oauth#web-applications-aspnet-mvc
https://cloud.google.com/docs/authentication/production
https://developers.google.com/sheets/api/quickstart/dotnet
Enjoy
Yaniv