Инструменты для захвата и конвертирования Интернета
Интернет-сообщество GrabzIt

Загрузка файла изображения

Задайте вопросы о том, как захватывать или конвертировать веб-страницы или HTML into изображения, CSV, PDF или DOCX документы, а также о том, как конвертировать видео into анимированные GIF с использованием нашего API.

Здравствуйте,

 

I am using REST API and I have converted the file and I am getting the response of the POST as file name = 123456.jpeg

I want the URL of the file to push to my server, as I am running the REST API remotely.

Can you assist me with the URL of the output generated file?

 

С уважением,

Рама

Asked by Ramu Angappan on the 28th of May 2021

Здравствуйте,

Как говорится в документации you should not be using the REST API in the client side as it will expose your application key. The capture is returned in the HTTP response so you just have to save it. You should not be using the URL's that GrabzIt uses as these are short lived as we don't store captures for long.

However if you want to load it in the browser and then save it on the server I recommend using the JavaScript API and one of the server side API's there are examples on how to do this.

С уважением

Ответ от службы поддержки GrabzIt от 28 мая 2021 г.

Thanks for quick response but the problem is the data is stored in zoho and I need to pass HTML data from it only.

They have their own coding language to invoke url 

when using their function I get a response from Grabz.it as 1254367.jpeg only.

 

Zoho invokeurl link :- Ссылка

Answered by Ramu Angappan on the 28th of May 2021

That's not our software so you would need to ask Zoho.

Ответ от службы поддержки GrabzIt от 28 мая 2021 г.

Ok, we'll check with them, IS there a way to get that short lined URLs from the response I get? I can push that URL to my Dropbox account and serve it there as an image document

Answered by Ramu Angappan on the 28th of May 2021

Вы могли бы использовать export functionality but you would also need to use a callback handler.

Ответ от службы поддержки GrabzIt от 28 мая 2021 г.

I tried the below Rest API link for export

"https://api.grabz.it/services/convert.ashx?key=xxxxxx&export=dropbox%3A%2F%2F&customid=123&html=<html><table id ="customers"><tr><th colspan=3>Retails Month Till Date - 28-May-2021</th></tr><tr><td>BATTERY</td><td>109.0</td><td>79134.86</td></tr><tr><td>CYCLES</td><td>199.0</td><td>949866.77</td></tr><tr><td>LUBRICANTS</td><td>8.0</td><td>1627.04</td></tr><tr><td>TUBE</td><td>10.0</td><td>1370.0</td></tr><tr><td>TYRE</td><td>22.0</td><td>13652.0</td></tr></table></html>&css=#customers {font-family: Arial, Helvetica, sans-serif; border-collapse: collapse; width: 100%;} #customers td{ border: 1px solid #ddd; padding: 8px; text-align:center} #customers tfoot { border: 1px solid #ddd; padding: 8px; } #customers tr:nth-child(even){background-color: #f2f2f2;} #customers tr:hover {background-color: #ccc;} tr.d4560 { background-color:yellow; color:red; font-weight: bold ;} tr.d4560:hover {background-color: #ccc;} tr.d30 { background-color:pink; color:black; font-weight: bold ;} tr.d30:hover {background-color: #ccc;} td.pym3 { background-color:#87cefa; color:black; font-weight: bold ;} #customers th { padding-top: 12px; padding-bottom: 12px; text-align: left; background-color: #4CAF50; color: white; text-align:center;}"

But it's not saving the file to Dropbox and I am still getting the file only as a response.

 

Answered by Ramu Angappan on the 28th of May 2021

If you are converting HTML all the variables have to be posted. If you make that call in your browser you will see the error. Also as I said you would need a callback handler otherwise you won't know what the exported file refers to.

Ответ от службы поддержки GrabzIt от 28 мая 2021 г.