Step 1: Prepare SpreadsheetWeb API
- Upload your Excel file to SpreadsheetWeb Hub to generate the API.
- Note the following:
- API Endpoint URL
- Workspace ID
- Application ID
Step 2: Set Up Azure API Management
2.1 Create a New API
- Go to Azure API Management → APIs → HTTP.
- Set the API URL to:
- Configure optional authentication if needed.
2.2 Configure API Operation
- Under Operations, create a new operation:
- Display Name: Calculate Shipping Cost
- Method:
POST - URL:
/calculations/calculatesinglesimple
- Add Headers:
Content-Type: application/json
2.3 Define Request Body
In the Request section, use the following body:
2.4 Define Response Body
In the Response section, add a sample response:
2.5 Test the API
Save and test the configuration to verify the response.
Step 3: Create a Custom Connector in Power Apps
- Open Power Apps → Data → Custom Connectors → New Connector.
- Enter the API Endpoint URL and add the Subscription Key (from Azure).
- Map the request and response fields.
Step 4: Build the Power Apps UI
4.1 Create Input Fields
- Add three Text Input fields:
originZIPdestinationZIPweight
- Add a Button labeled Submit to trigger the API call.
- Add a Label for displaying the API result.
Step 5: Set Up Power Automate Flow
5.1 Create a Flow
- In Power Automate, create a new flow.
- Add three input fields for
originZIP,destinationZIP, andweight.
5.2 Call the API
Add a Custom Action to call the API with the following JSON body:
5.3 Return the Response
Step 6: Connect Power Automate to Power Apps
Link the Submit button in Power Apps to trigger the flow:
- Input test values for originZIP, destinationZIP, and weight.
- Click Submit and verify the calculated result appears in the label.