web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Azure DevOps - Connect...
Power Apps
Suggested Answer

Azure DevOps - Connection reference + Environment Variables

(0) ShareShare
ReportReport
Posted on by 45

Hi everyone,

I'm working on automating the deployment of Power Platform solutions (mainly Power Automate and Power Apps) from DEV to PREPROD, and eventually to PROD, using Azure DevOps pipelines.

I'm facing an issue that occurs only when I add Connection References to the solution.json schema. If I skip them, environment variables migrate correctly. But once I include Connection References, the deployment fails.

Here’s a sample of the references I’m using

{
  "EnvironmentVariables": [
    {
      "SchemaName": "demo_FeedbackPhotos",
      "Value": "Photos"
    },
    {
      "SchemaName": "demo_ToolConfig",
      "Value": "Config"
    },
    {
      "SchemaName": "demo_Users",
      "Value": "UserList"
    }
  ],
  "ConnectionReferences": [
    {
      "LogicalName": "demo_OutlookGeneric",
      "ConnectionId": "conn-001",
      "ConnectorId": "/providers/Microsoft.PowerApps/apis/shared_office365"
    },
    {
      "LogicalName": "demo_ExcelConnector",
      "ConnectionId": "conn-002",
      "ConnectorId": "/providers/Microsoft.PowerApps/apis/shared_excelonlinebusiness"
    },
    {
      "LogicalName": "demo_OutlookUser",
      "ConnectionId": "conn-003",
      "ConnectorId": "/providers/Microsoft.PowerApps/apis/shared_office365"
    },
    {
      "LogicalName": "demo_SharePointConnector",
      "ConnectionId": "conn-004",
      "ConnectorId": "/providers/Microsoft.PowerApps/apis/shared_sharepointonline"
    }
  ]
}

I have a few questions:


  1. Is it possible to change the connection account between environments? For example, using my personal account in DEV, but a generic account (e.g., coaching@company.com) in PREPROD/PROD?
  2. How can I ensure that flows are automatically enabled in PROD after migration, but remain disabled in DEV and PREPROD?
  3. Has anyone encountered errors when adding Connection References to the schema and knows how to fix them?
 
Categories:
I have the same question (1)
  • developerAJ Profile Picture
    4,763 on at
    1. Is it possible to change the connection account between environments? For example, using my personal account in DEV, but a generic account (e.g., coaching@company.com) in PREPROD/PROD?
    “Yes, you can change it using the JSON schema above. However, you won’t be able to create a connection directly from the pipeline — you’ll need to use the respective connection IDs. The issue you’re currently facing is due to an incorrect connection ID. Please create a new connection in production, and you’ll get the correct connection ID.
    Connection ID captured in the URL
  • Suggested answer
    developerAJ Profile Picture
    4,763 on at
    1. How can I ensure that flows are automatically enabled in PROD after migration, but remain disabled in DEV and PREPROD?
    Not sure if we have anything from devops action but you can do this using Power Automate flow
     
     
     

    If this solution helped you resolve your issue, kindly mark it as accepted — it makes it easier for others to find and also closes the discussion. If you found it useful, a Like ❤️ would be greatly appreciated!

    🤝 Let’s connect on LinkedIn 

    📘 Explore more on my articles

    🐱‍💻 Github Link

  • developerAJ Profile Picture
    4,763 on at
    Please tag me if you are still facing the issue. if issue is resolved mark response as solution
     

    If this solution helped you resolve your issue, kindly mark it as accepted — it makes it easier for others to find and also closes the discussion. If you found it useful, a Like ❤️ would be greatly appreciated!

    🏷️ Please tag me @developerAJ if you still have any queries or issue persists

    🤝 Let’s connect on LinkedIn 

    📘 Explore more on my articles

    🐱‍💻 Github Link

    💼👥 Looking for Jobs Power Platform & Microsoft Jobs Network

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 516

#2
Vish WR Profile Picture

Vish WR 444

#3
WarrenBelz Profile Picture

WarrenBelz 434 Most Valuable Professional

Last 30 days Overall leaderboard