By Rohit Dabra, Chief Technology Officer, QServices
Published June 12, 2026
Rohit Dabra is the Co-Founder and Chief Technology Officer at QServices, a software development company focused on building practical digital solutions for businesses. At QServices, Rohit works closely with startups and growing businesses to design and develop web platforms, mobile applications, and scalable cloud systems. He is particularly interested in automation and artificial intelligence, building systems that automate routine tasks for teams and organizations. LinkedIn ↗
Written from QServices' hands-on delivery work and reviewed by Sahil Kataria, Chief Executive Officer, QServices, before publishing.
To connect Power Automate to a custom .NET API, build a Custom Connector using the API's OpenAPI definition and Entra ID OAuth for auth. Flows can then call your .NET endpoint securely, with no hardcoded credentials, and handle transient failures with a retry policy.
What you need before you start
This guide assumes the following are in place. Missing any one of these will stall you mid-setup.
- .NET 8 Web API deployed at an HTTPS endpoint. The API must be publicly accessible or reachable from Power Automate's cloud infrastructure via a firewall allowlist or Azure API Management.
- OpenAPI/Swagger definition. Swashbuckle (built into .NET 8 Web API templates) generates this at
/swagger/v1/swagger.json.
- Azure AD / Entra ID tenant with app registration rights. You need permission to create app registrations and expose API scopes.
- Power Automate Premium license. Custom Connectors require a per-user Premium or per-flow plan. The standard Microsoft 365 license does not include them.
- Environment Maker role in the Power Platform environment where you will deploy the connector.
- Azure API Management (optional). Adds throttling, request logging, and a single front door if multiple flows share the same .NET API.
For background on connector concepts, browse our Power Automate and workflow automation guides.
Step-by-step: Connect Power Automate to a custom .NET API
- Expose the .NET endpoint and confirm it returns clean JSON. In your .NET 8 Web API project, ensure the action method returns a typed response object so Swashbuckle documents it fully. Verify the generated OpenAPI definition at
/swagger/v1/swagger.json accurately describes request parameters and response schema. Incomplete schema means Power Automate cannot generate typed connector inputs automatically.
- Register the API in Azure AD (Entra ID) and require an access token. In the Azure Portal, go to App registrations and create a registration for your API. Under Expose an API, define an application ID URI and add a scope (for example,
Invoke). In your .NET API, configure AddMicrosoftIdentityWebApi() and annotate protected endpoints with the required scope. Do not accept shared secrets in query strings or headers. They appear in logs and rotate poorly.
- Create a second Entra ID app registration for the Power Automate connector. In App registrations, create a client application (for example, "MyAPI-PowerAutomate"). Under API permissions, grant it the scope from the previous step. Generate a client secret (note the expiry date; maximum is two years) or configure a certificate for longer-lived credentials. This registration is the identity Power Automate uses to request tokens.
- Build a Custom Connector in Power Automate from the OpenAPI definition. In Power Automate, go to Data > Custom Connectors > New custom connector > Import an OpenAPI file. Upload the
swagger.json. On the Security tab, select OAuth 2.0 and authorization type Azure Active Directory. Enter the client ID, client secret, tenant ID, and resource URL (the application ID URI from step 2). The Microsoft Custom Connectors documentation has a full field reference.
- Test a single connector operation in the test console. On the Test tab, create a new connection using the OAuth credentials and run one operation with sample input. Confirm the response matches the expected schema. If the token request fails, check that the redirect URI in Entra ID matches Power Automate's OAuth callback URL shown on the Security tab.
- Use the connector in a flow and configure error handling and retry policy. Add the Custom Connector action to a flow and map its typed inputs from upstream steps. In the action settings (three-dot menu > Settings), set a Retry Policy using Fixed Interval with count 3 and interval 20 seconds. Wrap the action in a Scope container and add a Configure run after branch for failed and timed-out outcomes so a transient 500 does not terminate the entire flow run.
Authentication options and when to use each
Client secrets are the fastest way to get a connector working, but they expire (Entra ID caps secrets at two years). Certificates do not expire on the same schedule and are auditable in Azure Key Vault. Azure API Management is worth adding when multiple teams' flows call the same .NET API and you want rate-limiting, request logging, or IP restrictions applied at the gateway rather than in application code.
| Auth method |
Setup effort |
Best for |
Watch for |
| Entra ID OAuth 2.0 + client secret |
Low |
Most production connectors |
Secret expires in 1-2 years; set a calendar alert |
| Entra ID OAuth 2.0 + certificate |
Medium |
Connectors requiring long-term stability |
Certificate rotation must be planned and documented |
| Azure API Management + subscription key |
Medium-high |
Multiple flows sharing one .NET API |
Adds a billable APIM tier; plan size affects throughput limits |
Start with Entra ID OAuth 2.0 and a client secret. Move to certificate auth or APIM if the connector is shared across teams or if the API handles data subject to audit requirements.
Where this gets tricky
Three patterns break this setup in production:
Hardcoded API key instead of Entra ID auth. Passing a shared secret in a custom header works until the key leaks, rotates under pressure, or the security team audits the flow. Custom Connector credentials stored in Entra ID are scoped, auditable in Azure logs, and do not live inside the flow definition where any Maker with read access can see them.
Calling the API inside an Apply to Each loop without batching. A flow iterating over 500 records that calls your .NET API once per item will hit Power Automate's action throttling limits and your API's rate limits at the same time. Design the .NET endpoint to accept an array of inputs, or enable Apply to Each concurrency control to cap parallel calls at a value your API can handle.
No retry policy on transient failures. Power Automate's default behavior when an action fails is to fail the run. A .NET API returning a 500 due to a database blip or a brief network interruption will terminate the flow unless you configure a retry policy before go-live, not after the first production incident.
How QServices can help
QServices builds Power Automate integrations against custom .NET APIs as part of our Power Automate development service. Most connector builds run 3 to 8 weeks end-to-end. Project budgets range from $6,000 for a single-connector project to $35,000 for multi-flow automation replacing a manual process. For a detailed breakdown, see our Power Automate cost guide.
We have shipped this integration pattern in production. For a manufacturing client, we built Power Apps and .NET integrations that digitized the full inventory lifecycle, including supervisor approval workflows tied to a custom ERP API:
Case Study
Manufacturing Inventory ERP Portal Integrated with Syspro (Hyspan)
Manufacturing and stocking company
Digitized full lifecycle of inventory operations with barcode and QR scanning, replacing error-prone spreadsheet tracking
Multi-warehouse management with FIFO/LIFO valuation, batch tracking, and supervisor approval workflows
Power Apps.NET Framework 4.7.2MySQLSyspro ERP
For a US pest control business, we connected a .NET API to QuickBooks Online, automating customer and invoice syncing and eliminating manual invoicing errors that were causing billing delays:
Case Study
QuickBooks Online Invoicing Integration for Pest Control Business (JanTech)
Pest control business, US
Automated customer and invoice syncing with QuickBooks Online eliminating manual invoicing errors
Multi-rate tax handling (in-town, out-of-town, exempt) with sandbox environment for safe testing
.NET (C#)SQL Server 2014QuickBooks Online APIjQuery
Do I need a Premium Power Automate license to use a Custom Connector?
Yes. Custom Connectors are a premium feature in Power Automate. You need either a Power Automate Premium per-user plan or a per-flow plan assigned to the flow that uses the connector. The standard Microsoft 365 or Office 365 license does not include Custom Connector access. Verify your license in the Power Platform admin center before starting the build to avoid discovering the restriction after completing the setup.
Ready to discuss your project?
Share your requirements with QServices. Our engineers will give you a straight answer on fit, timeline, and cost — no sales scripts.
Book a Free Consultation
Frequently Asked Questions
What Power Automate license do I need for a Custom Connector? +
Custom Connectors require a Power Automate Premium per-user plan or a per-flow plan. The standard Microsoft 365 license does not include them. Check your license in the Power Platform admin center before building. If your organization uses the per-flow plan, that plan must be assigned to the specific flow using the connector, not just to a user.
Can I test a Power Automate Custom Connector without building a flow? +
Yes. The Custom Connector designer includes a Test tab where you can create a connection and run individual operations directly. This confirms token exchange, request formatting, and response schema before touching any flow. Run at least one operation end-to-end before adding the connector to production flows.
Does the .NET API need to be publicly accessible for Power Automate to reach it? +
Power Automate's cloud infrastructure needs to reach your HTTPS endpoint. A public endpoint works directly. For private APIs behind a firewall, use the on-premises data gateway or expose the API through Azure API Management with IP allowlisting for Power Automate's published outbound IP ranges.
What is the difference between a Custom Connector and an HTTP action in Power Automate? +
The HTTP action sends a raw request with no schema awareness. A Custom Connector generates typed inputs and outputs from the API's OpenAPI definition and stores OAuth credentials at the connector level, so credentials are managed once and reused across all flows using that connector rather than repeated per action.
How long does it take to build a Custom Connector for a .NET API? +
Building the connector (Entra ID registrations, importing the OpenAPI definition, and testing one operation) takes one to two days for a developer familiar with both tools. The full integration project, covering flow design, error handling, and testing, runs 3 to 8 weeks depending on flow count and API complexity.