maikvandergaag / msft-extensions

Repository for extensions mainly used for Azure DevOps Extensions
https://msftplayground.com
MIT License
126 stars 80 forks source link

Update Privacy Level Parameter in Power BI Action - Resolves #501 #525

Closed Adee1499 closed 4 months ago

Adee1499 commented 4 months ago

This PR addresses an issue (Issue #501) with the privacy level parameter in the Power BI Action Update SQL Credentials. The current implementation uses an ‘individual’ parameter with the values “Individual” and “Organization”, which seems to be a misinterpretation of the intended privacy levels.

According to the Microsoft Power BI documentation, the privacyLevel parameter in the Gateways - Update Datasource endpoint of the Power BI REST API should accept the following values:

These values correspond to the privacy levels that can be assigned to credentials. The current implementation incorrectly sets the $level variable to ‘Individual’ regardless of the input, which is not a valid privacy level.

This PR updates the ‘scope’ parameter and the underlying methods to correctly reflect the privacy levels as defined in the Microsoft documentation. This change will ensure that users can accurately set their desired privacy level when updating SQL credentials in Power BI Actions.

Please review and let me know if there are any concerns or questions.

maikvandergaag commented 4 months ago

Looks good! Are you willing to test the beta version?

Adee1499 commented 4 months ago

Thanks for the quick review. It works fine from my testing 👍