Nintex and Azure functions are heavily used in my new
company for O365. There is a need to integrate Nintex workflow with Azure
functions. The first task for me is to configure how the Nintex workflow to
call Azure function and retrieve the returns from the function. Here are details I would like to keep as my
reference.
1. The first step is to set up a SharePoint online list that
could test the Nintex workflow. The list is out of box simple list with default "Title" field.
2. Second step is to set up a simple Azure function as
indicated as in this blog. You could use visual studio to create a default Azure function and deploy to Azure as described here. Then you need to identify the endpoint that your Nintex workflow can call.
In your new function, click </> Get function URL at the top right, select default (Function key), and then click Copy.
The endpoint will looks like this:
Since this is simple function and will only take one input query key/value as name as "Bob" to display "Hello Bob", the key and value will be passed in the URL.
3. The third is to set up a Nintex workflow. Here are details.
a. Set up a Nintex workflow variables as in the screenshot.
b. Set the variables through Build Dictionary action as in the screenshot.
c. Add workflow action Call Http Web Services to call Azure function using the function endpoint as described before. Please note the URL is hard coded and we will discuss how to get it from configuration list.
d. Add Log to History List action to debug the function.
After save and publish, the overall workflow will look like this:
3. Run the workflow from the list item and verify the workflow history.
Now you can integrate Azure function from Nintex workflow. The next steps will to create Azure functions that will return other format like xml or jason. Then use Nintex workflow to retrieve the return result and process the business logic. This seems like similar as text returns.
No comments:
Post a Comment