AWSLive-testedattested

API Gateway REST API (deny-by-default)

A REST API wired end to end - resource tree built from route paths, deny-by-default IAM authorization, MOCK/Lambda/HTTP integrations, deployment + stage with throttling and JSON access logs.

terraformAWSaws

Compare API Gateway across clouds →

aws-apigateway-restvizier v1.2.0

Verification

Live-tested

Really deployed to a cloud sandbox, verified against its outputs and assertions, then destroyed - with the teardown confirmed.

Conformance

  • Static validation (fmt · validate · tflint)
  • Security scan clean (Checkov)
  • Plan test superseded by live test

Provenance

Functional

  • Live-tested - applied, verified, destroyed

Last verified 2026-06-30 · how we verify

Verify this download

cosign · sha-256

Don't take our word for it. Every release is signed with cosign - check the bytes against our pinned public key before you trust them.

# 1. Our pinned public key - fetch once, trust out-of-band
curl -O https://www.iac-bazaar.com/cosign.pub

# 2. This module's Sigstore bundle
curl -o aws-apigateway-rest-1.0.0.sigstore.json \
  https://www.iac-bazaar.com/api/artifacts/aws-apigateway-rest/signature

# 3. Verify the tarball you downloaded
cosign verify-blob \
  --key cosign.pub \
  --bundle aws-apigateway-rest-1.0.0.sigstore.json \
  aws-apigateway-rest-1.0.0.tar.gz
# → Verified OK

# 4. (optional) confirm the checksum too
echo "83449a011f0de9fdb5f1a373cfa38af9320b557bf2f9ec5fde08283f2a3795d5  aws-apigateway-rest-1.0.0.tar.gz" | sha256sum -c

Use it from the registry

terraform · opentofu
module "apigateway_rest" {
  source  = "www.iac-bazaar.com/iac-bazaar/aws-apigateway-rest/aws"
  version = "1.0.0"
}

Needs a registry token from /account/tokens. The module itself is free; the account is what identifies you. Full setup: registry docs.

Cite it in your README

badge · attribution

Paste this beside the module in the repository that uses it. The badge is rendered from this artifact's verification record, so it reads live-tested because the record says so, and the link lands on this page.

README.md, GitLab, Gitea
[![IaC Bazaar: live-tested](https://www.iac-bazaar.com/api/artifacts/aws-apigateway-rest/badge)](https://www.iac-bazaar.com/catalog/aws-apigateway-rest?utm_source=syndication&utm_medium=readme&utm_campaign=artifact)

Terraform module 1.0.0, live-tested on IaC Bazaar: [API Gateway REST API (deny-by-default)](https://www.iac-bazaar.com/catalog/aws-apigateway-rest?utm_source=syndication&utm_medium=readme&utm_campaign=artifact)

```hcl
module "apigateway_rest" {
  source  = "www.iac-bazaar.com/iac-bazaar/aws-apigateway-rest/aws"
  version = "1.0.0"
}
```

Preview:IaC Bazaar: live-tested

Inputs & outputs

Create a free account to read this module's contract

The declared contract - every input name, type, default and description, plus every output - is shown to signed-in accounts, not to anonymous visitors.

A free account sees the contract of every module in the catalogue. There is no subscription and nothing to buy - the modules are free to download, and they run under Vizier.

Documentation

aws-apigateway-rest — API Gateway REST API

A REST API (API Gateway v1) wired end to end: the API, a resource tree built automatically from your route paths (nested paths and their parents included), methods with deny-by-default authorization, MOCK integrations (no backend required) or Lambda/HTTP proxies, a deployment + stage with throttling and detailed metrics, structured JSON access logs to a managed CloudWatch log group, and the account-level CloudWatch role those logs need. Works with Terraform and OpenTofu (>= 1.6), AWS provider >= 6.0, < 7.0. API Gateway is pay-per-call, and this module is VPC-free (REGIONAL/EDGE endpoints only).

Secure / sane defaults

  • Deny-by-default authorization. Routes that leave authorization unset inherit default_authorization, which is AWS_IAM — unauthenticated callers are rejected unless a route is explicitly opened with authorization = "NONE". Flip the default to NONE only for a public API.
  • Access logs on by default, streamed as a structured JSON record (request id, source IP, method, resource path, status, latency) to a module-managed CloudWatch log group with 30-day retention (KMS optional).
  • Execution logging at ERROR by default; data_trace_enabled (full request/response bodies, which can capture secrets) is off.
  • Throttling on by default (burst/rate caps in the stage method settings) so a single client cannot exhaust the account-wide soft limits.
  • No cost surprises: the API cache cluster and X-Ray tracing are off (both bill independently of request volume); cache_data_encrypted is forced on whenever a cache cluster is enabled.
  • The CloudWatch-role footgun is handled. REST API logging requires a region-wide account CloudWatch role; the module creates and registers it for you (create_cloudwatch_role, default true) and a stage precondition fails fast if logging is requested with no role available.

Requirements

  • Terraform or OpenTofu >= 1.6
  • hashicorp/aws >= 6.0, < 7.0

License

Commercial — LicenseRef-IaCBazaar-Commercial. © IaC Bazaar. Original work (not derived from a third-party module).

Usage code & full reference need an account

The complete copy-paste usage, the full input/output reference, and operational notes are free with an account - shown here and bundled in the download. Sign in and this section fills in.

  • Usage
  • Inputs (key)
  • Outputs
  • Notes
  • Live test (`tests/`)

Related modules

Static validatedLive test pending

aws-appsync

introspection_config defaults to ENABLED, handing any caller a complete map of every type, field and argument, and query_depth_limit defaults to 0, which means no limit - so one nested query multiplies into thousands of resolver calls. Both closed here, with request bodies kept out of CloudWatch and a WAF association for the rate nothing else bounds.

View module
Live-tested

aws-apigateway-http

HTTP API with routes, Lambda/ALB integrations, custom domain, JWT authorizers, and access logs.

View module
Static validatedLive test pending

tencent-api-gateway

An API Gateway service with net_type INNER rather than OUTER, https rather than the http that stays plaintext to the gateway, and QPS ceilings required - without a limit one caller can spend the whole backend's capacity. auth_type NONE and CORS are both named per API, since either turns an endpoint into an open one.

View module
Static validatedLive test pending

oci-api-gateway

Managed API gateway with route deployments, JWT/auth policies, rate limiting, CORS and custom-domain TLS.

View module
Live-tested

gcp-api-gateway

A serverless API Gateway fronting an OpenAPI 2.0 spec - API, immutable config and managed gateway - with a dedicated least-privilege backend service account and a built-in default spec.

View module
Live-tested

azure-api-management

An API Management gateway tuned for the serverless Consumption tier - scale-to-zero, billed per call - with a system-assigned managed identity, TLS hardening, and HTTP/2 enabled.

View module