EntraIdScope
Classsealednet10.0
Describes a delegated permission scope that an API registration created by Aspire exposes.
namespace Aspire.Hosting.Azure;
public sealed class EntraIdScope{ // ...}8 members
Remarks
Section titled Remarks The scope's ID is stable across deployments: unless
EntraIdScope.Id is set, it derives from the registration's name and the scope's EntraIdScope.Name . Microsoft Graph does not allow a scope to be removed, or its name to change, while it is enabled. To retire a scope, set EntraIdScope.IsEnabled to false, deploy, and then remove the scope in a later deployment. Properties8
Section titled PropertiesDisplayName get; setstring Gets or sets the scope's title, shown on the admin consent page. Defaults to
EntraIdScope.Name . Namegetstring Gets the scope's name, the value that appears in the token's
scp claim, such as access_as_user . RequiresAdminConsent get; setbool Gets or sets whether only an administrator can consent to the scope. Defaults to
false, which lets users consent. UserConsentDescription get; setstring? Gets or sets what the scope allows, shown on the consent page for users. When
null, EntraIdScope.Description is used. UserConsentDisplayName get; setstring? Gets or sets the scope's title shown on the consent page for users. When
null, EntraIdScope.DisplayName is used.