cancel
Showing results for 
Search instead for 
Did you mean: 

SmartSheet API Connector from Digital Exchange - Having issue with Get sheet as CSV

Hello,

I'm using Smartsheet API and  able to use other Actions Available in Smartsheet -  Sheet Actions VBO and able to use different actions but having issue using Get sheet as CSV action. After I use the action the csv file is not storing in  my local based on the Smartsheet Document it will send the output as Output Stream But  there is no output parameter in   Get Sheet as CSV action  and file is not storing on my local is there a way I can store the file by passing path as input variable?
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri
1 BEST ANSWER

Best Answers

ewilson
Staff
Staff
@Harish Mogulluri,

Ah yes, that's an issue with the Web API feature. The XLSX and PDF files are binary content which the Web API feature doesn't properly support. There's a enhancement request open with product to address this.

In the meantime there is a workaround. It involves using the Utility - HTTP VBO​ to perform this one action. Here are some screenshots of a quick test I performed.

37028.png
37029.png
37030.png
37031.png
37032.png
Cheers,
Eric

View answer in original post

10 REPLIES 10

ewilson
Staff
Staff
@Harish Mogulluri,

The value in the Response_Content data item is the actual CSV content. You can use the Utility - File Management VBO to write that content out to a file.

Cheers,

Thanks @Eric.

Yes I noticed that  but basically I want to get highlighted colors in smartsheet as well . If I use the response content I may loose the highlighted cells just trying to figure out how to get the highlighted color.

Just to give some context basically We created a formula if some body updated the sheet from the past  24 hours  the smartsheet will highlight the updated cells.
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri

ewilson
Staff
Staff
@Harish Mogulluri,

If you want to include the special formatting of a sheet then you shouldn't be getting it as a CSV. CSV is typically just the actual content of a sheet, not it's formatting. To preserve formatting you'd need to get the sheet as an XLSX or PDF.

If you want to try getting the sheet in a different format you can change the value of the Accept header on the request. For XLSX, you'd set the header value to application/vnd.ms-excel. For PDF, you'd set the value to application/pdf.

Cheers,
​Eric

Yes I  tried changing that header  yesterday but the file is not saving on my local.

Thanks,
Harish
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri

Do you think  parsing the response content and updating to xlsx  using file management or any other way will get the desired result. I will check this anyway
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri

ewilson
Staff
Staff
@Harish Mogulluri,

Ah yes, that's an issue with the Web API feature. The XLSX and PDF files are binary content which the Web API feature doesn't properly support. There's a enhancement request open with product to address this.

In the meantime there is a workaround. It involves using the Utility - HTTP VBO​ to perform this one action. Here are some screenshots of a quick test I performed.

37028.png
37029.png
37030.png
37031.png
37032.png
Cheers,
Eric

Thanks for your response . I dont see HTTP Request file action . I'm using  BP 6.10.2 version. Is this VBO updated in Version 7?
-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri

ewilson
Staff
Staff
You can get the latest version of the Utility - HTTP VBO from the DX.

https://digitalexchange.blueprism.com/dx/entry/3439/solution/utility---http

Cheers,
Eric

Thank you Eric  That worked. I tried using C# code earlier to save the file using Smartsheet DLL but  some reason I'm getting an error and closing BP itself.

-----------------------
If I answered your query. Please mark it as the Best Answer

Harish Mogulluri