{"id":46337163,"url":"https://github.com/squareops/terraform-aws-billing-notifications","last_synced_at":"2026-03-04T19:05:15.596Z","repository":{"id":264183151,"uuid":"642395479","full_name":"squareops/terraform-aws-billing-notifications","owner":"squareops","description":"Terraform module to deploy an AWS budget forecast, automatically sending notifications when usage exceeds specified budget limits, ensuring proactive cost management and alerts.","archived":false,"fork":false,"pushed_at":"2024-11-22T13:07:01.000Z","size":33,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2024-11-22T14:19:54.305Z","etag":null,"topics":["aws","billing-notifier","lambda-functions"],"latest_commit_sha":null,"homepage":"https://squareops.com","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/squareops.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-18T13:23:50.000Z","updated_at":"2024-11-22T13:06:38.000Z","dependencies_parsed_at":"2024-11-22T21:20:36.399Z","dependency_job_id":null,"html_url":"https://github.com/squareops/terraform-aws-billing-notifications","commit_stats":null,"previous_names":["squareops/terraform-aws-billing-notifications"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/squareops/terraform-aws-billing-notifications","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squareops%2Fterraform-aws-billing-notifications","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squareops%2Fterraform-aws-billing-notifications/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squareops%2Fterraform-aws-billing-notifications/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squareops%2Fterraform-aws-billing-notifications/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/squareops","download_url":"https://codeload.github.com/squareops/terraform-aws-billing-notifications/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/squareops%2Fterraform-aws-billing-notifications/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29388120,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-13T00:02:39.825Z","status":"ssl_error","status_checked_at":"2026-02-13T00:00:20.807Z","response_time":55,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6: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":["aws","billing-notifier","lambda-functions"],"created_at":"2026-03-04T19:05:14.929Z","updated_at":"2026-03-04T19:05:15.583Z","avatar_url":"https://github.com/squareops.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# terraform-aws-billing\n\n# AWS Budget Forecast Notification\n\nConfiguration in this directory creates set of AWS resources which may be sufficient for a fully working stage or prod\nTerraform module - creates an AWS Budget with notification via SNS enabled/Email enabled with optional sns topic\ncreation (or use a pre-existing one) to alert when a U$S (currency actually configurable) budget forecasted threshold % is reached\n(currently 100% of the `limit_amount`).\n\nProvides an AWS budget resource (`aws_budgets_budget`). Budgets use the cost visualisation provided by **Cost Explorer** to show\nyou the status of your budgets, to provide forecasts of your estimated costs, and to track your AWS usage, including your free tier usage.\n\nPlease check the **input parameters** for a better understanding of it.\n\n## Usage Example\n```hcl\nmodule \"aws_budget_alert\" {\n  source            = \"squareops/billing-notifications/aws\"\n  version           = \"1.0.1\"\n  name              = local.name\n  environment       = local.environment\n  account_id        = local.account_id\n  budget_type       = \"COST\"\n  limit_amount      = \"10\"\n  limit_unit        = \"USD\"\n  time_period_start = \"2023-11-16_00:00\"\n  time_unit         = \"DAILY\"\n  notification = {\n    comparison_operator = \"GREATER_THAN\"\n    threshold           = 100\n    threshold_type      = \"PERCENTAGE\"\n    notification_type   = \"ACTUAL\"\n  }\n  cost_types = {\n    include_credit             = false\n    include_discount           = true\n    include_other_subscription = true\n    include_recurring          = true\n    include_refund             = false\n    include_subscription       = true\n    include_support            = true\n    include_tax                = true\n    include_upfront            = true\n    use_blended                = false\n  }\n  slack_notification_enabled = true\n  slack_channel_id           = \"XXXXXZZZZ\"\n  slack_workspace_id         = \"ABCDUTSSZ\"\n  email_notification_enabled = true\n  email_address              = \"notification.com\"\n}\n\n```\n## Usage\n\nTo run this example you need to execute:\n\n```bash\n$ terraform init\n$ terraform plan\n$ terraform apply\n```\n\nOr if using the `Makefile` in this repo you need to execute:\n\n```bash\n$ make init\n$ make plan\n$ make apply\n```\n\nNote that this example may create resources which can cost money (AWS EC2, for example). Run `terraform destroy` or `make destroy`\nwhen you don't need these resources.\n\n\u003c!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK --\u003e\n## Requirements\n\nNo requirements.\n\n## Providers\n\n| Name | Version |\n|------|---------|\n| \u003ca name=\"provider_aws\"\u003e\u003c/a\u003e [aws](#provider\\_aws) | n/a |\n| \u003ca name=\"provider_awscc\"\u003e\u003c/a\u003e [awscc](#provider\\_awscc) | n/a |\n\n## Modules\n\nNo modules.\n\n## Resources\n\n| Name | Type |\n|------|------|\n| [aws_budgets_budget.aws_budget_report](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/budgets_budget) | resource |\n| [aws_iam_policy.chatbot_role_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_policy) | resource |\n| [aws_iam_role.chatbot_role](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role) | resource |\n| [aws_iam_role_policy_attachment.chatbot_policy_attach](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy_attachment) | resource |\n| [aws_sns_topic.aws_budget_alerts](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/sns_topic) | resource |\n| [aws_sns_topic_policy.sns_topic_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/sns_topic_policy) | resource |\n| [aws_sns_topic_subscription.aws_budget_alerts_target](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/sns_topic_subscription) | resource |\n| [awscc_chatbot_slack_channel_configuration.aws_budget_alerts_slack](https://registry.terraform.io/providers/hashicorp/awscc/latest/docs/resources/chatbot_slack_channel_configuration) | resource |\n| [aws_iam_policy_document.aws_budgets_assume_role_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |\n| [aws_iam_policy_document.chatbot_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |\n| [aws_iam_policy_document.sns_topic_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |\n\n## Inputs\n\n| Name | Description | Type | Default | Required |\n|------|-------------|------|---------|:--------:|\n| \u003ca name=\"input_slack_notification_enabled\"\u003e\u003c/a\u003e [slack\\_notification\\_enabled](#input\\_slack\\_notification\\_enabled) | Flag to enable or disable Slack notifications. | `bool` | `false` | no |\n| \u003ca name=\"input_slack_channel_id\"\u003e\u003c/a\u003e [slack\\_channel\\_id](#input\\_slack\\_channel\\_id) | The ID of the Slack channel for notifications. | `string` | `\"\"` | no |\n| \u003ca name=\"input_slack_workspace_id\"\u003e\u003c/a\u003e [slack\\_workspace\\_id](#input\\_slack\\_workspace\\_id) | The ID of the Slack workspace for notifications. | `string` | `\"\"` | no |\n| \u003ca name=\"input_notification\"\u003e\u003c/a\u003e [notification](#input\\_notification) | Configuration for budget notifications. | \u003cpre\u003eobject({\u003cbr\u003e    comparison_operator = optional(string, \"GREATER_THAN\") # LESS_THAN, EQUAL_TO or GREATER_THAN\u003cbr\u003e    threshold           = number\u003cbr\u003e    threshold_type      = string                     # PERCENTAGE or ABSOLUTE_VALUE\u003cbr\u003e    notification_type   = optional(string, \"ACTUAL\") # ACTUAL or FORECASTED\u003cbr\u003e  })\u003c/pre\u003e | n/a | yes |\n| \u003ca name=\"input_cost_types\"\u003e\u003c/a\u003e [cost\\_types](#input\\_cost\\_types) | Configuration for included cost types in the budget. | `any` | \u003cpre\u003e{\u003cbr\u003e  \"include_credit\": false,\u003cbr\u003e  \"include_discount\": true,\u003cbr\u003e  \"include_other_subscription\": true,\u003cbr\u003e  \"include_recurring\": true,\u003cbr\u003e  \"include_refund\": false,\u003cbr\u003e  \"include_subscription\": true,\u003cbr\u003e  \"include_support\": true,\u003cbr\u003e  \"include_tax\": true,\u003cbr\u003e  \"include_upfront\": true,\u003cbr\u003e  \"use_blended\": false\u003cbr\u003e}\u003c/pre\u003e | no |\n| \u003ca name=\"input_time_period_start\"\u003e\u003c/a\u003e [time\\_period\\_start](#input\\_time\\_period\\_start) | The start date of the budget time period(e.g., 2017-01-01\\_12:00). | `string` | `\"\"` | no |\n| \u003ca name=\"input_time_period_end\"\u003e\u003c/a\u003e [time\\_period\\_end](#input\\_time\\_period\\_end) | The start date of the budget time period(e.g., 2017-01-01\\_12:00). | `string` | `\"\"` | no |\n| \u003ca name=\"input_time_unit\"\u003e\u003c/a\u003e [time\\_unit](#input\\_time\\_unit) | The unit of time for the budget (e.g., MONTHLY, QUARTERLY, ANNUALLY and DAILY). | `string` | `\"\"` | no |\n| \u003ca name=\"input_name\"\u003e\u003c/a\u003e [name](#input\\_name) | A unique name for the budget configuration. | `string` | `\"\"` | no |\n| \u003ca name=\"input_environment\"\u003e\u003c/a\u003e [environment](#input\\_environment) | The environment for which the budget is configured. | `string` | `\"\"` | no |\n| \u003ca name=\"input_account_id\"\u003e\u003c/a\u003e [account\\_id](#input\\_account\\_id) | The AWS account ID for which the budget is created. | `string` | `\"\"` | no |\n| \u003ca name=\"input_budget_type\"\u003e\u003c/a\u003e [budget\\_type](#input\\_budget\\_type) | The type of budget (e.g., COST, USAGE) for monitoring. | `string` | `\"\"` | no |\n| \u003ca name=\"input_limit_amount\"\u003e\u003c/a\u003e [limit\\_amount](#input\\_limit\\_amount) | The budgeted amount for the specified time period. | `number` | n/a | yes |\n| \u003ca name=\"input_limit_unit\"\u003e\u003c/a\u003e [limit\\_unit](#input\\_limit\\_unit) | The unit of measurement for the budgeted amount(e.g,, USD, GB). | `string` | `\"\"` | no |\n| \u003ca name=\"input_email_notification_enabled\"\u003e\u003c/a\u003e [email\\_notification\\_enabled](#input\\_email\\_notification\\_enabled) | Flag to enable or disable Slack notifications. | `bool` | `false` | no |\n| \u003ca name=\"input_email_address\"\u003e\u003c/a\u003e [email\\_address](#input\\_email\\_address) | n/a | `string` | `\"\"` | no |\n\n## Outputs\n\n| Name | Description |\n|------|-------------|\n| \u003ca name=\"output_sns_topic_arn\"\u003e\u003c/a\u003e [sns\\_topic\\_arn](#output\\_sns\\_topic\\_arn) | The Amazon Resource Name (ARN) of the created AWS SNS topic for budget alerts. |\n| \u003ca name=\"output_budget_report_id\"\u003e\u003c/a\u003e [budget\\_report\\_id](#output\\_budget\\_report\\_id) | The ID of the AWS Budgets budget report created for monitoring costs. |\n| \u003ca name=\"output_chatbot_role_arn\"\u003e\u003c/a\u003e [chatbot\\_role\\_arn](#output\\_chatbot\\_role\\_arn) | The ARN of the AWS IAM role created for the chatbot to assume. |\n\u003c!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK --\u003e\n\n## Contribution \u0026 Issue Reporting\n\nTo report an issue with a project:\n\n  1. Check the repository's [issue tracker](https://github.com/sq-ia/terraform-aws-billing/issues) on GitHub\n  2. Search to see if the issue has already been reported\n  3. If you can't find an answer to your question in the documentation or issue tracker, you can ask a question by creating a new issue. Be sure to provide enough context and details so others can understand your problem.\n\n## License\n\nApache License, Version 2.0, January 2004 (http://www.apache.org/licenses/).\n\n## Support Us\n\nTo support a GitHub project by liking it, you can follow these steps:\n\n  1. Visit the repository: Navigate to the [GitHub repository](https://github.com/sq-ia/terraform-aws-billing).\n\n  2. Click the \"Star\" button: On the repository page, you'll see a \"Star\" button in the upper right corner. Clicking on it will star the repository, indicating your support for the project.\n\n  3. Optionally, you can also leave a comment on the repository or open an issue to give feedback or suggest changes.\n\nStarring a repository on GitHub is a simple way to show your support and appreciation for the project. It also helps to increase the visibility of the project and make it more discoverable to others.\n\n## Who we are\n\nWe believe that the key to success in the digital age is the ability to deliver value quickly and reliably. That’s why we offer a comprehensive range of DevOps \u0026 Cloud services designed to help your organization optimize its systems \u0026 Processes for speed and agility.\n\n  1. We are an AWS Advanced consulting partner which reflects our deep expertise in AWS Cloud and helping 100+ clients over the last 4 years.\n  2. Expertise in Kubernetes and overall container solution helps companies expedite their journey by 10X.\n  3. Infrastructure Automation is a key component to the success of our Clients and our Expertise helps deliver the same in the shortest time.\n  4. DevSecOps as a service to implement security within the overall DevOps process and helping companies deploy securely and at speed.\n  5. Platform engineering which supports scalable,Cost efficient infrastructure that supports rapid development, testing, and deployment.\n  6. 24*7 SRE service to help you Monitor the state of your infrastructure and eradicate any issue within the SLA.\n\nWe provide [support](https://squareops.com/contact-us/) on all of our projects, no matter how small or large they may be.\n\nTo find more information about our company, visit [squareops.com](https://squareops.com/), follow us on [Linkedin](https://www.linkedin.com/company/squareops-technologies-pvt-ltd/), or fill out a [job application](https://squareops.com/careers/). If you have any questions or would like assistance with your cloud strategy and implementation, please don't hesitate to [contact us](https://squareops.com/contact-us/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsquareops%2Fterraform-aws-billing-notifications","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsquareops%2Fterraform-aws-billing-notifications","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsquareops%2Fterraform-aws-billing-notifications/lists"}