> For the complete documentation index, see [llms.txt](https://docs.couchdrop.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.couchdrop.io/managed-file-transfer/as2/connect-to-external-as2.md).

# Connect to external AS2

Learn about connecting to external AS2 providers with Couchdrop

## Introduction

Couchdrop supports outbound AS2 connections for securely sending files to external AS2 partners.

Once configured, the AS2 connection appears in Couchdrop as a virtual folder. Files uploaded to that folder are packaged as AS2 messages, encrypted, signed where configured, and sent to your trading partner.

{% hint style="info" %}
This page covers outbound AS2 connections. To receive files over AS2, see [Inbound AS2 Stations](/managed-file-transfer/as2/as2-stations.md).
{% endhint %}

### How it works

Unlike storage-based connections, an outbound AS2 connection is designed for sending messages rather than browsing remote files.

The connection appears in Couchdrop as an outbound [virtual folder](/how-couchdrop-works.md). You can upload files to this folder, but operations such as listing files on the remote AS2 system or downloading files from it are not supported.

When a file is uploaded to the AS2 folder, Couchdrop packages it into an AS2 message, applies the configured encryption and signing, and sends it to the external AS2 endpoint.

## How to connect to an external AS2 partner

{% hint style="warning" %}

### Before you start

To connect to an external AS2 partner, you will generally need:

* Access to Couchdrop with the appropriate permissions
* Your trading partner's **AS2 ID**
* Your trading partner's **AS2 endpoint URL**
* Your trading partner's **public certificate**
* Your **public and private signing certificate/key pair**
  {% endhint %}

{% stepper %}
{% step %}

### Create an outbound AS2 connection

In Couchdrop, create a new connection and select **Outbound AS2** from the list of available connections.

Configure the connection name and virtual folder name.
{% endstep %}

{% step %}

### Configure the AS2 partner

Enter your trading partner's AS2 configuration details, including their **AS2 ID** and **AS2 endpoint URL**.

Upload the trading partner's public certificate.
{% endstep %}

{% step %}

### Configure message signing

Under **Message Signature Configuration**, upload your public certificate and private key.

These credentials are used when signing outbound AS2 messages sent to your partner.
{% endstep %}

{% step %}

### Save and test the connection

Once created, the AS2 connection will appear as a virtual folder in Couchdrop. Upload a test file to confirm it can be delivered successfully to your AS2 partner.
{% endstep %}
{% endstepper %}

***

## Using outbound AS2 in Couchdrop workflows

Because the AS2 connection appears as an outbound virtual folder, other Couchdrop features can use it as a destination.

| Feature                   | How it works with outbound AS2                                                         |
| ------------------------- | -------------------------------------------------------------------------------------- |
| **Inbound SFTP and FTPS** | Files uploaded by SFTP or FTPS users can be sent to the AS2 connection.                |
| **Mailboxes**             | Email attachments received through a Mailbox can be sent to the AS2 partner.           |
| **Upload Links**          | Files received through an Upload Link can be routed to the AS2 connection.             |
| **Inbound Webhooks**      | Files received through an inbound HTTPS webhook can be sent to the AS2 partner.        |
| **Inbound AS2**           | Files received through an inbound AS2 Station can be forwarded to another AS2 partner. |
| **S3 Gateway**            | Files received through the S3 Gateway can be sent to the AS2 connection.               |
| **Automations**           | Use the AS2 virtual folder as an outbound destination in Couchdrop Automations.        |
