[PR #361] [MERGED] feat(provider): add netcup #678

Closed
opened 2025-11-20 04:25:40 -05:00 by saavagebueno · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/qdm12/ddns-updater/pull/361
Author: @Azorimor
Created: 9/7/2022
Status: Merged
Merged: 6/14/2023
Merged by: @qdm12

Base: masterHead: provider-netcup


📝 Commits (10+)

📊 Changes

12 files changed (+431 additions, -0 deletions)

View changed files

📝 README.md (+2 -0)
docs/netcup.md (+32 -0)
📝 internal/settings/constants/providers.go (+1 -0)
📝 internal/settings/errors/intermediary.go (+1 -0)
📝 internal/settings/errors/validation.go (+1 -0)
internal/settings/providers/netcup/info.go (+35 -0)
internal/settings/providers/netcup/json.go (+72 -0)
internal/settings/providers/netcup/login.go (+49 -0)
internal/settings/providers/netcup/models.go (+14 -0)
internal/settings/providers/netcup/provider.go (+151 -0)
internal/settings/providers/netcup/update.go (+70 -0)
📝 internal/settings/settings.go (+3 -0)

📄 Description

This PR adds basic support to use Netcup as provider (#282). The implementation only updates the IP of the given host. Additional settings (TTL, Retry, Refresh, ...) can be set manually in the netcup customercontrolpanel / dashboard.

All requests to the netcup api are send to the same endpoint. The different functions are defined by the body of the request. For example the following requests (and more) are necessary. (see doc) The requests are implemented in netcup/client.go.

Login (Create Session on server, which is valid for 15 minutes (logout not implemented, because 15 min as default seems ok))
body:

"action": "login",
"param": {
  "customernumber": "111",
  "apikey": "xxxxx",
  "apipassword": "yyyy"
}

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/qdm12/ddns-updater/pull/361 **Author:** [@Azorimor](https://github.com/Azorimor) **Created:** 9/7/2022 **Status:** ✅ Merged **Merged:** 6/14/2023 **Merged by:** [@qdm12](https://github.com/qdm12) **Base:** `master` ← **Head:** `provider-netcup` --- ### 📝 Commits (10+) - [`ac08f73`](https://github.com/qdm12/ddns-updater/commit/ac08f73f2f0066840a0cc6f449fa8d30479aa684) Started working on netcup provider - [`2a5cf9a`](https://github.com/qdm12/ddns-updater/commit/2a5cf9a777d5e585e66066c00011e9d84a5acb8c) Fully functional netcup provider - [`7888fb7`](https://github.com/qdm12/ddns-updater/commit/7888fb7868153233d12675980f959a65cb85c0c5) Some cleanup - [`64f80ec`](https://github.com/qdm12/ddns-updater/commit/64f80ec81b5457aac171ad6ad25cfa1f80a1fce0) update naming convention to use Provider - [`27efb62`](https://github.com/qdm12/ddns-updater/commit/27efb6277c908f5875a1660b7bd98d316f35b3ca) Apply linting - [`6fbf5ed`](https://github.com/qdm12/ddns-updater/commit/6fbf5ed6bd7e3448c57554140e3aec2a3e585f55) update netcup docs - [`e5ea43e`](https://github.com/qdm12/ddns-updater/commit/e5ea43e89544742aed939fb6b444f4c7631489fe) removed unused logout (auto logout after 15 minutes) - [`b2e0378`](https://github.com/qdm12/ddns-updater/commit/b2e037849110c0a41478d3d7535550f6678cb8fb) removed resolved TODO - [`2c07aff`](https://github.com/qdm12/ddns-updater/commit/2c07affc091ad939c6d6fd231ea690335c2e28f6) Apply PR feedback - [`80f1d63`](https://github.com/qdm12/ddns-updater/commit/80f1d63e36b8d03b3cb6e4f679e4402df5501021) Fix login ### 📊 Changes **12 files changed** (+431 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+2 -0) ➕ `docs/netcup.md` (+32 -0) 📝 `internal/settings/constants/providers.go` (+1 -0) 📝 `internal/settings/errors/intermediary.go` (+1 -0) 📝 `internal/settings/errors/validation.go` (+1 -0) ➕ `internal/settings/providers/netcup/info.go` (+35 -0) ➕ `internal/settings/providers/netcup/json.go` (+72 -0) ➕ `internal/settings/providers/netcup/login.go` (+49 -0) ➕ `internal/settings/providers/netcup/models.go` (+14 -0) ➕ `internal/settings/providers/netcup/provider.go` (+151 -0) ➕ `internal/settings/providers/netcup/update.go` (+70 -0) 📝 `internal/settings/settings.go` (+3 -0) </details> ### 📄 Description This PR adds basic support to use [Netcup](https://netcup.eu) as provider (#282). The implementation only updates the IP of the given host. Additional settings (TTL, Retry, Refresh, ...) can be set manually in the netcup customercontrolpanel / dashboard. All requests to the netcup api are send to the same endpoint. The different functions are defined by the body of the request. For example the following requests (and more) are necessary. (see [doc](https://www.netcup-wiki.de/wiki/DNS_API)) The requests are implemented in netcup/client.go. Login (Create Session on server, which is valid for 15 minutes (logout not implemented, because 15 min as default seems ok)) body: ```json "action": "login", "param": { "customernumber": "111", "apikey": "xxxxx", "apipassword": "yyyy" } ``` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
saavagebueno added the pull-request label 2025-11-20 04:25:40 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ddns-updater#678