Skip to main content

Introduction

HoneyHive allows you to set user properties in your traces to gain more insights into your application.

Prerequisites

You have already set tracing for your code as described in our quickstart guide.

Setting User Properties

You can set User Properties on both the trace level or the span level. If the User Properties applies to the entire trace, then set it on the trace level. If the User Properties applies to a specific span, then set it on the span level. For more details, refer to the enrich traces documentation.
User Properties can only be set on the trace level.
In Python, you can use the enrich_session function to set User Properties on the trace level.To pass User Properties to HoneyHive, pass it to the user_properties param in the enrich_session function. This function is used to enrich the session with additional information. Remember that enrich_session will update, not overwrite, the existing user_properties object on the trace.Read more about the enrich_session function in the Python SDK reference.Here’s an example of how to set User Properties on the trace level in Python:
Python

Concepts

What are User Properties?

User properties are additional attributes that you can set on your traces to gain more insights into your application. Examples include:
  • User ID
  • User email
  • User properties
  • User payment plan details
  • User experiment group
User properties can help you link traces to specific users, improving your ability to group and filter traces using user-centric attributes.

SDK Reference

Read more about the enrich_session function in the Python SDK reference.