---
title: "load(_:)"
framework: groupactivities
role: symbol
role_heading: Instance Method
path: "groupactivities/groupsessionjournal/attachment/load(_:)"
---

# load(_:)

Downloads the attachment data and asynchronously delivers it as the type you specify.

## Declaration

```swift
func load<AttachmentType>(_ attachmentType: AttachmentType.Type) async throws -> AttachmentType where AttachmentType : Transferable
```

## Parameters

- `attachmentType`: The type you use to interpret the data. An app typically uploads and downloads a single type of data for an activity. For more information about defining your types, see doc://com.apple.documentation/documentation/CoreTransferable/Transferable.

## Return Value

Return Value A requested type that contains the downloaded information.

## Discussion

Discussion Use this function to retrieve the file or data another participant provides. The method asynchronously retrieves and decodes the data, returning it as the requested type. If the requested type isn’t available, the method throws an error.

## See Also

### Downloading the attachment data

- [loadMetadata(of:)](groupactivities/groupsessionjournal/attachment/loadmetadata(of:).md)
