{"id":36688406,"url":"https://github.com/converged-computing/check-aws-costs","last_synced_at":"2026-01-12T11:17:02.141Z","repository":{"id":194165062,"uuid":"690203519","full_name":"converged-computing/check-aws-costs","owner":"converged-computing","description":"Simple script to generate single interface of daily costs for inspection","archived":false,"fork":false,"pushed_at":"2023-09-11T22:33:42.000Z","size":11,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-10T05:37:02.436Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/converged-computing.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-09-11T18:26:49.000Z","updated_at":"2023-09-12T12:31:12.000Z","dependencies_parsed_at":"2023-09-12T05:10:19.391Z","dependency_job_id":null,"html_url":"https://github.com/converged-computing/check-aws-costs","commit_stats":null,"previous_names":["converged-computing/check-aws-costs"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/converged-computing/check-aws-costs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/converged-computing%2Fcheck-aws-costs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/converged-computing%2Fcheck-aws-costs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/converged-computing%2Fcheck-aws-costs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/converged-computing%2Fcheck-aws-costs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/converged-computing","download_url":"https://codeload.github.com/converged-computing/check-aws-costs/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/converged-computing%2Fcheck-aws-costs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28338970,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T10:58:46.209Z","status":"ssl_error","status_checked_at":"2026-01-12T10:58:42.742Z","response_time":98,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-12T11:17:01.261Z","updated_at":"2026-01-12T11:17:02.117Z","avatar_url":"https://github.com/converged-computing.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AWS Cost Check\n\nWe need an automated means to check for cases that can lead to bad times with billing.\n\n- Instances left on (and forgotten)\n- Storage / Volumes attached to off-instances\n\nLikely the way we monitor these will depend on the project. For example, a project that regularly runs long analyses would not want an alert for an instance up a day. Much of the analysis would come down to looking for either patterns or outliers. Since outliers require some kind of model and historical data, I'm going to (at first) go for more of a logical approach - identifying the patterns to be concerned about, and then assessing:\n\n- total lump sums of things\n- big rates of change between timepoints\n- going above some threshold\n\nI want to start by reading about some of these patterns and taking notes, and asking:\n\n1. What is the pattern?\n2. What are we looking for?\n\nA third idea I'm also thinking is that it might be easy enough to just plot everything we have, over time, and send an email (or similar) to a human to look at it. I might just start with this because it's simple and easy.\n\n## Usage\n\n```bash\npip install -r requirements.txt\n\n# See what you can customize\npython check-aws-costs.py --help\n\n# Run the default, looking at DAILY (granularity) AmortizedCost (metric) SERVICE (dimension) for 90 days over 4 regions (us-east-1/2 and us-west-1/2).\npython check-aws-costs.py\n```\n```console\nQuerying for daily cost by service for us-east-1\nQuerying for daily cost by service for us-east-2\nQuerying for daily cost by service for us-west-1\nQuerying for daily cost by service for us-west-2\nSaving raw results to cache/spending-2023-09-11.json\nSaving raw results to cache/spending-latest.json\nAdding us-east-1 to the data frame...\nAdding us-east-2 to the data frame...\nAdding us-west-1 to the data frame...\nAdding us-west-2 to the data frame...\nSaving formatted results to cache/spending-2023-09-11.csv\nSaving formatted results to cache/spending-latest.csv\n```\n\nThis generates the files mentioned above.\nNote that we save based on the day, but also \"latest\" to make it easy to find the latest\nto plot. Hey, if \"latest\" works poorly for container tags it can work here too! How to plot?\n\n```bash\npython plot-aws-costs.py\n```\n\nThis will generate a pdf in your present working directory. We don't generate plots if the total is under $5. \n\n```console\nSkipping amazon-simple-notification-service, total across regions is \u003c $5\nSkipping amazon-simple-queue-service, total across regions is \u003c $5\nSkipping amazon-simple-storage-service, total across regions is \u003c $5\nSkipping amazoncloudwatch, total across regions is \u003c $5\nSkipping amazon-elastic-container-service-for-kubernetes, total across regions is \u003c $5\nSkipping amazon-ec2-container-registry-(ecr), total across regions is \u003c $5\nSkipping amazon-route-53, total across regions is \u003c $5\nSkipping amazon-virtual-private-cloud, total across regions is \u003c $5\nSkipping aws-systems-manager, total across regions is \u003c $5\nSkipping amazon-elastic-container-registry-public, total across regions is \u003c $5\nSkipping aws-lambda, total across regions is \u003c $5\nSkipping tax, total across regions is \u003c $5\nSkipping aws-cost-explorer, total across regions is \u003c $5\n```\n\nThe data is fairly generic and we could have other output types/formats too.\n\n## References\n\n - [AWS Cost-Saving Gotchas](https://medium.com/@matt_weingarten/aws-cost-saving-gotchas-f0f883c34c69)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fconverged-computing%2Fcheck-aws-costs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fconverged-computing%2Fcheck-aws-costs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fconverged-computing%2Fcheck-aws-costs/lists"}