entra-app-registration

Guides Microsoft Entra ID app registration, OAuth 2.0 flows, and MSAL integration.

Updated Jan 23, 2026
One-click install
npx skills add https://github.com/stephschofield/beth --skill entra-app-registration-stephschofield
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: entra-app-registration
Source: https://github.com/stephschofield/beth/tree/main/.github/skills/entra-app-registration
Command: npx skills add https://github.com/stephschofield/beth --skill entra-app-registration-stephschofield

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Setting up Microsoft Entra ID (formerly Azure AD) app registrations involves many error-prone steps: choosing the right application type, configuring redirect URIs, adding API permissions, granting admin consent, and wiring OAuth flows into application code. This Skill walks through each step with portal, Azure CLI, and Bicep options so authentication works on the first attempt. ## Core Features & Use Cases - App Registration Workflows: Step-by-step guidance for creating web, SPA, mobile, and daemon app registrations via the Azure Portal, Azure CLI, or Bicep infrastructure-as-code. - OAuth 2.0 & MSAL Implementation: Detailed coverage of authorization code, PKCE, client credentials, device code, and refresh token flows, with complete console app examples in C#, Python, and Node.js. - Permissions & Troubleshooting: Reference tables for Microsoft Graph delegated and application permissions, admin consent procedures, and solutions for common AADSTS error codes. - Use Case: A developer needs a .NET console app that signs users in and calls Microsoft Graph. The Skill provides the registration steps, the User.Read permission setup, and a working MSAL code sample. ## Quick Start Ask the agent to create a new Entra app registration for a single-page application with User.Read permission and show the MSAL code to sign users in.

Frequently Asked Questions about entra-app-registration

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a Microsoft Entra app registration with Azure CLI?▼

Run az ad app create with a display name, redirect URIs, and sign-in audience, for example az ad app create --display-name "MyApp" --spa-redirect-uris "http://localhost:3000". Then add API permissions with az ad app permission add and create a service principal with az ad sp create.

What is the difference between delegated and application permissions in Microsoft Graph?▼

Delegated permissions let the app act on behalf of a signed-in user, limited by that user's rights. Application permissions let the app act with its own identity for background services and always require admin consent.

Which OAuth flow should I use for a console or headless application?▼

Use the device code flow for interactive console apps without a browser, where the user enters a code at microsoft.com/devicelogin. Use the client credentials flow for service-to-service authentication with no user involvement.

Should I use DefaultAzureCredential in production?▼

No. DefaultAzureCredential is intended for local development where it picks up Azure CLI or VS Code credentials. In production, use ManagedIdentityCredential for Azure-hosted apps to get deterministic behavior without fallback-chain latency.

Why am I getting AADSTS50011 redirect URI mismatch errors?▼

The redirect URI in your request does not exactly match one registered in the app registration. Matching is case-sensitive and trailing slashes matter, and the URI must be registered under the correct platform type (Web, SPA, or Public client).

When should I use certificates instead of client secrets?▼

Use certificates for production confidential clients because they are more secure than secrets and avoid storing password-like values. Client secrets are acceptable for development but must be stored securely, rotated regularly, and never committed to source control.