Exporting CRM Events (S3)
This feature automatically exports CRM events such as message sends, deliveries, and clicks generated in FlareLane to your Amazon S3 bucket every day. Because the exported data is stored in Parquet format, you can load it into your in-house data warehouse or BI tools to analyze campaign performance in detail.
Setup only needs to be done once. After you create an IAM Role in your AWS account to delegate write permissions to FlareLane and enter the destination bucket and permission details in the FlareLane console, data is loaded automatically starting the next day.
How it works
Section titled “How it works”| Item | Details |
|---|---|
| Run schedule | Runs automatically every day at 03:00 KST (manual runs are not supported) |
| Target period | The previous day, 00:00 ~ 24:00 based on the project timezone (default Asia/Seoul) |
| Target storage | Amazon S3 (other clouds such as GCS and Azure Blob are not currently supported) |
| File format | Parquet (snappy compression) |
| Authentication method | AWS STS cross-account AssumeRole. The project ID is verified via ExternalId to prevent confused deputy attacks. |
Exported files are stored using the following path rule.
s3://<bucket>/<prefix>/<YYYY-MM-DD>/<YYYYMMDDHHMMSS>_part_<NNN>.parquet
// e.g. s3://my-flarelane-export/crm/2026-05-14/20260515030412_part_001.parquetSupported event types
Section titled “Supported event types”During setup, you can freely choose which events to export from the list below (at least 1 is required). Events of unselected types are excluded from the export.
| Category | Event type |
|---|---|
| Push | push.sent, push.aborted, push.failed, push.clicked |
| SMS | sms.sent, sms.aborted, sms.failed, sms.delivered, sms.undelivered |
| Kakao AlimTalk | kakaoalimtalk.sent, kakaoalimtalk.aborted, kakaoalimtalk.failed,kakaoalimtalk.delivered,kakaoalimtalk.undelivered |
| Kakao Brand Message | kakaobrandmessage.sent,kakaobrandmessage.aborted,kakaobrandmessage.failed,kakaobrandmessage.delivered,kakaobrandmessage.undelivered |
email.sent, email.aborted, email.failed, email.delivered, email.opened, email.clicked, email.complaint | |
| In-App Message | iam.displayed, iam.clicked, iam.closed |
Prerequisites
Section titled “Prerequisites”Please prepare the following items before starting setup.
| Item | Description |
|---|---|
| Amazon S3 bucket | The bucket where exported data will be loaded. We recommend using a separate bucket dedicated to CRM events. |
| CloudFormation stack / IAM Role creation permission | Required to perform Step 2 in your AWS account. |
| Project ID | You can find this on the project settings screen in the console. It is used as the ExternalId condition value in the IAM Role Trust Policy. |
| FlareLane Glue Role ARN | A value FlareLane provides separately. It is used as the Principal in the IAM Role Trust Policy. |
| KMS key ARN | (Optional) Required only if the destination bucket is encrypted with SSE-KMS (a customer-managed key). Not needed for the SSE-S3 default encryption. |
Setup steps
Section titled “Setup steps”This is the CloudFormation template used for setup. Download it with the button below and use it in Step 2.
Download iam-role.yaml
Step 1: Prepare the S3 bucket
Section titled “Step 1: Prepare the S3 bucket”Prepare the destination S3 bucket for the export in your AWS account. You may reuse an existing bucket, but we recommend using a separate bucket dedicated to CRM events.
Step 2: Create the IAM Role and Policy
Section titled “Step 2: Create the IAM Role and Policy”Create an IAM Role and permissions so that FlareLane's Glue Job can write data to your S3 bucket and clean up temporary files (rename and cleanup) after loading. Choose one of the two methods below.
Method A — CloudFormation template (recommended)
Section titled “Method A — CloudFormation template (recommended)”- Download the template using the
iam-role.yamldownload button above. - In the AWS console, go to CloudFormation → Create stack → With new resources (standard) and upload
iam-role.yamlvia Upload a template file. - Enter the following parameters.
| Parameter | Description |
|---|---|
ProjectId | FlareLane project ID. Used as the ExternalId in the Trust Policy. |
DestinationBucketName | The S3 bucket name you prepared in Step 1 |
FlarelaneGlueRoleArn | The Glue Role ARN provided by FlareLane |
KmsKeyArn | (Optional) Enter only if the bucket is encrypted with SSE-KMS. Leave blank for SSE-S3. |
- On the final review step, select the "I acknowledge that AWS CloudFormation might create IAM resources with custom names" checkbox and then create the stack.
- When the stack is created, copy the
RoleArnvalue from the Outputs tab. You will use it for the console input in Step 3. - (SSE-KMS buckets only) Copy the
KmsKeyPolicyStatementJSON from the Outputs tab and add it as a Statement to that KMS key's Key policy (KMS console → Customer managed keys → select the key → edit key policy). Cross-account KMS access is not sufficient with IAM permissions alone; you must also allow this Role as aPrincipalin the key policy.
Method B — Manual setup
Section titled “Method B — Manual setup”If you configure it directly in the console without using CloudFormation, follow the steps below.
(1) Create the IAM Role
- In the AWS console, go to IAM → Roles → Create role.
- Select Custom trust policy as the Trusted entity type and paste the JSON below as is. Replace the two placeholders with the actual values.
<FLARELANE_GLUE_ROLE_ARN>: The value provided by FlareLane<FLARELANE_PROJECT_ID>: FlareLane project ID
{ "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "AWS": "<FLARELANE_GLUE_ROLE_ARN>" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "sts:ExternalId": "<FLARELANE_PROJECT_ID>" } } } ]}- Enter any Role name (e.g.,
flarelane-crm-export-role) and create it.
(2) Attach the S3 inline policy
- On the detail screen of the Role you created, select Add permissions → Create inline policy.
- Switch the policy editor to JSON mode and paste the JSON below. Replace
<DESTINATION_BUCKET>with the bucket name you prepared in Step 1.
{ "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObject", "s3:ListBucket" ], "Resource": [ "arn:aws:s3:::<DESTINATION_BUCKET>", "arn:aws:s3:::<DESTINATION_BUCKET>/*" ] } ]}- Enter any policy name (e.g.,
flarelane-crm-export-policy) and save it.
(3) Grant KMS permissions — SSE-KMS buckets only
If the destination bucket is encrypted with a KMS customer-managed key, you must configure the following two items in addition to the policy above.
- Grant the Role KMS permissions (
kms:GenerateDataKey,kms:Decrypt) and set theResourceto that key ARN. - Add a Statement to that KMS key's Key policy that allows this Role as a
Principal. Cross-account KMS access is not sufficient with IAM permissions alone and must always be accompanied by key policy authorization.
Step 3: Enter the settings in the FlareLane console
Section titled “Step 3: Enter the settings in the FlareLane console”On the Project settings → CRM event export screen in the FlareLane console, enter the following values.
| Field | Description |
|---|---|
| Enabled | Turn the export on/off |
| S3 bucket name | The bucket name you prepared in Step 1 |
| S3 path prefix | Path prefix within the bucket (optional) |
| IAM Role ARN | The ARN of the Role you created in Step 2 (for Method A, the stack Outputs RoleArn) |
| Event types to export | Select from the Supported event types above |
After saving and turning on the enable toggle, the export starts automatically from the next 03:00 KST.
Step 4: Verify operation
Section titled “Step 4: Verify operation”The first run occurs between 03:00 ~ 03:30 KST the day after you enable it. Please check the following during the morning of that day.
- Verify that a
<prefix>/<yesterday's date>/directory has been created inside the destination S3 bucket. - Verify that a file in the format
<YYYYMMDDHHMMSS>_part_001.parquetexists in the directory. - Open the Parquet file and check that the events from the previous day have been loaded correctly.
If the directory has not been created, please check the following items.
- Whether the relevant events actually occurred on the previous day (if none occurred, even an empty directory is not created)
- Whether the relevant events are included in the Event types to export filter you selected
- Whether the
sts:ExternalIdvalue in the IAM Role Trust Policy matches your project ID - Whether the
ResourceARN in the IAM Policy matches the actual bucket name - (For SSE-KMS buckets) Whether the export Role is allowed as a
Principalin the KMS key's Key policy
If data is still not loaded even though all of the above items are correct, please contact the FlareLane support team.
Frequently asked questions
Section titled “Frequently asked questions”Q. Can I receive all historical data from before the feature was enabled in one batch?
This is not supported. Data is loaded on a daily basis starting from the "previous day" after the time of enablement. If you need data from a past period, please contact the FlareLane support team.
Q. Yesterday's data is empty.
It is likely one of the following two cases.
- There were no CRM events on that date (in this case the S3 directory itself is not created)
- The type of the events that occurred is not included in the Event types to export filter
Q. What happens if I change the S3 path prefix midway?
Data is loaded to the new prefix path starting from the time of the change. Files stored under the existing prefix path are kept as is, and FlareLane does not move them automatically.
Q. I entered the IAM Role ARN incorrectly. Will that day's data be automatically loaded again?
It is not recovered automatically. If you correct the ARN to the right value and save, data is loaded normally starting the next day. If you need the data for the missing dates, please contact the FlareLane support team.
Q. Can I export to multiple S3 buckets simultaneously from a single project?
Currently only 1 destination bucket can be configured per project.