Repository navigation
feat: add zone switch group link resource - #1
Merged
Merged
Conversation
client.zone_switch_group_links wraps the public-API /zoneSwitchGroupLinks endpoints: list, get, find, create, update (read-merge-PUT) and delete.
The controller answers two list filters with HTTP 500 ("At most 1
parameter"), so list() refuses them and find() filters by zone and matches
the switch group client-side. ADR 0009 records the live read findings.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
client.zone_switch_group_links, a wrapper for the public-API (wsg)/zoneSwitchGroupLinksendpoints, so a Switch Manager switch group can be linked to a zone.list(*, zone_id=None, switch_group_id=None, domain_id=None): every page, at most one filterget(id)find(zone_id, switch_group_id): the record orNone, whatever itslinkflagcreate(zone_id, switch_group_id, link=True): returns{id}update(id, fields): read-merge-PUT overzoneId/switchGroupId/linkdelete(id)ADR 0009, the README,
docs/and the repo memory are updated.Live findings (read-only, production controller)
zoneIdtogether withswitchGroupIdreturns HTTP 500 ("At most 1 parameter").list()raisesValueErrorbefore sending, andfind()filters by zone and matches the group client-side.switchGroupIdfilter naming an unknown group returns HTTP 500. An unknownzoneIdreturns an empty list.get()for an unknown id returnsNone.The controller held no link records, and create, update and delete were not run live.
Test plan
make tests(lint, mypy, 318 unit tests)list/find/get🤖 Generated with Claude Code