Skip to content

Quick demo of AWS S3 integration, RESTful API, data collection

Notifications You must be signed in to change notification settings

FrancoJim/sample_code_2

Repository files navigation

Sample Code 2

This is just a sample application to demonstrate coding capabilities.

Python Dependencies

  • pytest
  • boto3
  • pandas
  • poetry
  • Bureau of Economic Analysis (BEA) RESTFUL API

Pre-requisites

Copy Environment Variables File

cp example.env .env

Bureau of Economic Analysis (BEA) API Request

  1. Go to BEA Data Application Programming Interface (API)
  2. Register for an API key.
  3. Open email and click on the link Please click here to activate your key.
  4. Complete Captcha and click Activate Key.
  5. Copy the API key from email.
  6. Add API key string to environment variable BEA_API_KEY in .env file.

AWS Credentials

  1. Go to AWS Management Console
  2. Click Username in upper-right corner, then My Security Credentials.
  3. Click on Access keys (access key ID and secret access key).
  4. Click on Create New Access Key.
  5. Copy and add Access key ID and Secret access key to environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY in .env file.

Docker Execution

To run the application in a Docker container, execute the following command:

Production

docker-compose --profile sample_2_prod up -d

Development

docker-compose --profile sample_2_dev up -d

Packaging

docker-compose --profile sample_2_package up -d

Testing

docker-compose --profile sample_2_test up -d

About

Quick demo of AWS S3 integration, RESTful API, data collection

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages