Prerequisites for using AWS B2B Data Interchange
This topic describes how to sign up for an AWS account, create an admin user, and configure an Amazon S3 bucket to use with B2B Data Interchange.
Sign up for an AWS account
To get started with AWS, you need an AWS account. For information about creating an AWS account, see Getting started with an AWS account in the AWS Account Management Reference Guide.
Configure an Amazon S3 bucket
You need to have an Amazon S3 bucket set up and ready to use. B2B Data Interchange requires buckets for storing input, output, and instruction documents. For details, see Getting started with Amazon S3.
-
The Amazon S3 bucket must be in the same AWS account as the B2B Data Interchange user.
-
The Amazon S3 bucket must be in the same region as the B2B Data Interchange user.
Setting up S3 bucket policies and permissions
Before you can transform and generate Electronic Data Interchange (EDI) documents, you must configure S3 bucket policies for your trading capabilities. This topic provides step-by-step instructions and example policies to help you get started.
Configuring S3 bucket policies
Follow these steps to configure policies for both your input and output buckets. If your buckets use SSE-KMS encryption, you must also update your AWS KMS key policy. For policy examples, see Example policies.
To configure a bucket policy
-
Open the Amazon S3 console at https://console.aws.amazon.com/s3/
. -
Navigate to your bucket and choose the Permissions tab.
-
In the Bucket policy section, choose Edit.
-
Do one of the following:
-
Copy an example policy from Example policies and paste it into the policy editor.
-
Choose Copy policy when creating a trading capability, and paste the copied policy.
-
-
Choose Save changes.
Note
For information about temporary files and related permissions, see Managing temporary files and permissions.
Enabling EventBridge notifications
You must enable Amazon EventBridge notifications for your input S3 bucket.
To enable EventBridge notifications
-
Open the Amazon S3 console at https://console.aws.amazon.com/s3/
. -
Navigate to your bucket and choose the Properties tab.
-
Scroll to the EventBridge section.
-
If notifications are already enabled, you're done. Otherwise, continue to the next step.
-
Choose Edit.
-
Select On and choose Save changes.
Important
After enabling EventBridge, wait at least 5 minutes before placing files in your S3 bucket. This allows time for the changes to take effect.
Managing temporary files and permissions
Your output bucket policies require the following permissions:
-
s3:GetObject- Allows the service to read temporary files -
s3:DeleteObject- Enables cleanup of temporary files
Important
Without the s3:DeleteObject permission:
-
Temporary files remain in your S3 bucket and incur storage charges.
-
These files can be up to ten times larger than the input X12 file.
The service uses the following locations for temporary files:
-
customerOutputDirectory/parsed- For service use -
customerOutputDirectory/- For S3 use (when using partnerships)tradingPartnerId/parsed
Example policies
Use these example policies to configure permissions for your S3 buckets and AWS KMS keys.
Important
Replace all user input placeholder values with your own
information.
If you use SSE-KMS or DSSE-KMS encryption, you must also configure AWS KMS key policies:
Important
Don't use AWS managed key policies - they can't be edited. Create a customer managed key instead.
If you use the same bucket for both input and output, use either policy and add the other permission, as shown in this example: