Skip to main content
February 7, 2022
Question

WEB Api

  • February 7, 2022
  • 9 replies
  • 0 views

Hi All, 

I'm trying to pass JSON object in the startprocess but some how I'm not able to send all the attributes at one go 

Here is the sample JSON I'm passing 

{
"CompanyName": "Company",
"Category": "Information Technology",
"SubCategory": "COnsulting",
"Definition": "On Call",
"ShipToState": "AK",
"invoiceDetails": [
{
"InvoiceNumber": "3425638769",
"InvoiceDate": "1/28/2022",
"InvoiceValue": "400.00$",
"InvoiceDueDate": "2/22/2022",
"InvoiceBalance": "300.00$"

},
"InvoiceNumber": "3425638769",
"InvoiceDate": "1/28/2022",
"InvoiceValue": "400.00$",
"InvoiceDueDate": "2/22/2022",
"InvoiceBalance": "300.00$"

]
}

In the above JSON I was able to get all the individual attributes into the process model except the  Invoice details

Any help is much appreciated 

Thanks  

    9 replies

    peter.lewis
    Employee
    February 7, 2022

    That doesn't look like valid JSON to me - I think you need additional brackets around your second list of invoice numbers like this:

    {
      "CompanyName": "Company",
      "Category": "Information Technology",
      "SubCategory": "COnsulting",
      "Definition": "On Call",
      "ShipToState": "AK",
      "invoiceDetails": [
        {
          "InvoiceNumber": "3425638769",
          "InvoiceDate": "1/28/2022",
          "InvoiceValue": "400.00$",
          "InvoiceDueDate": "2/22/2022",
          "InvoiceBalance": "300.00$"
    
        },
        {
          "InvoiceNumber": "3425638769",
          "InvoiceDate": "1/28/2022",
          "InvoiceValue": "400.00$",
          "InvoiceDueDate": "2/22/2022",
          "InvoiceBalance": "300.00$"
        }
      ]
    }

    Can you update your request to include that valid JSON?

    February 7, 2022

    Hi Peter, Thank you for the Response ,but still I have no luck 

    Thank you

    Nanda

    peter.lewis
    Employee
    February 7, 2022

    I think you'll have to provide more context for us to help you. Did you update your request to send valid JSON? What does your Web API look like? How is the process model set up? What troubleshooting steps have you tried? The more information you provide the faster we'll be able to suggest a solution.