Skip to main content
Nintex Community Menu Bar
Question

Why my response contains extra fields, Is this okay

  • May 6, 2025
  • 9 replies
  • 78 views

Forum|alt.badge.img+2

My actual response from apis is

 


{
"restrictions": [
"apple",
"banana",
"orange"
]
}

 

9 replies

Forum|alt.badge.img+2
  • Author
  • Rookie
  • May 6, 2025
{
"$type": "System.String[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089",
"$values": ["apple","banana","orange"]
}

This is response


Forum|alt.badge.img+11
  • Nintex Employee
  • May 6, 2025

The REST endpoint may return an object like in this case, instead of rows and columns.  It looks like it is an array of strings.

You can use the String System Types > Deserialize, Deserialize Array or Deserialize Typed Array (depending on the situation) to return it as rows/columns instead.

https://help.nintex.com/en-US/k2cloud/userguide/current/Content/SBrokers/SB-Serialization.htm

It is also possible to chain the Service method in a single SmartObject method.

 


Forum|alt.badge.img+2
  • Author
  • Rookie
  • May 6, 2025

I tried it’s not working

 "/TestStringArray": {
      "get": {
        "summary": "Get String Restrictions Array",
        "description": "Returns the restrictions array made of strings.",
        "operationId": "getTestStringArray",
        "responses": {
          "200": {
            "description": "A string array response",
            "schema": {
              "$ref": "#/definitions/TestStringArrayResponse"
            }
          },
          "default": {
            "description": "Unexpected error",
            "schema": {
              "type": "object",
              "properties": {
                "message": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    }
  },

    "TestStringArrayResponse": {
      "type": "object",
      "properties": {
        "restrictions": {
          "type": "array",
          "items": {
            "type": "string",
            "example": "apple"
          }
        }
      }


 

 


Forum|alt.badge.img+11
  • Nintex Employee
  • May 6, 2025

You will also want the SmartObject method to be a List type, and not a Read type; if it is only returning 1 row.


Forum|alt.badge.img+2
  • Author
  • Rookie
  • May 6, 2025


WHEN I USED SYSTEM Object Deserialize Array type array

 

 


Forum|alt.badge.img+2
  • Author
  • Rookie
  • May 6, 2025

Can some-one help what is going on


Forum|alt.badge.img+11
  • Nintex Employee
  • May 6, 2025

Is your SmartObject method that contains the chained Service Object methods, of the Type List?


Forum|alt.badge.img+2
  • Author
  • Rookie
  • May 7, 2025

Yes

 


Response is :

 


when I add

 

 


Forum|alt.badge.img+2
  • Author
  • Rookie
  • May 7, 2025

Continue …

WHEN I USED SYSTEM Object Deserialize Array type array

 


response is