---
title: Send Optimizely Data Platform data with Real-Time Audiences for Feature Experimentation for the Go SDK
slug: feature-experimentation/docs/send-optimizely-data-platform-data-with-real-time-audiences-for-feature-experimentation-for-the-go-sdk
docTags: 
createdAt: 2026-08-05T20:39:54.000Z
---

## Prerequisites

You must configure [Real-Time Audiences for Feature Experimentation](docId:6UBBxxRv331nBIVZ2lun8) before sending events to Optimizely Data Platform (ODP) from Feature Experimentation.

## Minimum SDK version

2.0.0

## Description

The Optimizely Client extension method, `SendOdpEvent`, lets you send data to the ODP server. This data can then be used to analyze user behavior and optimize experiences across different channels and touchpoints.

The `SendOdpEvent` method can be used to:

- [Merge or stitch users together](docId\:zofYSXRfkDa-2L5Umjfmy) and determine which event is associated with which customer.
- Send various types of events and actions, such as pageviews, clicks, form submissions, and others. When using this method, you can include additional data to provide more context and information about the event being tracked.

For example, by connecting an email address identifier with a `fs_user_id` identifier, you can use the `SendOdpEvent` method to send events that are associated with both identifiers. This enables you to track and analyze the behavior of a specific user across different touchpoints and devices.

You cannot create or update user profile data like name or address with `SendOdpEvent`. Instead, you can use the [ODP Create and update customers API endpoint](docId:8V9hWw_Py3-kwJJ5H7uR0) or [ODP UI](docId:9GxAiVHBPBQndq-66qYBy) to manage customer profiles.

## Send events to Optimizely Data Platform

:::hint{type="info"}
- The Go SDK discards the event immediately if there are any errors (`sdkNotReady`, `odpNotIntegrated`, or `odpNotEnabled`).
- All events (implicit or explicit) are discarded, if requested before the datafile is ready and a warning log is sent.
  - The datafile is expected to be fully ready in the Go SDK before you create user contexts and accept decision requests.
:::

## Parameters

This table lists the required and optional parameters for the `SendOdpEvent` method.

| Parameter           | Type                     | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| ------------------- | ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `eventType`         | String                   | The type of event to be sent. If not specified, defaults to "fullstack" for Go SDK-generated events.                                                                                                                                                                                                                                                                                                                                                                                                          |
| `action` *required* | String                   | Specifies the subcategory of the event type, which is used to track the app and user lifecycle.                                                                                                                                                                                                                                                                                                                                                                                                               |
| `identifiers`       | map\[string]string       | A key-value map of user identifiers. At least one key-value pair is required.                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `data`              | map\[string]interface\{} | The event data in a key-value map. The value can be any type (string, number, or boolean.) Null values are allowed but are interpreted as empty strings.<br />The Go SDK adds default event data to the given data dictionary. You can overwrite the default data values by sending the same key when creating your map.<br />- "idempotence\_id":\<UUID created by the Go SDK><br />- "data\_source\_type":"sdk"<br />- "data\_source":"go-sdk"<br />- "data\_source\_version":\<Go SDK version implemented> |

## Returns

This method sends event data to the Optimizely Data Platform (ODP) server. It returns an error when any issue occurs, otherwise returns nil.

## Example

```go
identifiers := map[string]string{"fs_user_id": "user123", "email": "user123@optimizely.com"}
data := map[string]interface{}{"item": "shirt", "price": 50.00}

err := optimizelyClient.SendOdpEvent("fullstack", "purchased", identifiers, data)
```

The following diagram shows the network calls between your application, the Go SDK, and the ODP server when calling the `SendOdpEvent` method.

![](https://api.archbee.com/api/optimize/BrbvVORKJ5iIeSMZye5kI/aywjoYfvQfZL3CZJRwzAQ_67824bd-go-sendodpevent.png)

1. Your application calls the `SendOdpEvent` method.
2. The Go SDK makes a POST request to ODP.
3. ODP responds with acknowledgment or relevant error.

## Source files

The language and platform source files containing the implementation for Go are available on [GitHub](https://github.com/optimizely/go-sdk/blob/master/pkg/client/client.go).
