GET: Read an attachment

This topic provides instructions for using the GET operation to read an attachment.

Overview

An attachment instance has both entity and binary data. The properties of an attachment instance are represented by data in JSON format.

Attachment instances are members of attachment collections. See Attachments.

To get the attachment resource for an attachment entity, use the URI for the attachment collection with the attachment entity ID appended.

Tip: To get the entity ID, first read all instances and locate the desired entity.

Example: GET /shared_spaces/<space_id>/workspaces/<workspace_id>/attachments/50, where 50 is the attachment ID.

The GET supports two content types: 

  • application/json. To retrieve the attachment’s entity data only

  • application/octet-stream. To retrieve the attachment’s binary content only

Note: When GETting instances, the REST API does not necessarily display all fields for the instance. For a complete list of available fields, see Retrieving metadata.

Back to top

Examples

See also: