Skip to content

Examples

The Anvil examples directory contains schema v2 configurations for every built-in provider.

AWS

AWS support is included in the base install.

For dependency result sharing, recovery, and configured-target fan-in, see the AWS Config cleanup workflow.

Azure

Install the Azure SDK dependencies with pip install "anvil[azure]", or use uv sync --extra azure in an Anvil source checkout.

GCP

Install the GCP SDK dependencies with pip install "anvil[gcp]", or use uv sync --extra gcp in an Anvil source checkout.

GitHub

GitHub examples cover token auth, GitHub App auth, organization-scoped code search, repository security settings, rulesets, branch protection, and security alert listing.

Install the GitHub client dependency with pip install "anvil[github]", or use uv sync --extra github in an Anvil source checkout.

Cloudflare

Install the Cloudflare client with pip install "anvil[cloudflare]", or use uv sync --extra cloudflare in an Anvil source checkout.

Datadog

Install the Datadog client with pip install "anvil[datadog]", or use uv sync --extra datadog in an Anvil source checkout.

GitLab

Install the GitLab client with pip install "anvil[gitlab]", or use uv sync --extra gitlab in an Anvil source checkout.

PagerDuty

Install the PagerDuty client with pip install "anvil[pagerduty]", or use uv sync --extra pagerduty in an Anvil source checkout.

GitHub Actions

For AWS OIDC workflows that execute Anvil and upload generated JSON results as workflow artifacts, see the GitHub Actions examples.

Result Examples

The result examples show structured task return values and ActionRecorder usage.

Repository Template

Create a dedicated task repository with the foundry-anvil-template. It provides a project layout for custom tasks and processors, YAML examples, validation, and CI outside the main Anvil repository.

Standalone AWS Multi-Account Template

If you need a small AWS Organizations script instead of the Anvil framework, start with the standalone multi-account template.

It includes active-account discovery, include/exclude filters, parallel account execution, multiple regions, member-account role assumption, dry-run handling, and JSON output. Replace account_task() with the work for your script and adapt the example arguments as needed.