azure-identity-py
Azure Identity SDK for Python authentication with Microsoft Entra ID.
Skill by Microsoft
Chalk Labs
Need help deploying azure-identity-py?
Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/magrathean-uk-azure-identity-py
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: cloud
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions: not checked yet.
What's inside
- Skill name
azure-identity-py- Description
- Azure Identity SDK for Python authentication with Microsoft Entra ID. Use for DefaultAzureCredential, managed identity, service principals, and token caching. Triggers: "azure-identity", "DefaultAzureCredential", "authentication", "managed identity", "service principal", "credential".
- License
- MIT
- Metadata
- author: Microsoft · package: azure-identity · version: 1.0.0
- Instructions
- 511 lines in SKILL.md · view on GitHub
Agent Skills spec issues
- body: 511 lines (spec recommends under 500)
Files (1)
- SKILL.md
SKILL.md (first lines)
# Azure Identity library for Python
Authentication library for Azure SDK clients using Microsoft Entra ID.
Use this skill when:
- An app needs to authenticate to Azure services from Python
- You need `DefaultAzureCredential` for local dev + Azure deployment
- You need `ManagedIdentityCredential` for Azure-hosted workloads
- You need service principal auth with secret or certificate
- You need direct token acquisition with `get_token()`
- You need to troubleshoot credential chain failures
## Installation
```bash
pip install azure-identity
```
For VS Code or broker-based desktop auth:
```bash
pip install azure-identity-broker
```
## Python Version
`azure-identity` supports Python 3.9+.
## Environment Variables
```bash
# Service principal with client secret
AZURE_TENANT_ID=<your-tenant-id>
AZURE_CLIENT_ID=<your-client-id>
AZURE_CLIENT_SECRET=<your-client-secret>
# Service principal with certificate
AZURE_TENANT_ID=<your-tenant-id>
AZURE_CLIENT_ID=<your-client-id>
AZURE_CLIENT_CERTIFICATE_PATH=/path/to/cert.pem
AZURE_CLIENT_CERTIFICATE_PASSWORD=<optional-password>
# Authority (sovereign clouds)
AZURE_AUTHORITY_HOST=login.microsoftonline.com # Default; or login.chinacloudapi.cn, login.microsoftonline.us
# User-assigned managed identity
AZURE_CLIENT_ID=<managed-identity-client-id>
# Credential selection (new)
AZURE_TOKEN_CREDENTIALS=dev|prod|<credential-name> # Optional, restricts DAC chain
```
## DefaultAzureCredential
The recommended credential for most scenarios. Tries multiple authentication methods in order:
```python
from azure.identity import DefaultAzureCredential
from azure.storage.blob import BlobServiceClient
# Works in local dev AND production without code changes
credential = DefaultAzureCredential()
client = BlobServiceClient(
account_url="https://<account>.blob.core.windows.net",
credential=credential
)
```
### Credential Chain Order
See [DefaultAzureCredential overview](https://aka.ms/azsdk/python/identity/credential-chains#defaultazurecredential-overview) for the current credential chain order and defaults.
### Customizing DefaultAzureCredential
```python
# Exclude credentials you don't need
credential = DefaultAzureCredential(
exclude_environment_credential=True,
exclude_shared_token_cache_credential=True,
managed_identity_client_id="<user-assigned-mi-client-id>" # For user-assigned MI (also accepts object ID or resource ID)
)
# Enable interactive browser (disabled by default)
credential = DefaultAzureCredential(
exclude_interactive_browser_credential=False
)
# Set subprocess timeout for CLI-based credentials (default: 10s)
credential = DefaultAzureCredential(process_timeout=30)
# Require AZURE_TOKEN_CREDENTIALS env var to be set
credential = DefaultAzureCredential(require_envvar=True)
```
### Exclude Parameters
| Parameter | Default | Effect |
|-----------|---------|--------|
| `exclude_environment_credential` | False | Skip env-var-based auth |
| `exclude_workload_identity_credential` | False | Skip Kubernetes workload identity |
| `exclude_managed_identity_credential` | False | Skip managed identity |
| `exclude_shared_token_cache_credential` | False | Skip shared token cache |
| `exclude_visual_studio_code_credential` | False | Skip VS Code credential |
| `exclude_cli_credential` | False | Skip Azure CLI |
| `exclude_powershell_credential` | False | Skip Azure PowerShell |
| `exclude_developer_cli_credential` | False | Skip Azure Developer CLI |
| `exclude_interactive_browser_credential` | **True** | Skip interactive browser |
| `exclude_broker_credential` | False | Skip WAM broker |
## get_bearer_token_provider
Helper that wraps a credential into a callable returning a bearer token string. Essential for OpenAI SDK and other non-Azure-SDK clients:
```python
from azure.identity import DefaultAzureCredential, get_bearer_token_provider
credential = DefaultAzureCredential()
token_provider = get_bearer_token_provider(From magrathean-uk/auditex, MIT.
More from magrathean-uk/auditex
- 0.587score
app-readonly-escalation
magrathean-uk
Use when a delegated Microsoft 365 audit is blocked and a customer-local app registration may provide a documented second pass.
SkillAFreshness: A★ 1Claude Code +9 - 0.587score
delegated-auth
magrathean-uk
Use when starting an authorized Microsoft 365 audit without an app registration and assessing delegated coverage before an app-consent escalation.
SkillAFreshness: A★ 1Claude Code +9 - 0.586score
auditex-operator
magrathean-uk
Use when operating Auditex for an authorized Microsoft 365 or Google Workspace audit and summarizing evidence coverage.
SkillAFreshness: A★ 1Claude Code +9 - 0.586score
evidence-pack
magrathean-uk
Use when reviewing or handing off an Auditex run and preparing a customer-safe evidence pack with integrity checks.
SkillAFreshness: A★ 1Claude Code +9 - 0.445score
azure-diagnostics
Microsoft
Debug Azure production issues on Azure using AppLens, Azure Monitor, resource health, and safe triage.
SkillAFreshness: A★ 1Claude Code +9 - 0.445score
microsoft-foundry
Microsoft
Deploy, evaluate, and manage Foundry agents end-to-end: Docker build, ACR push, hosted/prompt agent create, container start, batch eval, prompt optimization…
SkillAFreshness: A★ 1Claude Code +9
Signals
- Stars
- 1
- Forks
- 1
- Open issues
- 0
- Last commit (this folder)
- Apr 21, 2026 (6 months ago)
- Last release
- Oct 23, 2026 (12 days ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 1.0.0
- License
- MIT
- Repository
- github.com/magrathean-uk/auditex
- Website
- magrathean.uk
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
Same skill elsewhere
Copies of this SKILL.md published by others; search shows only one of them.
More from Microsoft
- 0.643score
azure-kubernetes
MicrosoftOfficial
Plan, create, and configure production-ready Azure Kubernetes Service (AKS) clusters.
SkillAFreshness: A★ 3.1KClaude Code +9 - 0.643score
azure-prepare
MicrosoftOfficial
Prepare azd-based Azure projects for deployment: generates azure.yaml, infrastructure (Bicep/Terraform), and Dockerfiles for the Azure Developer CLI (azd)…
SkillAFreshness: A★ 3.1KClaude Code +9 - 0.643score
azure-app-onboard
MicrosoftOfficial
End-to-end orchestrator: from a business idea, app idea, or existing app to running Azure deployment with cost estimates and pre-deploy approval.
SkillAFreshness: A★ 3.1KClaude Code +9 - 0.643score
appinsights-instrumentation
MicrosoftOfficial
Guidance for instrumenting webapps with Azure Application Insights.
SkillAFreshness: A★ 3.1KClaude Code +9 - 0.643score
azure-compliance
MicrosoftOfficial
Run Azure compliance and security audits with azqr plus Key Vault expiration checks.
SkillAFreshness: A★ 3.1KClaude Code +9 - 0.643score
foundry-iq
MicrosoftOfficial
Foundry IQ knowledge bases.
SkillAFreshness: A★ 3.1KClaude Code +9
Done for you
Rather not set it up yourself?
Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.
See how we build AI agents →Read the case studies
Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.
- launches shipped
- 50+
- launches shipped
- media placements
- 500+
- media placements
- founders on every account
- 2
- founders on every account
Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block
Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.
Get azure-identity-py running in your business
Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.
Cite this page
azure-identity-py skill. Agent Mart. https://agentmart.dev/skills/magrathean-uk-azure-identity-py (last updated 2026-10-24)