Docs
Sign up now
  • Getting started
    • Welcome to Sortment
    • Core Concepts
  • Schema
    • Overview
    • Related and Events Table
    • Setting Up Related Table
    • Setting Up Events Table
    • Custom Properties
  • ENGAGE
    • Audiences
      • Creating Audience
      • Audience Filters
      • Campaign Event Filters
      • Creating Audience Using SQL Builder
      • Managing Audiences
      • Audience Insights
    • Traits
      • Use Cases
      • Calculated Traits
        • Advanced Mode
      • Dynamic Traits
    • Profiles
      • User Profile View
    • Campaigns
      • Overview
      • Building a Campaign
      • Campaign Reports
        • Glossary
      • Conversion Tracking
  • Journeys
    • Getting Started
    • Journey Builder
    • Journey Components
      • Trigger
      • Delays
      • Flow Control
      • Action blocks
    • Tutorial: Creating a journey
    • Journey Settings
  • Connector
    • Overview
    • Getting started
      • Iterable
      • Klaviyo
  • Enable Data Sync
  • Setup
    • Data Warehouses
      • Snowflake
      • BigQuery
      • Redshift
      • Databricks
      • PostgreSQL
    • Cloud Bucket Storage
      • Amazon S3 for Snowflake
      • Google Cloud Storage for BigQuery
      • Amazon S3 for Redshift
      • Amazon S3 for Databricks
    • Communication Channels
      • Email
        • SendGrid
        • SES
        • Mailmodo
      • SMS
        • MSG91
        • Gupshup
      • WhatsApp
        • Meta (Facebook)
          • Add new Phone Number to Meta
        • Gupshup Enterprise
        • WATI
        • Gallabox
        • Yellow.ai
        • Kaleyra.io
    • Real-time Events
      • Setting up Event Source
      • Whitelist Event Payload
  • Settings
    • Sync Schedules
    • Audit Logs
    • Subscription Groups And Contact Fields
    • Delivery Controls
    • Test Profiles
    • Alerts
  • Data and Security
    • Technical Overview
    • Warehouse Data Practices
    • Data Access And Usage
    • Security Compliance
    • Audit Logs
    • Privacy Policy
Powered by GitBook
On this page
  • Connection configuration
  • AWS credentials setup
  • Creating Stage in Snowflake
  • Setting up the credentials

Was this helpful?

  1. Setup
  2. Cloud Bucket Storage

Amazon S3 for Snowflake

PreviousCloud Bucket StorageNextGoogle Cloud Storage for BigQuery

Last updated 2 months ago

Was this helpful?

As discussed in , Amazon S3 is required for several data-related use cases in Sortment.

Connection configuration

Following details are requied on Sortment for S3 connection for Snowflake:

  • AWS Region: The geographical region where your AWS services, including S3 and Snowflake, are deployed. Examples include us-east-1 (N. Virginia) or ap-south-1 (Mumbai). In your → Click on your profile (top-right) → See the selected region.

  • AWS S3 Bucket Name: A globally unique name assigned to an S3 bucket where you store and retrieve data. On → Go to S3 → Locate your bucket under “Buckets” list.

  • Access Key ID: A unique identifier for an AWS IAM user or service that allows programmatic access to AWS services. On → IAM → Users → Select your user → Security Credentials tab → Generate Access Key.

  • Secret Access Key: A secret key paired with the Access Key ID, used for signing API requests securely. Generated alongside the Access Key ID in IAM (only shown once). If lost, you must generate a new pair.

  • Snowflake Stage Name: This stage will be used to read and write data between your Snowflake and Amazon S3 bucket. You have to create a new stage for Sortment, and use the resepctive name here. Follow the to create the stage.

AWS credentials setup

Follow these steps to setup an S3 bucket for Sortment:

Creating a bucket

  1. Click on "Create bucket."

  2. Enter a unique bucket name (globally unique across AWS).

  3. Select an AWS region for the bucket. This should be same as your Snowflake cluster region.

  4. Create the bucket.

Creating a user

Create inline policy to the user

  1. From your AWS console navigate to Identity and Access Management (IAM) > Users > Select the user > Add permission > Create inline policy

  2. In the JSON policy editor, use the following policy. Update {$bucket-name} to the bucket created above. Give your policy a name and create the policy.

{
	"Version": "2012-10-17",
	"Statement": [
		{
			"Effect": "Allow",
			"Action": "s3:*",
			"Resource": [
					"arn:aws:s3:::{$bucket-name}",
					"arn:aws:s3:::{$bucket-name}/*"
				]
		}
	]
}

Configuring Access Key

The Access Key access type allows you to configure Sortment to use an IAM user by providing the user's Access Key ID and Secret Access Key.

Once you have an Access Key ID and Secret Access Key, paste those values into the form and click Create.

Creating Stage in Snowflake

Once the credentials are created, you need to create a stage in Snowflake to complete the S3 connection.

Ensure that the stage name is set as sortment.

-- Set variables
set bucket_url='s3://sortment';
set aws_key_id='REPLACE_WITH_YOUR_AWS_KEY';
set aws_secret_key='REPLACE_WITH_YOUR_AWS_SECRET_KEY';
set smt_default_role='SORTMENT_ROLE';

-- Set role for grants
USE ROLE identifier($smt_default_role);

-- Create stage for Sortment
CREATE OR REPLACE STAGE sortment
  URL=$bucket_url
  CREDENTIALS=(AWS_KEY_ID=$aws_key_id AWS_SECRET_KEY=$aws_secret_key)
  file_format = (type = csv field_optionally_enclosed_by='"' compression = none)

Setting up the credentials

Use the credentials generated above to connect Sortment to your S3 bucket and proceed.

Sign in to the AWS Management Console and .

Follow the user creation flow to create a new user for Sortment. If you need help, consult the on this topic.

If you need help generating these keys, consult the on this topic.

navigate to the S3 service
IAM article
IAM article
cloud bucket storage setup
AWS Console
AWS Console
AWS Console
steps below