Skip to content

feat(parameters): add support for AppConfig Agent - #5399

Merged
svozza merged 20 commits into
mainfrom
feat/parameters-appconfig-agent
Jul 15, 2026
Merged

svozza merged 20 commits into
mainfrom
feat/parameters-appconfig-agent

Conversation

@svozza

@svozza svozza commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds a new getConfig function exported from @aws-lambda-powertools/parameters/appconfig-agent that retrieves configurations from the AWS AppConfig Agent Lambda extension's local HTTP endpoint. Since caching, polling, and prefetching are handled by the agent, the implementation is a lean standalone function modeled on the commons metadata module rather than the BaseProvider pattern, keeping customer bundles small.

Changes

  • Add getConfig function in packages/parameters/src/appconfig-agent/ that fetches from http://localhost:2772/applications/{app}/environments/{env}/configurations/{config} using native fetch with a configurable timeout (default 3000ms)
  • Support json and binary transforms by reusing the existing transformValue utility; no maxAge/forceFetch options since caching is handled by the agent
  • Return undefined when not running in a Lambda environment (local development/testing)
  • Respect the AWS_APPCONFIG_EXTENSION_HTTP_PORT environment variable and fall back to POWERTOOLS_SERVICE_NAME when application is not provided
  • Add ./appconfig-agent and ./appconfig-agent/types subpath exports with typed return values (string, JSONValue, or explicit generic)
  • Add unit tests (100% coverage), type tests, and an e2e test suite that deploys the agent extension layer alongside AppConfig profiles
  • Document the new function in the Parameters feature page, README, and add a doc snippet

Issue number: closes #5312


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added the size/XL PRs between 500-999 LOC, often PRs that grown with feedback label Jul 7, 2026
@svozza
svozza force-pushed the feat/parameters-appconfig-agent branch from 5d0bfe0 to ba6478b Compare July 7, 2026 12:17
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added size/XL PRs between 500-999 LOC, often PRs that grown with feedback and removed size/XL PRs between 500-999 LOC, often PRs that grown with feedback labels Jul 7, 2026
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added size/XXL PRs with 1K+ LOC, largely documentation related and removed size/XL PRs between 500-999 LOC, often PRs that grown with feedback labels Jul 7, 2026
@svozza
svozza marked this pull request as draft July 7, 2026 12:26
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added size/XXL PRs with 1K+ LOC, largely documentation related and removed size/XXL PRs with 1K+ LOC, largely documentation related labels Jul 7, 2026
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added size/XXL PRs with 1K+ LOC, largely documentation related and removed size/XXL PRs with 1K+ LOC, largely documentation related labels Jul 7, 2026
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added the size/XXL PRs with 1K+ LOC, largely documentation related label Jul 8, 2026
@svozza

svozza commented Jul 8, 2026

Copy link
Copy Markdown
Contributor Author
@dreamorosi

Copy link
Copy Markdown
Contributor

Thanks for working on this - and glad we were able to smooth out the non-Lambda experience.

@svozza

svozza commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Yeah, the non-lambda part was trickier than I expected but I think we landed on a nice solution in the end. Thank you for helping iterate on the design!

This branch was previously deployed

1 inactive deployment
e2e-tests — 657ee944 Deployed Jul 15, 2026 by svozza via run-e2e-tests-on-utils (layers, 24, x86_64) #864
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XXL PRs with 1K+ LOC, largely documentation related

2 participants