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.

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.

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.