Skip to content

Add endpoint resolution context and HTTP signer/executor for hc_agent - #23

Draft
binrogithub wants to merge 1 commit into
masterfrom
codex/create-endpoints.py-for-config-merging
Draft

Add endpoint resolution context and HTTP signer/executor for hc_agent#23
binrogithub wants to merge 1 commit into
masterfrom
codex/create-endpoints.py-for-config-merging

Conversation

@binrogithub

Copy link
Copy Markdown
Owner

Motivation

  • Provide a unified endpoint resolution mechanism that merges runtime environment and config values and supports HC_AGENT_ and HC_ENDPOINT_ overrides.
  • Support table-driven service templates with sensible fallbacks and special casing for services like rds and aom, and expose the resolved endpoint to HTTP executor and signer helpers.

Description

  • Add hc_agent/core/endpoints.py which implements EndpointContext, merges config and environment (HC_AGENT_REGION, HC_AGENT_BASE, HC_AGENT_BASE_DOMAIN) and loads endpoint overrides from config (endpoints, endpoint_overrides, agent.endpoints) and environment variables prefixed with HC_ENDPOINT_.
  • Implement template-driven resolution with DEFAULT_TEMPLATES and SERVICE_TEMPLATES to map services to patterns including rds.{region}.{base} and aom.{region}.{base} with fallbacks to region-less templates.
  • Add hc_agent/core/http_executor.py and hc_agent/core/signer.py which consume the EndpointContext and resolve service hosts for HTTP requests and signing operations respectively.
  • No skills from the AGENTS.md catalog were used for this change.

Testing

  • No automated tests were run for this change.

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant