How to Use the ArcGISAttachmentConnector

Dan Minney
Dan Minney
  • Updated

Introduction

The ArcGISAttachmentConnector provides users with the ability to easily manage attachments in ArcGIS Online & ArcGIS Enterprise Portal. This transformer provides the ability to add, delete, download, List, and upload attachments. 

The ArcGISAttachmentConnector could be used for various purposes, such as:

  • Synchronizing attachments between ArcGIS Online and ArcGIS Enterprise (or vice versa)
  • Removing or updating outdated attachments
  • Uploading externally collected data to existing ArcGIS records
  • Integrating with external business systems (e.g., transferring files to/from ArcGIS as part of a business workflow)
  • Exporting attachments for archiving before deleting features or performing data migrations

 

Requirements

 

ArcGISAttachmentConnector Parameters

 

Authentication

  • Connection: Users can specify an ArcGIS Online web connection or an ArcGIS Enterprise web connection. 

Request

  • Action: Users can choose to Add, Delete, Download, List, or Update attachments

Feature

  • Feature URL: Users must provide the Feature URL. In ArcGIS Online & ArcGIS Portal this can be found on the bottom right of the ‘layer overview’ page.

 

Best Practices

 

Step-by-step Instructions

Part 1: Downloading Attachments With the ArcGISAttachmentConnector

In this example, we will walk through how to download attachments from an ArcGIS Online Feature Service using the ArcGISAttachmentConnector.

 

1. Read the ArcGIS Online Feature Service

First, we’ll add an Esri ArcGIS Online (AGOL) Feature Service reader to a blank workspace to read in the layer we want to download attachments from. We need to retrieve the ObjectIDs for our records to use in the ArcGISAttachmentConnector Feature URL parameter.

For information on how to connect to Esri ArcGIS Online, see Tutorial: Getting Started with ArcGIS Online and Portal.

 

2. List Attachments

Next, we can add an ArcGISAttachmentConnector to our workspace and connect it to the ArcGIS Online Feature Service Reader. 

We will use the List action in the ArcGISAttachmentConnector to get the attachment_id. Once we’ve retrieved the attachment_id we can then use this in a subsequent ArcGISAttachmentConnector to download the attachment.

 

In the ArcGISAttachmentConnector, we can set the parameters as follows:

 

When run, the ArcGISAttachmentConnector outputs a record for each attachment, including its attachment_id, attachment_name, and attachment_size.

 

3. Download Attachments

Next, another ArcGISAttachmentConnector can be added to the workspace and connected to the first one. In the ArcGISAttachmentConnector_2 parameters, we can set the parameters as follows:

 

When run, the ArcGISAttachmentConnector downloads the files to the folder specified. The Output port also includes an attribute that contains the file path of the downloaded attachment (_downloaded_path).

 

Part 2: Uploading Attachments with the ArcGISAttachmentConnector

In this next section, we will explore how to use the ArcGISAttachmentConnector to migrate attachments from ArcGIS Online to ArcGIS Portal.

 

1. Modify the ArcGISAttachmentConnector

Continuing from the previous example, we will modify the ArcGISAttachmentConnector_2 to download the attachment as an attribute. The advantage of this is that we can provide this attribute when we want to upload the attachment to ArcGIS Portal, removing the need to download the attachments locally to a hard drive.

 

2. Read the ArcGIS Portal Feature Service

Because the ArcGISAttachmentConnector uses the ObjectID to determine which record to upload the attachment to, we need to read in our ArcGIS Portal dataset and join it to our attachments data using a unique identifier, in this case, the TreeID attribute. 

 

3. Join the Attachments to ArcGIS Portal Records

After adding our ArcGIS Portal Reader to the workspace for our TreeInventory layer, we can a FeatureJoiner to join ObjectIDs to the attachments. In the FeatureJoiner, we are joining based on the TreeID, which we know is a unique identifier.

Note: set the Attribute Conflict Resolution parameter to Prefer Right if you have identical ObjectID column names between your two datasets. This will ensure that the output ObjectID value is from the dataset you want to write the attachments to. 

 

4. Upload Attachments

Lastly, we can add another ArcGISAttachmentConnector to the workspace and connect it to our FeatureJoiner. The ArcGISAttachmentConnector parameters are set as follows:

 

Once the ArcGISAttachmentConnector_3 has been configured, the workspace looks like this: 

 

When the workspace is run, the attachments will be uploaded to the corresponding ArcGIS Portal records. You can verify this by opening the feature service in ArcGIS Portal and viewing the attachments under the Data view.

Was this article helpful?

We're sorry to hear that.

Please tell us why.

As of January 14th, 2026, comments on knowledge base articles have been closed. To make sure questions don’t get missed and to enable more community support, we’ve moved discussions to the FME Community. If you have a question or a comment about this article, please create a new post or create a support ticket.