Skip to content

feat(environments): read DevX Core URL from config (DEVX-793) - #190

Open
smukherjee-godaddy wants to merge 1 commit into
godaddy:mainfrom
smukherjee-godaddy:DEVX-793-devx-core-url
Open

feat(environments): read DevX Core URL from config (DEVX-793)#190
smukherjee-godaddy wants to merge 1 commit into
godaddy:mainfrom
smukherjee-godaddy:DEVX-793-devx-core-url

Conversation

@smukherjee-godaddy

Copy link
Copy Markdown
Contributor

Summary

  • read devx_core_url from each active environments.toml entry
  • preserve <ENV>_DEVX_CORE_URL and DEVX_CORE_URL as higher-precedence runtime overrides
  • retain built-in DevX Core URLs for prod and ote, and cover file configuration, precedence, and invalid URLs

Example

[dev]
api_url = "https://api.dev-godaddy.com"
client_id = "..."
devx_core_url = "https://api.developer.commerce.dev-godaddy.com"

Validation

  • cargo check
  • cargo clippy -- -D warnings
  • cargo test (552 passed)
  • cargo fmt --check

https://godaddy-corp.atlassian.net/browse/DEVX-793

derive_account_url(sources.env_name().unwrap_or_default())
}

fn default_devx_core_url(sources: &SourceChain<'_>) -> String {

@jpage-godaddy jpage-godaddy Aug 7, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It'd be simpler if you added the config value to BUILTIN_ENVS and extended BaseEnvConfig; then you don't need a separate environment-to-values lookup table or this function. The default function is mainly for if you needed to compute a default; for pre-populating built-in environments, we already have a mechanism for that.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants