Returns a URI that can be used to download a drawing file. For example, the URL below returns a URI to the MTO file from the deliverable whose id is '{0001ADB6-0000-0000-9300-1BC0C4591E04}'.
POST <ServiceRoot>/Sites('MySiteAlias')/Plants('MyPlant')/Deliverables('{0001ADB6-0000-0000-9300-1BC0C4591E04}')/Files('0001ADB6-0000-0000-9300-1BC0C4591E04_MTO')/Com.Ingr.Core.V1.RetrieveFileUri/
To know the various formats supported, a query can be made to include instant annotations as follows:
GET
<ServiceRoot>/Sites('MySiteAlias')/Plants('MyPlant')/Deliverables('{0001ADB6-0000-0000-9300-1BC0C4591E04}')/Files(‘0001ADB6-0000-0000-9300-1BC0C4591E04_Default’)?$format=application/json;odata.metadata=full
A Prefer header with the value "odata.include-annotations=*" has to be added.
In the json response, the key "@ingr.supportedFormats" gives the supported formats in which to download the given file entity.
To request a file entity in given format, the format can be specified either in format query option or Accept header along with the uri returned by the RetrieveFileURI POST uri.
A deliverable file with key as "0001ADB6-0000-0000-9300-1BC0C4591E04_Default" can be downloaded in the following formats:
Required format |
Extension |
MimeType to be used in $format/AcceptHeader |
---|---|---|
Portable Document Format |
|
application/pdf |
AutoCAD Drawing Database |
.dwg |
image/vnd.dwg |
MicroStation Design |
.dgn |
image/vnd.dgn |
Drawing Exchange Format |
.dxf |
image/vnd.dxf |
For example:
GET
<ServiceRoot>/Sites('MySiteAlias')/Plants('MyPlant')/Deliverables('{0001ADB6-0000-0000-9300-1BC0C4591E04}')/Files(‘0001ADB6-0000-0000-9300-1BC0C4591E04_Default’)/$value?$format=application/pdf