1

Microsoft offers a RESTful API for Azure App Configuration with the documentation at: https://learn.microsoft.com/en-us/rest/api/appconfiguration/configurationstores/list

I have defined some features using Feature Manager in an instance of App Configuration. When I use the above API, it just gives me a list of App Configuration. I was wondering if there is an API for listing the features defined in App Configuration. I am building a service and I need to be able to query it programmatically.

Mar Chal
  • 133
  • 3
  • 15

1 Answers1

2

The key-values present in your instance of App Configuration can be accessed through the data-plane API detailed here. The API docs you linked to are control-plane docs for creating/managing App Configuration instances, rather than working with the data inside of them.

Features in an App Configuration instance are key-values that follow specific conventions detailed here. To work with them programmatically, you can use the key-values API and follow the feature flag conventions for key-values.

J. Campbell
  • 680
  • 4
  • 5
  • Thanks! In the samples [here](https://github.com/Azure/AppConfiguration/blob/main/docs/FeatureManagement/Clients/AspNetCore/Microsoft.FeatureManagement.AspNetCore.md), the feature flags are local (in the appsettings) while I am trying to read them from App Configuration. Is there an SDK for that or do I need to make HTTP calls to the key-values endpoint? Also, in [the documentation for key-values API](https://learn.microsoft.com/en-us/azure/azure-app-configuration/rest-api-key-value), the host hasn't been mentioned. For example: `GET /kv/{key}?label={label}&api-version={api-version}` – Mar Chal Jan 06 '21 at 00:15
  • The Microsoft.Extensions.Configuration.AzureAppConfiguration package provides the capability to load feature flags from Azure App Configuration and consume them using the Microsoft.FeatureManagement library. Check out this [tutorial](https://learn.microsoft.com/en-us/azure/azure-app-configuration/use-feature-flags-dotnet-core). It mentions using Microsoft.Azure.AppConfiguration.AspNetCore instead of the package I mentioned, but this package just references the one I mentioned and adds some ASP.NET Core functionality. The host should be available in Azure portal for your instance. – J. Campbell Jan 06 '21 at 16:18
  • Thanks. I found what I was looking for at [App Configuration API reference](https://learn.microsoft.com/en-us/dotnet/api/overview/azure/data.appconfiguration-readme). I used `Azure.Data.AppConfiguration` and `Azure.Identity` and also created an rbac principal to be able to access App Configuration using client ID and client secret. – Mar Chal Jan 07 '21 at 23:40