Skip to content

Quick AWS Lambda function to retrieve costs from Vultr using a Telegram Bot

Notifications You must be signed in to change notification settings

Fmrhj/aws-lambda-telegram-vultr

Repository files navigation

AWS Lambda for Vultr costs

AWS Deployment

Usage

# Install dependencies
make install

# Local test
make get_costs

# Test deployed lambda endpoint (from AWS API Gateway)
make test_endpoint

Configuration/ Environmental Variables

It requires a config.env file to debug the function locally. The AWS deployment requires the following environmental variables:

VULTR_API_KEY=<vutlr_api_key>
END_POINT=<vultr_endpoint>
TELEGRAM_API_KEY=<key>

Set webhook

make set_webohook

# or
bash run_set_webhook.sh

Deploy to AWS

Dependencies:

  • AWS account
  • AWS CLI
  • Create a custom role to deploy directly to AWS Lambda
make deploy

Note: HTTP deployment option is cheaper and sufficient for this use case.

About

Quick AWS Lambda function to retrieve costs from Vultr using a Telegram Bot

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published