How do you do to set a property on an Azure resour...
# azure
How do you do to set a property on an Azure resource which need to be computed from another property of the same resource which is only known once the resource. For instance, I want to set an uri in the IdentifierUris property of the Application resource (AzureAd), and this needs to contain the ApplicationId of the Application which I will know only once created.
What are you computing it from?
In the past, I've generated it as
identifierUris         = @("https://$tenantName/$webApiId")
where webApiId is just a new UUID which is saved and passed to another app
I am computing it from the same Application.
It does not come from another app I created. It have to be the app id of the current app
Why does it have to be the app id of the current app?
The azure console uses this pattern by default, but it has not been required in that format in my experience
Maybe a better question is, what are you trying to do? What's your application to be used for?
It is specified this way in the tutorial I am following. This tutorial is about enabling sso on a teams tab.
I need so set the Application ID URI which is suppsoed to contain the AppId.
What do you think @kind-mechanic-53546?
@millions-journalist-34868, thanks, that makes it a bit clearer
I believe that you should be able to just generate your own uuid for use as the id segment of the uri
that worked for me fine in my b2c application which uses the same flow
then you can just plug that value into your manifest
Copy code
"webApplicationInfo": {
  "id": "<application_GUID here>",
  "resource": "<api://>>>UUID generated previously<<"
I'm pretty confident this should work
Thanks I will give it a try ! How did you do to create the scope access_as_user using Pulumi in your case ? It seems terraform azure ad provider used by Pulumi does not support exposing an api yet, so I was planning to look at how to create it using powershell.
I didn't 😞
This was all done using powershell as TF and Pulumi don't support ms graph api as yet
I adapted this script to create a trust framework app and proxy and upload custom policies for a B2C app
Okay understood, thanks for the answer.