Skip to main content

Library python for simplify to create lambda function (AWS lambda) and Dazzl API service.

Project description

LIB Dazzl Lambda Tools | Build Status Requirements Status

Library python for simplify to create lambda function (AWS lambda) and Dazzl API service.

The authentication is automatically executed and use a environment variable.

How to use

# Import
import dazzl_aws_lambda_tools as aws_lambda

# Initialize
# It's a bucket event
dz = aws_lambda.Tools(record)

# Send a request to backend
path = '/super/path/with/id/and/another/data'
body = { 'foo' 'bar' }
dz.send('POST', path, body)

# Get name to bucket

# Get key to bucket

Logger and environments

The logger has different level :

  • development has level DEBUG,
  • staging has level INFO,
  • production has level ERROR

if you want customize log level use variable environment LOG_LEVEL

For more information see : Logging Levels

Variables environments

Name Value example Required
LOG_LEVEL info false
URL_API__<env> true if you want send request
USERNAME_<env> true if you want send request
PASSWORD_<env> hidden_password true if you want send request

<env> is a environment type :

  • development : DEVE
  • staging : STAG
  • production : PROD

Convention bucket name

The bucket name exist for three environment :

Environment Example bucket name

Script test

clear; python3 -m memory_profiler ./tests/ ; python3 -m memory_profiler ./tests/

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for dazzl-aws-lambda-tools, version 0.4
Filename, size File type Python version Upload date Hashes
Filename, size dazzl_aws_lambda_tools-0.4.tar.gz (5.0 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page