iSheets API version 2 - iSheet module - API - iSheet module - Get attachment
OVERVIEW
This api is designed to be used for downloading an iSheet item attachment.
GET /api/3/isheet/item/{itemid}/attachment/{attachmentid}
Parameter Name | Parameter Value | Description |
---|---|---|
item | number | isheet item ID |
attachmentid | number | isheet item attachment ID |
PLEASE NOTE: a common 'gotcha' here is to include the iSheetid in the uri (like when calling 'get item'). This is unnecessary. We only require the unique identifier of the iSheet item and attachment.
Response : Binary stream of document
Response Code
Code | Meaning |
---|---|
200 | Document found |
400 | Problem with parsing XML or JSON object (Bad Request) |
401 | Unauthorized |
403 | Validation failed/ Forbidden |
404 | Document doesn't exists in the system |
405 | Method not allowed (calling api with wrong method) |
500 | Internal error occured while gettting document content |
Maybe be little late but here goes! We are trying to download a doc from an Isheet. We keep getting a "forbidden" error when we try and call using
https://xxx.highq.com/focis/api/3/isheet/item/8/attachment/3
We changed the Isheet column to store Docs in Folder and selected a new folder. However when we run Get ITems call on the Isheet the Attchement ID it returns within URL of format below neither lets us get the Document using that URL OR the one listed above. We get a FORBIDDEN error.
Using that URL/API call doesn't work We get a 405.
Taking values FROM that and plugging them into URL above and in documentation doesn't work. We get a 403
https://xxx.highq.com/focis/api/3/isheet/item/8/attachment/3
When we change accept/header to Application/Octet we get 500 error. Is it issues around formatting headers?
We CAN get the Doc back from Folder / FIles API call BUT the Document ID is not the Attachment ID returned via the ISheet call. So we cant tie the doc to the Row in the isheet!!!
Imran Aziz, if you get a second can you see if you can help me with my use-case? I've raised a forum post as follows... https://developerportal.thomsonreuters.com/blog/download-isheet-attachments
Imran Aziz I reported it yesterday. The last update I sent to support was about receiving the 500 error, asking for details about how to configure the request (Headers, Content-Type and so on).
Alexander Beulich can you please raise this issue with HighQ support at support@highq.com as the technical team will need to investigate the issue. This issue was sorted in Collaborate 4.3.7 and should work well.
Imran Aziz I'm having the same issue as Andrew. I'm also getting a 500 error when trying to get an attachment through the API. Any news about this?
Andrew Quinn thanks for raising the issue, the technical team is looking into this issue, the URL returned in the get iSheet records is an http URL rather than an API URL. I will provide an update after investigating it with the team.
Hi Imran Aziz,
Having problems using this endpoint. Calling this with Accept header set to */* results in Access Denied response. Setting to application/octet-stream results in (500) Internal server error. When I retrieve the iSheet record item to find the attachment Id, the response includes an API url for the attachment, e.g.
As you can see, this is different to the API endpoint described in this wiki page. So I tried calling this different API endpoint, which results in a Method Not Allowed error response.
Comments
7 Comments