Skip to content

Commit

Permalink
Add endpoint docs to README
Browse files Browse the repository at this point in the history
  • Loading branch information
nunofgs committed Oct 31, 2023
1 parent b7c25e6 commit 9de9496
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -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)
}

// ...
}
```

0 comments on commit 9de9496

Please sign in to comment.