Currently I have been working in a project to implement few APIs hosted on Azure and make them publicly available via Azure API Management service. At the moment, the APIM service communicates with the Function App (API), and the Function App has the authorization level as Function. So, anytime there is a request to the APIM service, this request is forwarded to the Function App, and the code is injected to the request be authorized. But, at the moment we are managing policies on XML files, and consequently the authorization code is hard coded on these files. So I was wondering if you have any suggestion in terms of managing these codes dynamically, without hard-coding them to these files, since the files are saved in Azure DevOps repos... At the moment, we have a pipeline set-up on Azure DevOps to manage policies changes, so anytime there is a change, it will upload the new policies files to a Storage Account, and then we deploy an ARM template to configure all the APIM service, with the new policies.
Any ideas how to manage those codes without hard-code them?
Thanks.