Federated Identity credentials auth in azure table sdk

SanaCMSFT-8922 301 Reputation points

I was trying to use FIC creds for table sdk but was getting the following issue:

CredentialUnavailableError: ManagedIdentityCredential authentication unavailable, no response from the IMDS endpoint.

This is the doc I am following for FIC credential setup(Python code): https://learn.microsoft.com/en-us/identity/microsoft-identity-platform/federated-identity-credentials?branch=main&tabs=python#library-api

And this link as reference to provide credentials to table sdk:


As FIC is not mentioned in table sdk doc, I am getting the credentials using first doc and the using those credentials using second doc as reference.

And this python code is being used in a synapse notebook.

What could be the reason for this error? Is it that FIC is not supported or something else?

Azure Table Storage
Azure Table Storage
An Azure service that stores structured NoSQL data in the cloud.
162 questions
Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
4,572 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Amira Bedhiafi 18,261 Reputation points

    This issue is common in environments where IMDS is not available, such as in local development environments or when the managed identity is not properly configured or supported.

    Since FIC might not be directly supported in the Azure Table SDK documentation, you can use the DefaultAzureCredential which supports various authentication methods, including managed identity and Azure AD tokens.

    Check this resource for more information and how to configure your local environment: https://learn.microsoft.com/en-us/azure/developer/python/configure-local-development-environment

    You can see the list of credential types that DefaultAzureCredential() goes through in the Azure docs.

    More links :