LaunchDarkly Source


LaunchDarkly is a feature management platform that empowers development teams to safely deliver and control software through feature flags.

This is an Event Cloud Source which can not only export data into your Segment warehouse, but they can also federate the exported data into your other enabled Segment Destinations.

This source is maintained by LaunchDarkly. For any issues with the source, please reach out to their team.

NOTE: The LaunchDarkly Source is currently in beta, which means that they are still actively developing the source. This doc was last updated on November 8, 2019. If you are interested in joining their beta program or have any feedback to help improve the LaunchDarkly Source and its documentation, please let their team know!

Getting Started

  1. From your Segment UI’s Sources page click on “Add Source”.
  2. Search for “LaunchDarkly” within the Sources Catalog and confirm by clicking “Connect”.
  3. Give the Source a nickname and follow the setup flow to “Add Source”. The nickname will be used to designate the source in the Segment interface, and Segment will create a related schema name. The schema name is the namespace you’ll be querying against in your warehouse. The nickname can be whatever you like, but we recommend sticking to something that reflects the source itself and distinguishes amongst your environments (eg. SourceName_Prod, SourceName_Staging, SourceName_Dev).
  4. Copy the Write key from the Segment UI and log in to your LaunchDarkly account - navigate to Integrations > Data Export Destinations
  5. Select “Add destination” and select “Segment” in the dropdown menu.
  6. Choose a name for the destination and the LaunchDarkly environment for which events will be forwarded to Segment
  7. Paste the Segment key into the “Write Key” textbox.
  8. Click “Save Destination”

Events

Below is a table of events that LaunchDarkly sends to Segment. These events will show up as tables in your warehouse, and as regular events in your other Destinations. LaunchDarkly will send through the userId if available.

Event Name Description
feature A feature flag has been evaluated
click A user clicked on a CSS selector for which they have configured a LaunchDarkly experimentation goal
Page A user has loaded a page which is associated with a LaunchDarkly experimentation goal
Custom A custom event was sent by the LaunchDarkly SDK

Event Properties

Below are tables outlining the properties included in the events listed above.

Property Name Description
event event type
Common Properties Properties common to all event types
environment The LaunchDarkly environment ID corresponding to event
project The LaunchDarkly project ID corresponding to the event
key The flag key corresponding to the event. In the case of experimentation events, this will be the goal key for the experiment.
Feature Request Event Properties
value The value the flag evaluated to
flagVersion The version of the flag when it was evaluated
reasonKind The evaluation reason for the flag.
prereqOf Set to another flag’s key if this flag evaluation was only performed in order to determine whether the prerequisite values were met for the indicated flag. See flag prerequisites.
default Indicates whether the flag value was the result of the default variation being selected
variation The variation of the flag requested. Flag variation values are stored in an array. This value corresponds to the index of the variation the array. Boolean flags show as 0 or 1 for true and false, and other flag types are numbered starting with 0 for their different variations.
Page View Event Properties
url The URL the user was on when the flag was evaluated
Click Event Properties
url The URL the user was on when the flag was evaluated
selector Contains the CSS selector corresponding to the click event
Custom Event Properties Custom Events have no additional properties besides the common properties

Adding Destinations

Now that your Source is set up, you can connect it with Destinations.

Log into your downstream tools and check to see that your events are populating and they contains all the properties you expect. If all your events and properties are not showing up, refer to the Destination docs for troubleshooting.

If there are any issues with how the events are arriving to Segment, please contact the LaunchDarkly team.

Get started with Segment

Segment is the easiest way to integrate your websites & mobile apps data to over 300 analytics and growth tools.
or
Create free account