Skip to content
This documentation is currently in preview, therefore subject to change.

Power Apps Getting Started Guide

Welcome to the Power Apps (Canvas app) getting-started guide for Build a Doc.
This tutorial shows, step-by-step, how to add the Build a Doc connector (displayed as HappyWiredPowerDocs) to a Power Apps Canvas app, call a Build a Doc action from a UI control, and verify the result in a label.

Prerequisites

  • A valid Build a Doc subscription and API key.
  • Appropriate Power Platform licensing and permissions to create Canvas apps.
  • A working knowledge of Power Apps Canvas basics.

App Overview

  1. Create a new Canvas app (Blank canvas - Phone or Tablet).
  2. Add the HappyWiredPowerDocs data source (Build a Doc connector).
  3. Add UI controls: a button to set JSON data, a button to call a Build a Doc action (Compute Data), and a label to show the result.
  4. Use ParseJSON (or a JSON variable) as the data source for the Compute action.
  5. Map the Compute action result to a variable (e.g. Output) and display Output.result in a label.
  6. Run the app and verify the displayed result.

Step by step

1. Create a new Canvas app

  • From Power Apps, select Create → choose Start with data.
    New App
  • Choose a Blank canvas (Phone or Tablet), depending on your needs.
    New App - Blank Canvas

2. Add the Build a Doc connector as a data source

  • In the app editor, open the left-side panel and select the grid icon, then Add data.
    Select Data
  • Search for HappyWiredPowerDocs and add it to your app’s data sources.
    Search for HappyWired

Build a Doc (HappyWiredPowerDocs) now appears in the Data panel and is available to call from the formula bar.


3. Add a button to set JSON data

  • From Insert, add a button. Name it Set JSON and give it descriptive text (e.g., Set JSON).
  • In the formula bar for that button, set a JSON variable. Example:
Set(jsonData, ParseJSON("[{\"EmpID\": 3,\"Total\": 56.2}, {\"EmpID\": 3,\"Total\": 100}]"))

Set JSON Button

4. Add a button to call the Compute Data action

  • Insert another button (e.g. labelled Compute Data).
  • In the formula bar, begin typing HappyWired and the connector actions will appear; choose HappyWiredPowerDocs.ComputeDataFunction.
  • Use this formula to call the action and store the response in a variable named Output:
Set(Output, HappyWiredPowerDocs.ComputeDataFunction({
expression: "Sum(Total)",
Data: jsonData,
filter: "EmpID=3"
}))
  • This computes the sum of Total where EmpID = 3.
    Compute Data Button

5. Display the result

  • From Insert, add a Label control.
  • In the label’s formula bar, set its Text property to the result from the Compute action:
Output.result

Output Label


6. Verify results

  • Run the app using the play icon in the top-right corner.
  • Click the Set JSON button to populate jsonData.
  • Click the Compute Data button to call the action.
  • Verify the label displays the expected numeric result (the sum) as shown below.
    Verify the result

Troubleshooting

Click to expand common errors and fixes

Connector / Action Not Listed in the Formula Bar

Cause:
The HappyWiredPowerDocs data source isn’t added to the app (Data panel) or the editor didn’t pick it up.

Fix:

  • Open the Data panel and confirm HappyWiredPowerDocs is present.
  • If it’s missing, remove and re-add the data source or re-open the app editor to force a refresh.
  • Re-check the formula bar after re-adding.

ParseJSON Errors

Cause:
The JSON string is invalid (e.g., unescaped double quotes or malformed structure).

Fix:

  • Validate the JSON string using an online/IDE JSON validator or store the JSON in a Text input to inspect.
  • Escape double quotes inside strings as required.
  • Only call ParseJSON() when the string is valid.

Output Variable Is Blank or Missing Result

Cause:
Compute action failed or the connector response shape is different than expected (value nested deeper).

Fix:

  • Confirm the Compute action succeeded (no runtime error).
  • For debugging, set a temporary label to JSON(Output) to inspect the actual shape of the response.
  • Compare the debug output to your label formula - sometimes the value is nested (e.g., Output.body.Result vs Output.result).
  • For the ComputeDataFunction used in this guide, Output.result is the correct path.

Type Mismatches (Text vs Number)

Cause:
Compute action returns a text value but the app expects a number.

Fix:

  • Convert the returned text to a number where needed, e.g., Value(Output.result).

Permissions / Licensing Errors

Cause:
Your Power Apps account lacks permission to use custom connectors or the required licensing.

Fix:

  • Confirm your account has permission to use custom connectors.
  • Verify licensing covers the connector’s usage and upgrade or request permissions if needed.

Unexpected Results from the Filter / Expression

Cause:
Field names in your JSON don’t match the ones used in your expression/filter (case-sensitive), or nested paths are incorrect.

Fix:

  • Verify JSON keys exactly match the field names referenced in your expression and filter (case-sensitive).
  • If fields are nested, ensure your path matches the connector’s response structure (use JSON(Output) debug label to confirm).

Step-by-Step Checklist

  1. Confirm the data source HappyWiredPowerDocs is added to the app (check the Data panel).

  2. Validate any JSON strings before using ParseJSON() (use a validator or a Text input).

  3. Inspect the Compute action run - ensure it succeeded and returned a non-empty Output.

  4. Use a debug label JSON(Output) to see the exact response shape and adjust your formulas (e.g., Output.result vs Output.body.Result).

  5. Convert types when necessary (e.g., Value(Output.result) for numbers).

  6. Verify app permissions and licensing for custom connector usage.

  7. Double-check filter/expression field names and nested paths for exact matches.