API Links parameters vs Swagger parameters

Octopus Self hosted on Windows server [2022.3 (Build 10936)]

This is only a ‘huh, that is interesting’ fyi. I’m working with the API and I noticed a difference in what the API returns in the ‘Links’ vs what Swagger returns. When calling the ‘/api’ directly I get the following in the WorkerPools link property:

“/api/Spaces-1/workerpools{/id}{?name,skip,ids,take,partialName}”

Swagger shows various endpoints (both with and without {baseSpaceId} and {id}) that include the skip, ids, take and partialName. But Swagger does not show any endpoint with the ‘name’ parameter.

Also, if I attempt to send a request with the name parameter (example attached), I get a result of all the worker pools, as if I had not supplied any query parameters. That leads me to conclude the ‘name’ parameter is not used, but is still being returned as a possible parameter in the API calls.

Not sure if this is something to cleanup in the API response or if I’m simply doing something very wrong in my API call. I’m using the ‘partialName’ parameter with great success though, so it’s not a blocking issue. Simply wanted to let someone know about the oddity.

Hey David,

Thanks for passing this along. I’m going to forward this to the team responsible for SwaggerUI and have them take a look. Please let us know if there’s anything else we should know about it or if you have any other questions.

Best,
Jeremy

Hey David,

The developers had a chat about this and opened this issue you can follow: Worker pools route advertises name parameter, but doesn't honor it · Issue #7979 · OctopusDeploy/Issues · GitHub

Please let me know if you have any questions or concerns. If not, I hope you have a great rest of your week!

Best,
Jeremy

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.