Adyen / Adyen/adyen-java-api-library
Support for dynamic baseURL or liveEndpointUrlPrefix configuration in API clients
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 148
- Forks
- 158
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 10
Description
Hi Team,
Currently, the PaymentsApi and similar classes in the Adyen Java API client module (checkout) require the baseURL or liveEndpointUrlPrefix to be defined at construction time. Once the API instance is created, there appears to be no supported way to override or change this value dynamically at runtime.
This becomes limiting in scenarios where different request contexts may require different endpoint routing, such as switching between regional prefixes or environments.
I would like to know the design reasoning such that introducing 'dynamic' behaviour here can go wrong. That brings me to my next query on the possibility to consider an enhancement that allows setting or overriding the base URL dynamically per request — or at least decouple it from being hardcoded in the constructor? Even exposing a method to set the liveEndpointUrlPrefix or baseURL after construction would help in advanced routing scenarios.
Thanks for your consideration!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with src/main/java/com/adyen/service/checkout/PaymentsApi.java at the referenced constructor and compare how similar API client classes define baseURL or liveEndpointUrlPrefix. Clarify whether routing should be configurable per request or after construction, then agree on the API shape and verification needed before implementation; the issue provides no named tests or accepted behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100