From 6fa9ba0057f2bc7b298f4bc567e75e9d11ed1193 Mon Sep 17 00:00:00 2001 From: Valentijn van der Jagt <1119935@hr.nl> Date: Tue, 10 Mar 2026 08:33:37 +0100 Subject: [PATCH] freaking-dell speciaal --- main.go | 34 +++++++++++++++++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/main.go b/main.go index 0e7da61..44331b5 100644 --- a/main.go +++ b/main.go @@ -11,6 +11,9 @@ In this project i play around with go. This is my first time writing go, and im // https://stackoverflow.com/questions/16466320/is-there-a-way-to-do-repetitive-tasks-at-intervals, How timer intervals work in GoLang // https://pkg.go.dev/modernc.org/sqlite#section-documentation, how to interface with specifically sqlite in GoLang // https://github.com/mattn/go-sqlite3/blob/v1.14.34/_example/simple/simple.go, How to inferface with a database in GoLang. +// https://go.dev/tour/moretypes/6, arrays.... +// https://go.dev/doc/tutorial/handle-errors, deal with returning errors + import ( "database/sql" "log" @@ -30,7 +33,36 @@ func findParcelProvider(code string, postal_code string)(string, error){ return v, nil } } - return "", errors.New("parcel not found!") + return "", errors.New("Parcel not found in the common providers!") +} + +func markPackageSubscription(code string, postal_code string, service string){ + /* + +{ + "type": "Shipment", + "format": "Default", + "service": "parcel-nl", + "hook": { + "uri": "https://your-server.example.com/dhl-webhook" + }, + "events": [ + "pre-transit", + "transit", + "delivered", + "failure", + "unknown" + ], + "shipmentIDsWithChallengeDetails": [ + { + "shipmentID": "3SABCDEF123456", + "postalCode": "1012AB" + } + ] +} + + */ + }