PL-400 Exam QuestionsBrowse all questions from this exam

PL-400 Exam - Question 316


DRAG DROP

-

You are designing a custom connector for an internal API used by Contoso, LLC.

Authentication to the API is carried out by using an API key. The API key is stored within Azure Key Vault. Each environment has a separate instance of the API with a different API key.

You need to reference the API key from Key Vault in the custom connector.

Which four actions should you perform in sequence? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.

NOTE: More than one order of answer choices is correct. You will receive credit for any of the correct orders you select.

Exam PL-400 Question 316
Show Answer
Correct Answer:
Exam PL-400 Question 316

Discussion

5 comments
Sign in to comment
1285cc6
Feb 9, 2025

According to ChatGPT: 1️⃣ Create an environment variable named APIKey (contoso_APIKey) Define the environment variable for the API key. Ensure it is set up to use Azure Key Vault. 2️⃣ Add a role assignment to Key Vault Grant appropriate access (e.g., "Get Secret" permission) to the Power Platform's managed identity in Azure Key Vault's access policies. 3️⃣ Use the syntax @environmentVariables("contoso.ApiKey") Configure the custom connector to use the environment variable. This ensures the API key is dynamically retrieved. 4️⃣ Create a connection Establish a connection to the custom connector using the referenced environment variable.

PRash3566
Oct 23, 2024

It should be 3,4,1,6.

greendend
Dec 20, 2024

1. Add a role assignment to a Key Vault 2. Create an environment variable named APIKey (contoso_APIKey) 3. Use the syntax @environmentVariables("contoso_ApiKey") 4. Create a connection reference

loftuscheek
Feb 26, 2025

"you need to reference in the custom connector" means (create connection reference, create connection are eliminated thus Create an environment variable named ApiKey (contoso_ApiKey) Add a role assignment to Key Vault Remove the current value Use the syntax @environmentVariables('contoso_ApiKey')

loftuscheek
Feb 26, 2025

correction: Create an environment variable named APIKey (for example, contoso_APIKey) that points to the Key Vault secret. Add a role assignment to Key Vault so that Power Platform can read the secret. Use the environment variable syntax (e.g., @environmentVariables('contoso_APIKey')) in the custom connector’s definition (OpenAPI/Swagger). Create a connection (or a connection reference) in your environment that uses the custom connector and picks up the secret from the environment variable.

Juan0414
Mar 6, 2025

I'm having some doubts because I'm not sure if creating a connection should be included because they are asking just to "reference the API key from Key Vault in the custom connector" not to use the connector itself. So I think I'd go with: - Add a role assignment to Key Vault (First thing mentioned in https://learn.microsoft.com/en-us/power-apps/maker/data-platform/environmentvariables-azure-key-vault-secrets#configure-azure-key-vault) - Create an environment variable named ApiKey (contoso_ApiKey) - Remove the current value (It is always good to remove current values to avoid issues when migrating the variables in a solution) - Use the syntax @environmentVariables('contoso_ApiKey') (There is a typo in the image) https://learn.microsoft.com/en-us/connectors/custom-connectors/environment-variables#use-an-environment-variable-in-a-custom-connector

itmaxuser
Apr 15, 2025

✅ Correct Order: 1-Create an environment variable named APIKey (contoso_APIKey) Define a reusable configuration variable that stores the API key. 2-Use the syntax @environmentVariables("contoso_APIKey") Reference the environment variable inside the custom connector definition (in the authentication header, for example). 3-Add a role assignment to Key Vault Ensure the Power Platform can access the secret by granting access to the Key Vault. 4-Remove the current value This allows Key Vault to serve as the source for the environment variable securely across environments.