Skip to main content

Notifications

Announcements

No record found.

Service | Customer Service, Contact Center, Fie...
Answered

IoT Integration with Connected Field Service

Posted on by 5

I'm trying to find the correct api for integrating  IoT software (not Azure IoT) with Connected Field Service.  More specifically,  which api do you use to create an IoT Alert in Connected Field Service in the cloud?  I see some references to on-premise apis, dataverse apis, etc. Frankly, it is confusing.  

Background. I have an Azure Confluent/Kafka architecture.  Why my IoT edge software generates an alert it will publish an event to Kafka.  Ideally, I want Field Service to subscribe to topics in Kafka and create the alert in Field Service automatically.  If Field Service can't do that, then I need to know which REST endpoint to use to create the alert in Field Service.

My expectation was that there would be a document that shows me the api endpoint to use, the credentials, and the specific entity to perform CRUD operations. I'm having trouble finding it.

I'd appreciate if someone can point me in the right direction.

Thanks!

Donnie

  • donniekerr Profile Picture
    donniekerr 5 on at
    RE: IoT Integration with Connected Field Service

    Thanks Dan.  I will post there.

  • RE: IoT Integration with Connected Field Service

    Hi Donnie,

    1. Yes you are correct that it’s just an entity type, same as if you were creating an account or contact. I believe the entity name is msdyn_iotalert (but I’m going off memory). You can double check in admin solution explorer.

    2. In terms of the credentials question I think it’s better to move that part of the request to the power platform forum. The question can be phrased as if you were creating any entity such as account or contact since there is nothing unique as it relates to the credentials for the IoT alert create scenario. I’m not sure off hand how to answer that question so that’s why I’m advising to post here - powerusers.microsoft.com/.../pa_integrations_dynamics365

  • donniekerr Profile Picture
    donniekerr 5 on at
    RE: IoT Integration with Connected Field Service

    I'm stuck on how to do Dataverse Web API authentication for my use case:  An Azure Function posting an IoT Alert to a D365 Field Service instance that is not associated with the Azure tenant of the Azure Function.

    I did create a 365 Developer Account/subscription, but it is not clear at all how to connect all three of these? I've read all of the multiple paths of documentation and am completely lost.

    I simply need to create the Dynamics 365 Field Service credentials to use to include in my server-side Azure Function call to Dataverse.  In my case it is a server-to-server api call not related at all to a user or web app.

    Any further advice would be appreciated.

    Thank you for your patience.

    Donnie

  • RE: IoT Integration with Connected Field Service

    How about these?

    docs.microsoft.com/.../create-entity-web-api

    docs.microsoft.com/.../compose-http-requests-handle-errors

    That section of the docs should hopefully get you all the info you need. LMK if not

  • Suggested answer
    donniekerr Profile Picture
    donniekerr 5 on at
    RE: IoT Integration with Connected Field Service

    Yes, this helps.  For now, I'm going to stick with Kafka and Dataverse API.  I still can't find the right endpoint/entity for an IoT Alert, though. see above question.

  • RE: IoT Integration with Connected Field Service

    I don't have samples specific to node or python but this document explains how it works on the field service side - docs.microsoft.com/.../cfs-custom-iot-provider

    Does that help?

    Note that the IoT provider framework doesn't add value when you are just using alerts but I do think its the right approach the moment you move beyond alerts.

  • donniekerr Profile Picture
    donniekerr 5 on at
    RE: IoT Integration with Connected Field Service

    Dan,

    I think developing the IoT Provider is the right answer, longer term, to get the full benefit of Field Service for IoT. I can't seem to find an example of the code required to build it though?  Do you have an example in Node or Python? I'm trying to Integrate Litmus Edge (LitmusAutomation.com) and I have access to the developers there to make it work via their API.  I just need better documentation on the Field Service side and sample code on how to build it.

    Thanks!

  • donniekerr Profile Picture
    donniekerr 5 on at
    RE: IoT Integration with Connected Field Service

    I'm trying to find the specific endpoint for an IoT Alert.  I assume it is an entityType but I don't see it in this list?

    docs.microsoft.com/.../entitytypes

    Also, how do I get credentials and pass them in the Web API?  This seems to be missing in the docs or I just don't see it.

  • RE: IoT Integration with Connected Field Service

    Ali nailed it. Adding some more color, Field Service relies on the IoT stack to discern between which alerts make sense to push to field service. Once the alert is pushed into field service, if you pass the device ID as part of the alert payload, we will link the alert to the iot device record and the related asset if you have created the records. If you haven't, we will create a device record automatically for you so that subsequent alerts on the same device can be linked to the same device. We also have an AI feature in public preview that scores the importance of the alerts that end up in Field Service.

    As you continue your IoT journey with Field Service and move past alerts, if you want to view device readings, pull device properties, etc, we have an extensibility framework that allows you to use the Field Service IoT capabilities with other providers using this extensibility framework. Please reach out if you have any questions and good luck!

  • Verified answer
    Ali Khan Profile Picture
    Ali Khan 1,380 on at
    RE: IoT Integration with Connected Field Service

    IoT Alert is a table in Dataverse (data service behind D365 FIeld Service). You can use Web API (docs.microsoft.com/.../overview) or use Azure Logic Apps (I am assuming it has a connector with Kafka?)

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans