#!/usr/bin/env python
# Copyright (c) TripleBlind Holdings, Inc. Confidential and Proprietary. All rights reserved.

import yaml

import tripleblind as tb


raise SystemExit("This script is for reference only.")

tb.initialize()

#############################################################################
# Amazon S3 (Simple Storage Service) buckets can be hold any sort of data files.
# A TripleBlind data asset can be connected to files stored within S3 buckets.
# Beyond the file itself, you also need to bucket, region and proper credentials
# to access the data.

# The storage location
BUCKET_NAME = "9bec276a-68c7-1234-aa91-ff93c418e600"
REGION = "us-east-1"

# The name of the stored object (a CSV file)
OBJECT_NAME = "test_data.csv"

# AWS credentials to access the bucket
# (these are not actual credentials but should look similar)
AWS_ACCESS_KEY_ID = "AKIAXWFHNGRFDXV5FQVX"
AWS_SECRET_ACCESS_KEY = "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"

tb.asset.S3Dataset.create(
    bucket_name=BUCKET_NAME,
    region=REGION,
    object_name=OBJECT_NAME,
    aws_access_key_id=AWS_ACCESS_KEY_ID,
    aws_secret_access_key=AWS_SECRET_ACCESS_KEY,
    name="Demo Asset",
    desc="Dataset of stored in an S3 bucket",
    is_discoverable=False,
)
