diff options
author | HimbeerserverDE <himbeerserverde@gmail.com> | 2022-10-19 22:00:58 +0200 |
---|---|---|
committer | HimbeerserverDE <himbeerserverde@gmail.com> | 2022-10-19 22:00:58 +0200 |
commit | 8ca000cef48893e5c9ca5e5f587fac7ddd8b5469 (patch) | |
tree | 2bf3d1cd5fc416f4431e0734d932d9d1d208d029 | |
parent | 5a824acdb8effa3fba03e7458d7a22a551b4a499 (diff) |
add updateRecords helper
-rw-r--r-- | dyndns.go | 13 | ||||
-rw-r--r-- | go.mod | 2 | ||||
-rw-r--r-- | go.sum | 2 |
3 files changed, 17 insertions, 0 deletions
@@ -4,6 +4,8 @@ package main import ( "flag" "net" + + "github.com/HimbeerserverDE/inwx" ) func main() { @@ -30,3 +32,14 @@ func main() { } } } + +func updateRecords(c *inwx.Client, ids []int, content string) error { + _, err := c.Call(&inwx.NSUpdateRecordsCall{ + IDs: ids, + RecordInfo: inwx.RecordInfo{ + Content: content, + }, + }) + + return err +} @@ -1,3 +1,5 @@ module github.com/HimbeerserverDE/dyndns go 1.19 + +require github.com/HimbeerserverDE/inwx v0.0.1 @@ -0,0 +1,2 @@ +github.com/HimbeerserverDE/inwx v0.0.1 h1:QWeSrEyOsFkII9S5UOX1oABtUzAGlJZGBRGERT8ohjg= +github.com/HimbeerserverDE/inwx v0.0.1/go.mod h1:9Jvob+vCE6XhI+G6QbinYX545I1DcveVqvSuX05v0Kg= |