Forum Discussion
Logic App Connection With Microsoft OneLake
Hello Everyone,
I'm retrieving Outlook emails with attachments using Logic Apps and aiming to store them in Fabric OneLake. However, there are no available connectors to establish a direct connection with OneLake. When I use the HTTP connector, every time my Logic App is triggered, I encounter an authorization failure. Despite trying multiple approaches—including generating a valid token, Basic Authentication, and Service Principal Authentication—the issue persists.
If anyone has dealt with a similar scenario, I would greatly appreciate your assistance.
Hi BhaskarMishra ,
Thanks for reaching out to the Microsoft fabric community forum.
Since there’s no direct connector for OneLake in Logic Apps, a common workaround is to use Azure Data Factory or Azure Functions to bridge the gap. You can configure an Azure Function to authenticate with OneLake using Managed Identity or OAuth 2.0, then expose an HTTP endpoint that Logic Apps can call. Another approach is to use Azure Storage Account as an intermediary store the attachments there first, then move them to OneLake using a scheduled pipeline in Microsoft Fabric. If authentication is the main issue, ensure that your token request follows the correct OAuth flow, and test API calls using Postman before integrating them into Logic Apps.
Solved: Re: Retrieve Attachments from Email and Save to On... - Microsoft Fabric Community
Solved: Pushing Data from Function App to One Lake - Microsoft Fabric Community
If this post helped resolve your issue, please consider giving it Kudos and marking it as the Accepted Solution. This not only acknowledges the support provided but also helps other community members find relevant solutions more easily.
We appreciate your engagement and thank you for being an active part of the community.
Best regards,
LakshmiNarayana.
6 Replies
- v-lgarikapatCommunity Support
Hi BhaskarMishra ,
Thanks for reaching out to the Microsoft fabric community forum.
Since there’s no direct connector for OneLake in Logic Apps, a common workaround is to use Azure Data Factory or Azure Functions to bridge the gap. You can configure an Azure Function to authenticate with OneLake using Managed Identity or OAuth 2.0, then expose an HTTP endpoint that Logic Apps can call. Another approach is to use Azure Storage Account as an intermediary store the attachments there first, then move them to OneLake using a scheduled pipeline in Microsoft Fabric. If authentication is the main issue, ensure that your token request follows the correct OAuth flow, and test API calls using Postman before integrating them into Logic Apps.
Solved: Re: Retrieve Attachments from Email and Save to On... - Microsoft Fabric Community
Solved: Pushing Data from Function App to One Lake - Microsoft Fabric Community
If this post helped resolve your issue, please consider giving it Kudos and marking it as the Accepted Solution. This not only acknowledges the support provided but also helps other community members find relevant solutions more easily.
We appreciate your engagement and thank you for being an active part of the community.
Best regards,
LakshmiNarayana.- v-lgarikapatCommunity Support
Thanks for your prompt response
Hi BhaskarMishra ,
I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If my response has addressed your query, please "Accept as Solution" and give a 'Kudos' so other members can easily find it.
Best regards,
LakshmiNarayana.- v-lgarikapatCommunity Support
Hi BhaskarMishra ,
If your question has been answered, kindly mark the appropriate response as the Accepted Solution. This small step goes a long way in helping others with similar issues.
We appreciate your collaboration and support!
Best regards,
LakshmiNarayana
- BoreddyManoharNew Member
Hello Everyone,
I am retrieving Outlook emails with attachments using Logic Apps and attempting to store them in Microsoft Fabric OneLake. However, there is no available connector to establish a direct connection with OneLake.
I tried using the HTTP connector. While the Logic App is able to authenticate using Managed Identity and connect to the Lakehouse, the uploaded files are created with 0 KB size.
I have attempted multiple approaches, including HTTP POST and PATCH methods, but I am still unable to load the data correctly into the Lakehouse.
If anyone has encountered this issue or knows a working solution, I would appreciate your guidance.
Thank you.
- burakkaragozSuper User
Hi BhaskarMishra ,
You’re definitely not alone in facing this challenge—direct Logic Apps to OneLake integration is a common roadblock due to the lack of a native connector and the complexities around authentication. Here’s a practical, step-by-step approach to make this work reliably:
Azure Function as a Bridge (Recommended):
- Create an Azure Function that authenticates to OneLake using a Managed Identity or Service Principal with the correct permissions.
- In your Azure Function, use the Microsoft Graph or Fabric REST API to upload files to OneLake. Make sure your function can acquire and refresh tokens as needed (OAuth2 flow).
- Expose the Azure Function as an HTTP endpoint.
- In Logic Apps, use the HTTP action to POST your email attachments to the Azure Function endpoint. The function handles all the OneLake authentication and upload logic.
- This method isolates all the tricky authentication from Logic Apps and gives you full control/flexibility.
Azure Data Factory (ADF) or Microsoft Fabric Pipelines:
- If you already use ADF or Fabric Data Pipelines, you can have Logic Apps drop the attachments into an Azure Storage Account (Blob Storage).
- Then, schedule a pipeline to move files from the storage account into OneLake. This is robust, scalable, and keeps authentication straightforward.
Key Things to Check:
- For Function authentication, ensure your app registration/service principal has the correct API permissions for OneLake (usually delegated or application permissions).
- Use tools like Postman to test the authentication and file upload flow before wiring it up to Logic Apps.
- Double-check that you are using the correct OAuth 2.0 endpoints and scopes for the Fabric/OneLake API access.
By introducing a small Azure Function layer, you can overcome the current authentication and connectivity limitations. This pattern is used successfully in many enterprise setups for similar scenarios.
If this helps, please consider marking the response as Accepted Solution so others with the same problem can find it easily. Let me know if you need example code or further details at any step!