Thanks, Mark, for that answer. It matches some of what I am doing. Yes, I am passing a value into the data lookup. And I did find the answer. I had to work with my coworker, a web developer, on the internal Web API that was built for this. He had to change something so that it reads the data from Nintex as “From Body” instead of “From Form.”
We discovered this through by looking through the logs, that when we called this Xtension in a Nintex workflow action, it contained the value of the parameter that we passed to it. But when using a data lookup on a Nintex Form, it did not contain that value in the web API logs. Therefore we realized that Nintex was expecting something else from us. So we rebuilt the web API to use a “fromBody” and have it accept JSON.
I’ll show you the “before” and “after” part of the Swagger file.
Before:
"post": {
"tags": [
"Customer"
],
"summary": "Lookup Customer By Tax ID",
"consumes": [
"multipart/form-data"
],
"produces": [
"application/json"
],
"parameters": [
{
"in": "formData",
"name": "taxId",
"required": true,
"type": "string"
}
],
After:
"post": {
"tags": [
"Customer"
],
"summary": "Extended Customer Details",
"consumes": [
"application/json",
"text/json",
"application/*+json"
],
"produces": [
"application/json"
],
"parameters": [
{
"in": "body",
"name": "body",
"required": true,
"schema": {
"$ref": "#/definitions/CustomerTaxId"
}
}
],
This now works for both the workflow action and the data lookup on the form, but we did have to re-build everything after we uploaded the new Swagger file definition into the Xtensions tab.
Next, I need some help in doing some Query JSON steps on some of the return data. I will post another question soon.