chore: promote develop to main - #125
Merged
Merged
Conversation
…API areas Adds Get/New/Update/Remove-PiHoleClient and Get-PiHoleClientSuggestion, covering Pi-hole's client management API (GET/POST/PUT + batch-delete, plus unconfigured-client suggestions). Single-item DELETE is intentionally skipped in favor of the batch endpoint, same precedent as Remove-PiHoleList/Remove-PiHoleDomain. Adds Get-PiHoleNetworkGateway/Route/Interface/Device and Remove-PiHoleNetworkDevice, covering the full Network Information API. Unlike Clients/Domains/Lists there's no batch-delete alternative for devices, so Remove-PiHoleNetworkDevice implements the single-item DELETE directly. Interface/route/gateway responses vary significantly by type and aren't fully enumerable from the spec, so they're returned via the existing generic PascalCase-conversion helper (already used by Get-PiHoleConfig) rather than a hand-picked set of fields - confirmed against the real server that this also correctly surfaces at least one live field not documented in the OpenAPI spec (interface stats.bits). Adds Client Management as its own README/EXAMPLES category; Network Information folds into "Configuration & Diagnostics" like the other read-only diagnostic areas (FTLInformation, Padd, Teleporter, History). Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…area
Extends Get-PiHoleConfig with -Element (request one subset of the
config tree, e.g. "dns/upstreams") and -Detailed. Adds Set-PiHoleConfig
(PATCH /config), Add/Remove-PiHoleConfigArrayItem (PUT/DELETE
/config/{element}/{value}, for array-type settings like dns/hosts and
dns/cnameRecords), and Get-PiHoleConfigProperty (the list of settings
that can never be changed via the API).
All three write functions require the app password's "app_sudo" flag
to be enabled in Pi-hole (Settings > All Settings) - Pi-hole blocks
config changes from app passwords by default, and there's no way to
enable it via the API itself (avoiding that would defeat the point).
Verified against a real server with app_sudo both disabled and
enabled: a real config value can be changed and reverted, an
array item can be added and removed, and a genuinely read-only
property (misc.readOnly) is correctly rejected.
Adds ConvertTo-PiHoleFriendlyErrorMessage (Private/Misc.ps1), used by
the three write functions' error handling: Pi-hole's own error
responses carry a clearer message/hint than the generic HTTP exception
text, and for the app_sudo case specifically, a concrete pointer to
where to enable it - previously the module surfaced only "403
(Forbidden)" or "400 (Bad Request)" with no explanation.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
feat: add Client Management and Network Information, completing both API areas
…agement # Conflicts: # README.md # docs/EXAMPLES.md
Resolves the README.md/docs/EXAMPLES.md conflicts from merging develop (which now includes PR #122's Client Management and Network Information) by regenerating both from the merged source instead of hand-resolving generated-file diffs. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
feat: add Config write/property functions, completing the Config API area
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
Get/New/Update/Remove-PiHoleClient,Get-PiHoleClientSuggestion,Get-PiHoleNetworkGateway/Route/Interface/Device,Remove-PiHoleNetworkDevice) intomain.Get-PiHoleConfig,Set-PiHoleConfig,Add/Remove-PiHoleConfigArrayItem,Get-PiHoleConfigProperty) intomain.Test plan
develop.🤖 Generated with Claude Code