Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4 Fixes on Calling Cloud Flows from Power Pages #146

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions power-pages-docs/configure/cloud-flow-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ Request
```html
POST https://contoso.powerappsportals.com/_api/cloudflow/v1.0/trigger/4d22a1a2-8a67-e681-9985-3f36acfb8ed4
{
"Location":"Seattle"
"eventData": "{\"Location\":\"Seattle\"}"
}
```

Expand All @@ -124,6 +124,9 @@ Body
}
```

> [!NOTE]
> Output parameters are returned with lowercase names, no matter what casing was used in the cloud flow.

## Authenticating cloud flow API requests

You don't need to include an authentication code, because the application session manages authentication and authorization. All API calls must include a Cross-Site Request Forgery (CSRF) token.
Expand All @@ -144,6 +147,7 @@ This sample demonstrates how to call a flow using Asynchronous JavaScript and XM
shell.ajaxSafePost({
type: "POST",
url: "/_api/cloudflow/v1.0/trigger/44a4b2f2-0d1a-4820-bf93-9376278d49c4",
contentType: "application/json",
data: JSON.stringify({"eventData":JSON.stringify({"Email": "[email protected]", "File":{"name":"Report.pdf", "contentBytes":"base 64 encoded string"} })})
})
.done(function (response) {
Expand All @@ -154,5 +158,5 @@ This sample demonstrates how to call a flow using Asynchronous JavaScript and XM
});
```
> [!NOTE]
> - If no input parameter is defined in the trigger, pass an empty payload in the request.
> - If no input parameter is defined in the trigger, pass a payload with empty eventData in the request (`data: JSON.stringify({"eventData":JSON.stringify({})})`).
> - For information on cloud flow limitations, see [Limits of automated, scheduled, and instant flows](/power-automate/limits-and-config).
1 change: 1 addition & 0 deletions power-pages-docs/configure/power-automate-how-to.md
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,7 @@ After creating the flow and attaching it to the Power Pages site, you can now ca
.ajaxSafePost({
type: "POST",
url: _url,
contentType: "application/json",
data: JSON.stringify(payload)
})
.done(function (response) {
Expand Down