Canvas apps, CDS, Community, Custom Data Provider, Data Integration, Dataflows, Embedded Canvas Apps, Model-Driven Apps, Power Apps, Power Automate, Power Platform, PowerApps, Scottish Summit, Virtual Entities

Scottish Summit 2020 – Deep Space in Power Platform

It has now been almost two weeks since the sound of bagpipes and the sight of kilts. I can still feel the excitement and passion which filled the air at the University of Strathclyde on that Saturday, when we were all united because of the passion for what we do. As usual it gave me so much inspiration and positive energy just to meet with like-minded enthusiasts, all with different experience, viewpoints and great ideas.

In my previous blog post I shared my story – my day – including pieces of what I learned from attending other sessions. In this blog post I will let you in on the session that I held.

Deep Space in Power Platform

My session had the title “Deep Space in Power Platform – exploring integration possibilities with open APIs.” At the speakers dinner on the night before the event, I got the same question from two different persons asking me what “deep space” is, like it was a feature in the Power Platform. It made me wonder if I should have chosen a better title for the session.

Anyway – this session was all about combining the Power Platform with information about deep space – as in rocket launches and photos from Mars. Hopefully everyone attending the session became fully aware of that fact when they entered to room to the tones of David Bowie and his “Life on Mars“.

The session was meant to spread knowledge about Virtual Entities, Dataflows and embedded Canvas Apps and for the attendees to get inspiration to their customer projects. Their customers most likely have other APIs and information instead of deep space, but there might be similar requirements – to integrate data into your apps and in some cases there is no need to update the data – you just want to display the information.

Technology comparison

Virtual Entities can mean a no-code or low-code solution, depending on your data source. Use a Virtual Entity if you want to just display data from another system in a Model-Driven App, without having the data stored in the CDS. The records will always be read-only and organization owned. You will be able to use the records almost in the same way you work with other records which are in the CDS. You just need to make sure your Custom Data Provider supports it.  

Dataflows is a no-code alternative to get data into the CDS (or an Azure Data Lake). Dataflows can be run once or on scheduled basis. There are 20+ sources you can choose from when setting it up – not to be mistaken for the connectors and the connector platform, that is something else. During my session I used the Web API source.

An embedded Canvas Apps is a Canvas App which is placed on a form and thereby can be utilized in a Model-Driven App. It is a simple No-Code/Low-Code way to display data from another system. You can set up a Custom Connector or use Power Automate and a flow in the background in order to get the data from the other system. This is per record only, i.e. always placed on the form. There is no way to get an overview of the integrated data as you can get with a Virtual Entity.

From my presentation – a link to where you can view all pieces can be found in the end of this post

Demo part 1 – Virtual Entities

The environment I used was prepared so that there were an entity called SpaceX Rocket Launch in there already, created in the classic experience because that is where you need to be in order to be able to create a Virtual Entity.

I described the code that builds up a Custom Data Provider for SpaceX rocket launches. Then onto registering the Custom Data Provider, adding a Data Source Record and updating the entity with the Data Source. You can read more about it in detail in my recent blog posts about Virtual Entities. The result is shown below.

Information about the SpaceX Rocket Launch last week – on the 7th of March

Demo part 2 – Dataflows

For this demo I used the same API but set up a Dataflow using the source Web API and let the Dataflow create an entity on the fly. Not to recommend in real world scenarios because you get un ugly prefix for your entity, but works fine for demo purpose. To be able to set our own prefix – I have added this as an idea, please vote for it here. Read more about Dataflows from Web API here or take a look at my presentation for the detailed steps to achieving this result. A link is provided in the end of this post.

The Dataflow has created an entity (with ugly prefixes for the entitiy and the fields) and also transferred data from the Web API to this new entity

Demo part 3 – Embedded Canvas App

Here we pretended that we wanted to manage missions in the CDS. There was an entity called Mission. Then we pretended that there were pictures which could be displayed from the missions. SpaceX have not been to Mars yet, however they have plans for making it to Mars and also carrying humans to Mars, you can even read phrases like “making life multiplanetary” on their website.

Nasa, on the other hand, have been to Mars and they expose data from Mars in their open APIs. They have a Mars weather service API “Insight”, summaries of the data are available here. They also have Mars rover photos available – an API which is designed to collect image data gathered by NASA’s Curiosity, Opportunity, and Spirit rovers on Mars and make it more easily available to us. This was the API that I used for the embedded Canvas App. For detailed steps of setting it up, please take a look at my presentation. A link is provided in the end of this post.

The end result is an embedded Canvas App, placed to the left on a form/tab. To the right we have a bonus – a forth way of displaying data from another system – to just insert an iFrame on the form. Please note that there are also other ways to accomplish a similar result. Now that we have the Power Apps Component Framework you can also develop your own PCF control or browse the PCF Gallery and see if the control you are looking for has already been invented.

For instance there is control for displaying YouTube videos YouTube Player. Taking about PCF controls – a few days ago Ivan Ficko released a new component URL Image Control. This one I could have used in my Virtual Entities demo – displaying the Mission Patch of the SpaceX rocket launch – well, perhaps next time!

Anyway, let us take a look at the result. Now we can take a look at the pictures, which the app provides us with, we can inspect them and ask ourselves – is there any life on Mars?

The embedded Canvas App to the left and an iFrame displaying video content to the right

Key takeaways

After the demos there was a comparison again, this time – when to use what technology. I will now try to summarize the key takeaways – what I wanted everyone to know after attending my session.

From my presentation – a link to where you can view all pieces can be found in the end of this post

Consider using Virtual Entities when you want to display data from another system, be able to work with the data (make searches, see it in views, open the records etc.) in the same way as with other “normal” entities but when at the same time it is OK to have the Virtual Entity records read-only and organization owned.

Consider using Dataflows for simple data integration and migration and for data preparation where you want to transform the data before e.g. data analysis. It is a simple way to get data from an open API to the CDS!

Consider using an embedded Canvas App when you want to display data from another system, it is OK to have it displayed per record only and you do not need to make searches on the data. You can read more about other use cases for embedded Canvas Apps here.

If you want to try any of the examples yourself, there are detailed steps in my presentation, provided to you here. If you attended my session – Thank you for coming and I hope you learned something new from it. If you did not – now you know what it was all about and I hope to see you at some other event in the future.

Thanks for the picture Jonas Rapp!

2 thoughts on “Scottish Summit 2020 – Deep Space in Power Platform”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s