Attachment Service
- Create the attachment
- Get attachment information
- Download the attachment
- Update the attachment
- Delete the attachment
- Filter for getting project-only attachments & attachments that belong to a particular attachment-type
- Create a new version of an attachment
- Get all the versions of an attachment
- Share the attachment
- Download a particular version
- Delete a particular version
Attachment Service
Attachments are mostly documents or any media files with additional information which can be assigned to any project, object, issue or slide. Please see the detailed structure of the attachment in the Object Model
- Please use the Bimplus Project Service for creating an attachment or for getting/deleting all the attachments of a project
- Please use the Bimplus Object Service for creating an attachment or for getting/deleting all the attachments of an object, issue or slide
Anchor createAttachment createAttachment
Attachment Json
Create and update of attachments is using of calls with "multipart/form-data" content or by string.
The body of string format
Name | Mandatory/Optional | Type | Description |
---|---|---|---|
fileName | optional | string | Name of the attachment |
imageData | mandatory | string | data for image |
The responses of json in following format :
Name | Type | Description |
---|---|---|
id | guid | Attachment Id |
relatedId | guid | ID of the object/project/issue the attachment is attached to. |
name | string | Attachment name |
fileName | string | Name of the attachment's file |
type | string | Attachment's content type |
size | int | File size in bytes |
sizeMB | int | FIle size in megabytes |
createAt | string ( Date ) | Date of creation |
creator | json ( User ) | User who created the attachment |
changed | string ( Date ) | Date of last modification |
changedBy | json ( User ) | User who did the modification |
attachmentType | string | Bimplus attachment type. Default type is "Document" |
hash | string | File hash |
classification | string | Bimplus internal attachment classification. |
tag | string | Optional value, for additional marking of the attachment. |
objectIds | array of guid | Obsolete. Replaced by "relatedId" |
version | int | Attachment version |
rights | json | User's right to the attachment, has following boolean properties : update, share, delete, download |
release | string(bool) | True if attachment is share or false if attachment is not share. |
Create the attachment
Deck of Cards | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Get Attachment information
Deck of Cards | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Download the attachment
Deck of Cards | |||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Update the attachment
Deck of Cards | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Delete the Attachment
Deck of Cards | |||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Filter for getting project-only attachments & attachments that belong to a particular attachment-type
- The normal attachment GET call (i.e projects/<project_id>/attachments) returns all the attachments inside a project i.e it iterates through all the objects inside a project and returns everything. If we want to retrieve the only the attachments that belongs to the project directly, then use ?projectOnly=true filter (i.e projects/<project_id>/attachments?projectOnly=true)
- Bimplus recognized following types of attachments : Document, Thumbnail, Ifc, SketchUp, AllplanResource, AllplanDrawing, AllplanLayout, AllplanLayoutDocument, AutodeskResource, Revit, AutoCadDrawing, BcfZip.
Of those, the type "Document" is handled as public and visible to all applications. The rest are either Bimplus internal, or application specific attachment types, visible only to the particular applications ( e.g. all "Allplan..." types are used by Allplan only ).
If the type is not specified, the default type "Document' is used. - The normal attachment GET call (i.e projects/<project_id>/attachments) returns by default only the attachments of type "Document". If you want to retrieve the attachments that belongs to particular attachment type, then specify the type in the filter ?attachmentType=<requested_type> (eg: projects/<project_id>/attachments?attachmentType=Ifc&attachmentType=SketchUp).
Anchor | ||||
---|---|---|---|---|
|
Create a new version of an attachment
Deck of Cards | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Get all the versions of an attachment
Deck of Cards | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Share the attachment
Deck of Cards | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Download a particular version of the attachment
Deck of Cards | |||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||
|
Anchor | ||||
---|---|---|---|---|
|
Delete a particular version
Deck of Cards | |||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||
|