[BUG]: Pi-Hole API has changed
Opened this issue · 1 comments
Describe the bug
Pi-Hole changed the API
Please see https://pi-hole.net/blog/2022/11/17/upcoming-changes-authentication-for-more-api-endpoints-required/#page-content
To Reproduce
Steps to reproduce the behavior:
- Use example flow
- Update the API key and user name credentials
- ECONNREFUSED is returned, like this;
3/31/2023, 11:37:05 AM[node: 7c83bfa0.af8d9](http://rp3plus:1880/#)
msg.payload : Object
{ status: "offline", error_code: "ECONNREFUSED", name: "admin", pihole: "admin" }
Test to demonstrate Pi-Hole is up and running
- Use a suitable text editor to create the URL as specified in the pi-hole notice
- Paste URL http://pi.hole/admin/api.php?status&auth=[your key] into browser
- Get {"status":"enabled"} back from pi-hole
Expected behavior
I expect to get the "status" back from Pi-Hole when using the example flow provided.
Hey @hrafnkel,
I've completely overseen this issue... sorry for that...
As you can see here: https://github.com/naimo84/pi-hole-remote/blob/main/src/piHoleRemoteApi.ts#L52
Every call I'm sending to pihole contains an authkey. So the problem might be somewhere else?
What do you mean by 1. Use example flow
? Unfortunately I don't have an example yet 😉 I can't remember, or I'm unable to find it ^^