I tried again to reproduce the issue with your settings. But no luck.
In the log file /usr/share/co3/logs/client.log the error and a stack trace will be there. That may give a clue as to what is going on.
You could also a support case and they can help you through it.
Original Message:
Sent: Wed November 24, 2021 07:04 AM
From: GENARO NIETO FERNANDEZ
Subject: API Bug
Hi Ben,
thanks for your time and sorry for my delayed response. I have tried as suggested with a single value and a streamlined request (no additional row_id or names). Same problem.
![](https://dw1.s81c.com/IMWUC/MessageImages/f5d4e42f878846b3bf552be5322fbd39.png)
I see that your request was using the id for the column instead of the name. So I tried that. Same error:
Finally, I switched the datatable name by its id in the request. Worked.
![](https://dw1.s81c.com/IMWUC/MessageImages/633796a8f6f84dc2b01dadbd930925b5.png)
Is this the screenshot you need?
![](https://dw1.s81c.com/IMWUC/MessageImages/e70b60a87db847a382d3c932fcda76cb.png)
The GET request for the table works fine using the name instead of the ID (without handle_format:names):
![](https://dw1.s81c.com/IMWUC/MessageImages/3fbe6ab6a7e5421f95855d81e13476bf.png)
And with handle_format:names:
![](https://dw1.s81c.com/IMWUC/MessageImages/f580ffed5af14091aceb54849d3575a0.png)
Thanks!!
------------------------------
GENARO NIETO FERNANDEZ
Original Message:
Sent: Mon November 22, 2021 09:27 AM
From: Ben Lurie
Subject: API Bug
I was able to update a row using the name of the table:
![](https://dw1.s81c.com/IMWUC/MessageImages/3cbb6081e18a42749bb108b47fa75020.png)
Can you share a screenshot of the datatable configuration where the display name and API Name of the table is configured? Just to limit the test further, just try updating one column as I did.
Ben
------------------------------
Ben Lurie
Original Message:
Sent: Fri November 19, 2021 08:48 PM
From: GENARO NIETO FERNANDEZ
Subject: API Bug
Hi Team!
After a couple of days fighting with the SOAR API function for updating one datatable row I think I have found a bug. This wrong behavior is easy to reproduce both in SOAR v41 and v42 using the API swagger.
The documentation indicates that in order to update a datatable row, a PUT request must be sent to the URL:
According to the documentation, the {table_id} in these API calls is either the internal ID for that datatable or its name.
I always provide the name I selected for that table as the ID is an internal value. This (using the name for the table_id) works for the GET request to retrieve datatable data. But when providing the name in the PUT to update a row a 500 error is returned.
I tried many options for the uploaded data (even copying the response format from the GET although keeping just one row from the table). No way.
Then I went back to the SOAR dashboard and realized that (using the browser debugger), when updating a row, SOAR Dashboard uses the ID for the REST call. That was it! This PUT API does not accept the name when referring to a datatable (although the documentation states it does).
Steps to reproduce the error.
In swagger make a PUT request using the datatable name for the table_ID:
This results in this 500 error:
![](https://dw1.s81c.com/IMWUC/MessageImages/d8f6aef141d94764bd2efab76d4cbecd.png)
Now replace the name and use the ID :
The result is the expected one. RC is 200 and the updated row is returned (names has been specified for the handle_ouput format).
![](https://dw1.s81c.com/IMWUC/MessageImages/0e7c340115f74ecbb3e626a1c42fb329.png)
Using the datatable name is accepted (as I mentioned before) when using a GET request to retrieve the datatable contents:
![](https://dw1.s81c.com/IMWUC/MessageImages/702b70911aca43faaf522d9c0cb5af79.png)
Thanks for your time!
------------------------------
GENARO NIETO FERNANDEZ
------------------------------