From 9de9496f190b74865e4850cbdabf82b67bff5ef3 Mon Sep 17 00:00:00 2001 From: Nuno Sousa Date: Tue, 31 Oct 2023 18:08:42 +0000 Subject: [PATCH 1/2] Add endpoint docs to README --- Readme.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/Readme.md b/Readme.md index 9ba0196..d1d7ac7 100644 --- a/Readme.md +++ b/Readme.md @@ -30,3 +30,28 @@ func main() { client.Close() } ``` + +## Other Regions + +If you're using a [different data center](https://customer.io/docs/accounts-and-workspaces/data-centers/) such as our EU region, you can specify an alternate endpoint: + +```go +package main + +import ( + "os" + + "github.com/customerio/cdp-analytics-go" +) + +func main() { + client, err := analytics.NewWithConfig(os.Getenv("WRITE_KEY"), analytics.Config{ + Endpoint: "https://cdp-eu.customer.io", + }) + if err != nil { + panic(err) + } + + // ... +} +``` From 30bc4d50195259dff58aa30a93dfe960dea2d95b Mon Sep 17 00:00:00 2001 From: Nuno Sousa Date: Thu, 2 Nov 2023 11:52:53 +0000 Subject: [PATCH 2/2] Add documentation links --- Readme.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Readme.md b/Readme.md index d1d7ac7..c82bd94 100644 --- a/Readme.md +++ b/Readme.md @@ -55,3 +55,11 @@ func main() { // ... } ``` + +## Documentation + +The links below contain more detailed documentation on how to use this library: + +* [Documentation](https://customer.io/docs/cdp/sources/connections/servers/go/) +* [Specs](https://customer.io/docs/cdp/sources/source-spec/source-events/) +* [godoc](https://pkg.go.dev/github.com/customerio/cdp-analytics-go)