Integrate your AI model in PowerApps

Create an app to call your deployed classification model

When you’ve built, trained, and deployed your model on the Peltarion platform, you want to put it to use. This tutorial will show you how to use the Peltarion connector in Microsoft Power Apps.

Note: This tutorial needs to call a deployed model. We recommend you to do the Classify customer complaints tutorial first.

Person- Target group Beginners. No prior Power App or coding knowledge required.
Clock- 20 minutes to build and set live.

You will learn to
Peltarion logo- Build an app with Microsoft Power Apps
Peltarion logo- Connect Microsoft Power Apps and Peltarion platform.

Rather watch?
If you like video you can watch how Björn use the Peltarion connector in Microsoft Power Apps in this step-by-step demo.

Watch how Björn use the Peltarion connector in Microsoft Power Apps

Create your Power App

Set Language to English. Translation formatting do funny things with your code otherwise.
  1. Log into Power Apps (or create an account if you don’t have one yet)

  2. Create a new Power App:
    Go to Apps → click on New App → click on Canvas → then choose to create an empty Phone layout.

  3. Add the following three components to the canvas:

    • Text input. This is where you write your test complaint. You can remove the default text and add a Hint text, e.g. Write message here.

    • Button. Used to call the Peltarion model. Rename it What’s the complaint about?

    • Text label. This is where the result will be displayed.

Power apps components

Add the Peltarion connector

Let’s connect the app with your deployed Peltarion model.
Note: The Connector only works during your free PowerApps trial period or of you have a premium version of PowerApps.

  1. Open the Data view in Power Apps. In the search box that appears, write Peltarion and select the Peltarion connector.
    Select the Peltarion connector

  2. Enter your model’s API URL and API token.
    You can find these in the Deployment view of the experiment you want to deploy.

  3. Click Connect. Now, the connection is done!

Call the deployed Peltarion model

Now, you want to call your API to run inference on your newly trained model. Let’s add an action to the Button component and display the result in the Label component!

  1. Click the Button component. Name it What’s this about?

  2. In the Formula field (Fx) 25at the top add the following code (Type the name of your input parameter instead of <YOUR-INPUT-PARAM>):

ClearCollect(dd, {<YOUR-INPUT-PARAM>: TextInput1.Text});
Set(jdata, JSON(dd, JSONFormat.IncludeBinaryData));
Set(res, PeltarionAI.callapi(jdata))
  1. Click the Text label component.

  2. Add the following code to the Formula field (Fx):


Check out our plugin GitHub page for more details.

Note: At this stage it’s a good idea to save the Power App.

Run the app and get a prediction

  1. Start the Power App by clicking the Play button 25in the top right corner.

  2. Enter a complaint in the text input, e.g., I like my credit card bill, but why does it come every month?

  3. Press the Button and wait for a response from the Peltarion platform.
    The first time you call your model this will take a little bit longer (around 20 seconds).

You should now have a fully working app to classify your customer complaints for you!


In case nothing happens once the model has finished loading:

  1. Go back to the editing page of your app.

  2. Select the Text box, add the formula:
    res.errorMessage and hit Enter.
    You will then get information about why an error occurred.

What you’ve learned

With this tutorial, we’ve learned to integrate Microsoft Power Apps. and the Peltarion platform. Well done!

Was this page helpful?
Yes No