Attachments

The attachments REST API is a special one. The difference is that the attachments REST API represents both entity data and binary content. The others represent just entity data.

Note: attachments are a technical preview. Until made public, send an HPECLIENTTYPE header with the value: HPE_REST_API_TECH_PREVIEW in your requests.

Attachment collection

In some of the HTTP methods, resource collection behaves as any other collection entity, representing only the attachment entity data without the binary content. In other HTTP methods, there is reference to binary content.

URI

Attachments are relevant only in the workspace context:

.../api/shared_spaces/{uid}/workspaces/{id}/attachments

Note: For the syntax for specifying parameters in URIs, see Variables and values.

Supported HTTP request methods

The attachment collection supports the following HTTP methods:

Method

Description

GET

Retrieve data about the attachment, and/or the actual attachment.

POST

Create new attachments in a collection.

PUT

Update information about the attachment (not the binary data).

DELETE

Delete existing attachments.

Note: To update an actual attachment (the binary data), DELETE the original attachment and POST a new one.

Actions on attachment collections

Back to top

Attachment instance

The attachment instance contains both the attachment’s entity data and the binary content.

Supported HTTP request methods

The attachment instance supports the following HTTP methods:

Method

Description

GET

Retrieve data about the attachment, and/or the actual attachment.

POST

Create new attachments in a collection.

PUT

Update information about the attachment (not the binary data).

Only the attachment’s entity data can be updated.

DELETE

Delete existing attachments.

Note: To update an actual attachment (the binary data), DELETE the original attachment and POST a new one in the collection.

Actions on attachment instances

Back to top

See also: