netlify / netlify/open-api

Duplicate base path /api/v1 for getSiteEnvVars

Open Beginner friendly
#579 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
323
Forks
133
Avg merge
2d 8h
Merged PRs (30d)
2

Description

The documentation of getSiteEnvVars shows the full URL as https://api.netlify.com/api/v1/api/v1/sites/{site_id}/env, i.e. duplicate base path /api/v1.

I assume this is just wrong and should be fixed. (It works for me without the duplicate.)

See also:
basePath (-> /api/v1): https://github.com/netlify/open-api/blob/d582bdbbc73abbe8bdaf5411a35f9b11282009fa/swagger.yml#L52
getSiteEnvVars (with /api/v1): https://github.com/netlify/open-api/blob/d582bdbbc73abbe8bdaf5411a35f9b11282009fa/swagger.yml#L332
vs e.g. getEnvVars (without /api/v1): https://github.com/netlify/open-api/blob/d582bdbbc73abbe8bdaf5411a35f9b11282009fa/swagger.yml#L221

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in swagger.yml at the basePath near line 52 and the getSiteEnvVars definition near line 332, then compare it with getEnvVars near line 221. Verify the generated endpoint URL no longer repeats /api/v1, and confirm the OpenAPI specification remains valid.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi, yaml
Domain
api
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.