Skip to content

fix(http,baremetal): route legacy /v1 paths under /1.0 on non-official endpoints - #282

Open
JayBeeDe wants to merge 1 commit into
mainfrom
fix/281
Open

fix(http,baremetal): route legacy /v1 paths under /1.0 on non-official endpoints#282
JayBeeDe wants to merge 1 commit into
mainfrom
fix/281

Conversation

@JayBeeDe

@JayBeeDe JayBeeDe commented Sep 7, 2026

Copy link
Copy Markdown
Member

Description

fix(http): route legacy /v1 paths under /1.0 on non-official endpoints

go-ovh aliases "/v1/"-prefixed paths to the endpoint's bare domain root instead of appending them under its "/1.0" base — a trick that only works on the official ovh-eu/ovh-ca/ovh-us gateways. On every other endpoint (Kimsufi, SoYouStart, custom URLs), that alias 404s since those hosts only serve the API under "/1.0".

Wrap the go-ovh client so Get/Post/Put/Delete/NewRequest strip the leading "/v1" segment before the request is built and signed whenever the active endpoint isn't one of the 3 official ones, letting the path append under the endpoint's own "/1.0" base instead.

Adjust the scope/subject if you'd rather tie it to the symptom (e.g. fix(baremetal): fix Kimsufi/SoYouStart 404s on dedicated server calls), but since the fix lives entirely in internal/http/client.go and applies to every affected product (not just baremetal), fix(http) is more accurate.

Fixes #281

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • My code follows the style guidelines of this project
  • I have commented my code
  • I ran go mod tidy
  • I have added tests that prove my fix is effective or that my feature works

@JayBeeDe
JayBeeDe requested a review from a team as a code owner September 7, 2026 13:45
…l endpoints

Signed-off-by: Jean-Baptiste Delon <jean-baptiste.delon@ovhcloud.com>
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.

[Bug]: Kimsufi / SoYouStart API calls return 404 due to go-ovh's /v1 root-aliasing

1 participant