Forum Discussion
AswanyT
1 year agoFrequent Visitor
403 Forbidden Error When Calling New-FabricWorkspace in PowerShell – Was Working Earlier
Hi Team, I'm encountering an issue while trying to call the Fabric REST API to create/get a workspace ID using PowerShell. The script was working fine until 19-May-2025, but it started failing fr...
- 1 year ago
Hi AswanyT,
- If possible,use managed identity tied to a user that has the necessary Power BI and Fabric admin rights. user principals generally have fewer restrictions in tenant-level operations like workspace creation.
- If creating new workspaces isn't mandatory in your flow, you can: Pre-create a set of workspaces manually or via user login. Use those workspaces via their ID or name for subsequent automation.
Thanks,
Prashanth Are
MS Fabric community support
AswanyT
1 year agoFrequent Visitor
Hi Akash_Varuna , All required permissions are granted in app registration. Also I am able to authenticate using spn. I am also able to perform below operations
Import-FabricItems -workspaceId $workspaceId -path "{pbip_path}"
Export-PowerBIReport -Id $reportId -WorkspaceId $workspaceId -OutFile "{saved_pbix_file_path}"
Only issue is not able fetch workspaceid using below line
$workspaceId = New-FabricWorkspace -name $workspaceName -skipErrorIfExists
- v-prasare1 year ago
Community Support
Hi AswanyT,
- If possible,use managed identity tied to a user that has the necessary Power BI and Fabric admin rights. user principals generally have fewer restrictions in tenant-level operations like workspace creation.
- If creating new workspaces isn't mandatory in your flow, you can: Pre-create a set of workspaces manually or via user login. Use those workspaces via their ID or name for subsequent automation.
Thanks,
Prashanth Are
MS Fabric community support