Skip to content

Commit

Permalink
Add endpoint docs to README (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
nunofgs authored Nov 2, 2023
1 parent b7c25e6 commit d9af6a6
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,36 @@ 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)
}

// ...
}
```

## 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)

0 comments on commit d9af6a6

Please sign in to comment.