Get attachment download URL
Request accessPurpose
This call is used to get a temporary link for downloading an attachment. Use the link with an HTTP GET
request to read the file. The file is not returned by this call itself.
A link is only given out once the file has passed the virus scan. See Attachments for the full picture.
How to request data
HTTP method: GET
- Constants and parameters enclosed in curly brackets { } must be replaced with their values.
- Please see the following Request parameters section with the required and optional parameters tables for these values. The generic URL format is as follows.
URL request format
https://{baseURL}/maps/orbis/feedback/{feedbackId}/attachments/{attachmentId}/download-url?key={API-key}&apiVersion={version}Request parameters
The following table describes the parameters that can be used in a request.
- Required parameters must be used or the call will fail.
Parameter | Required | Type | Description |
|---|---|---|---|
| Yes | string | The ID of the feedback the file belongs to. Part of the URL. |
| Yes | string | The ID of the attachment, as listed with the feedback. Part of the URL. |
Response data
The scanState field tells you whether the file is ready to be downloaded:
CLEAN- the file passed the virus scan.downloadUrlholds the link andexpiresAttells you when it stops working. It points at TomTom’s file storage on*.blob.core.windows.netand already carries a temporary access token, so use it exactly as you received it. The link is valid for 15 minutes; if it expires, simply make this call again.PENDING- the virus scan is still running, so no link is given yet. Wait a moment and try again.
A file that did not pass the virus scan is never handed out. In that case the call fails with the HTTP
code 409.
Response codes
HTTP Code | Message | Description | Sample response |
|---|---|---|---|
| OK | The file passed the virus scan and the link is ready | |
| OK | The virus scan is still running. Try again shortly | |
| Forbidden | Access denied | |
| Not Found | Attachment or feedback not found | |
| Conflict | The file did not pass the virus scan, or is otherwise not available for download | |
| Internal Server Error | Internal server error | |