To post cost estimates to Slack:
- Create a Slack Webhook in your workspace.
- Use the
infracost output --format slack-messagecommand to produce a Slack-flavored Markdown message. Slack message blocks have a 3000 char limit so the Infracost CLI automatically truncates the middle of the
slack-messageoutput format if required.
- Post the message to Slack using
curlfrom your CI/CD system. See this example for how to do this in GitLab, the same bash commands can be used in other systems.
If you run into any issues, please join our community Slack channel, we'll help you very quickly 😄