-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
13 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -220,7 +220,7 @@ You can also send anonymous events representing people you haven't identified. A | |
|
||
```go | ||
// Arguments | ||
// anonymous_id (required) - an identifier representing an unknown person. | ||
// anonymous_id (required) - nullable, an identifier representing an unknown person. | ||
// name (required) - the name of the event you want to track. | ||
// attributes (optional) - any related information you'd like to attach to this | ||
// event, as a ```map[string]interface{}```. | ||
|
@@ -234,6 +234,18 @@ if err := track.TrackAnonymous("anonymous_id", "invite", map[string]interface{}{ | |
// handle error | ||
} | ||
``` | ||
#### Anonymous invite events | ||
|
||
If you previously sent [invite events](https://customer.io/docs/anonymous-invite-emails/), you can achieve the same functionality by sending an anonymous event an empty string for the anonymous identifier. To send anonymous invites, your event *must* include a `recipient` attribute. | ||
|
||
```go | ||
if err := track.TrackAnonymous("", "invite", map[string]interface{}{ | ||
"first_name": "Alex", | ||
"recipient": "[email protected]", | ||
}); err != nil { | ||
// handle error | ||
} | ||
``` | ||
|
||
### Adding a device to a customer | ||
|
||
|