Developer
Ask a QuestionBlecon WebsiteBlecon Console
  • Learn Blecon
    • Introduction
    • Blecon Modems
      • Device Identity and Network Security
      • Modem Firmware vs Modem Library
      • Using the Modem
      • Communicating with the cloud
      • Sending data from the cloud to a device
    • Blecon Hotspots
    • Blecon Networks
      • Blecon Accounts
      • Registering devices
        • The Blecon Scanner
        • Blecon Scanner Developer Guide
      • Blecon Events
      • Cloud Integrations
  • Cloud Integrations
    • Webhook
    • AWS S3
    • AWS SQS
    • AWS EventBridge
    • Memfault
  • Getting Started Guides
    • Getting started index
    • Install the Blecon Modem Firmware
    • Set up a Blecon Hotspot
    • Use Blecon from your computer with the Blecon CLI
    • Create a Network and register a device
    • Send device requests and events to your web service
    • Use Blecon from a Development Board
    • Use the Blecon Modem from an MCU
  • Device Guides
    • KKM S5-BCN
  • Development Board Guides
    • Supported Development Boards
    • Ezurio DVK-BL54L15
    • Fanstel EV-BM15C
    • InsightSiP ISP2454-LX-EB
    • Nordic nRF52840DK
    • Nordic nRF54L15DK
    • Minew ME54BE01
    • Panasonic PAN-B511 EVB
    • Raytac AN54L15Q-DB
    • u-Blox EVK-NORA-B20
  • Modem Reference
    • Modem Firmware Releases
      • nRF54L15 DK
      • nRF52840 Dongle
      • nRF52840 DK
    • CLI Releases
    • SDK Releases
    • Modem API Reference
    • Modem Protocol Reference
      • Request Frames
      • Command Protocol
      • UART Transport
    • Guides and best practices
      • Retrieve a device's identity
  • Cloud Reference
    • Configuration API
    • Advanced event routing
  • Hotspot Reference
    • Blecon Hub
Powered by GitBook

Get Support

  • Ask a question
On this page
  • AWS S3
  • Introduction
  • Click next, then find the policy you created in the previous step, and attach it to the role.
  1. Cloud Integrations

AWS S3

Upload and download from S3 buckets

AWS S3

Introduction

The Blecon AWS S3 integration securely stores device events in S3 buckets. It also allows devices to download the contents of S3 buckets.

With this integration, you can easily log any amount of device data for further processing, and allow devices to download configuration or firmware.

Uploading Data

The S3 integration places device events in the bucket in JSON format. It names the event files as follows:

/<year>/<month>/<day>/<device_id>/<event_id>

Note that your device must send a Blecon request of type Message to upload data.

Downloading Data

The S3 integration supports two methods for downloading data from a bucket.

Method: Device ID

device.request.<namespace>.s3_download_id

The response will be the contents of /<device_id> from the bucket, if any.

Method: Filename

device.request.<namespace>.s3_download_filename

The filename should be supplied as an ASCII string in the request's payload. The response will be the contents of that location.

Preparing your AWS account

Note Region

Note the region in use, which is found in the top right of the AWS Console.

Create Bucket

Navigate to the S3 service in the AWS Console, and create a new bucket. You will need to choose a globally unique name.

Create IAM Policy

Noting the bucket name you created, create a policy like the below.

{
	"Version": "2012-10-17",
	"Statement": [
		{
			"Sid": "VisualEditor0",
			"Effect": "Allow",
			"Action": "s3:*",
			"Resource": [
				"arn:aws:s3:::<BUCKET NAME>",
				"arn:aws:s3:::<BUCKET_NAME>/*"
			]
		}
	]
}

For ease of creating, select the JSON editor, paste the below, and insert your bucket name where indicated.

Create IAM Role

Now that we've created the policy, we can create a role, and attach the policy to it.

<<<<<<< HEAD Navigate to the IAM service in the AWS Console and select Create Role. For Trusted Entity, choose AWS account and enter 202578976232.

Click next, then find the policy you created in the previous step, and attach it to the role.

Navigate to the IAM service in the AWS Console and select Create Role. For Trusted Entity, choose AWS account and enter 329599652485

Click next, then find the policy you created in the previous step and attach it to the role.

main

Click next and note the below on role naming, or the integration will not work.

Ensure the role has a name that begins with the text BleconIntegrationRole

Find the role in the list of roles, and copy the ARN.

Configuring the Integration

Now you should have everything you need to configure the Blecon integration:

  • Bucket Name

  • IAM Role ARN

  • Region

  • Bucket Name

The namespace is your choice. Device requests must use this namespace to be routed to this integration.

PreviousWebhookNextAWS SQS

Last updated 2 months ago

Log into or.

If you have questions, feel free to !

create an AWS account
contact us
Creating an AWS policy
Creating a role for Blecon
Creating a role for Blecon
Obtaining the ARN for your new role
Configuring the AWS Integration in the Blecon Console