Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
176 changes: 120 additions & 56 deletions .generator/schemas/v2/openapi.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,10 @@ public static void main(String[] args) {
new ProductAnalyticsSankeyDefinition()
.entriesPerStep(10L)
.numberOfSteps(3L)
.source("@view.name")
.target("@view.name"))
.source("""
@type:view @view.name:"/logs"
""")
.target(""))
.search(
new ProductAnalyticsSankeySearch()
.audienceFilters(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,23 +32,20 @@ public static void main(String[] args) {
+ " @application.name:ecommerce-platform")
.timeFrame(
new QueryEventFilteredUsersRequestDataAttributesEventQueryTimeFrame()
.end(1761309676L)
.start(1760100076L)))
.end(1761309676000L)
.start(1760100076000L)))
.includeRowCount(true)
.limit(25L)
.query(
"user_org_id:5001 AND first_country_code:US AND"
+ " first_browser_name:Chrome")
.query("first_country_code:US AND first_browser_name:Chrome")
.selectColumns(
Arrays.asList(
"user_id",
"user_email",
"user_name",
"first_seen",
"last_seen",
"first_country_code",
"first_browser_name",
"events_count",
"session_count",
"error_count",
"avg_loading_time")))
"first_browser_name")))
.id("query_event_filtered_users_request")
.type(
QueryEventFilteredUsersRequestDataType.QUERY_EVENT_FILTERED_USERS_REQUEST));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,11 @@ public ProductAnalyticsJourneyListResponse queryProductAnalyticsJourneyList(
/**
* Return the individual sessions that reached, or dropped off at, a given step of the journey.
* Each row contains the identity join key, the event timestamp, and the columns requested in
* <code>entity_columns</code>.
* <code>entity_columns</code>. This endpoint lists only sessions. Omit <code>
* query.search.join_keys</code>, or set its <code>primary</code> to <code>@session.id</code>. Any
* other primary join key, such as <code>@usr.id</code>, returns a 400 error. To get the users
* behind the sessions, add <code>@usr.id</code> or <code>@usr.email</code> to <code>
* entity_columns</code>.
*
* @param body (required)
* @return ApiResponse&lt;ProductAnalyticsJourneyListResponse&gt;
Expand Down Expand Up @@ -1049,7 +1053,10 @@ public ProductAnalyticsRetentionListResponse queryProductAnalyticsRetentionList(

/**
* List the individual users or accounts counted in one cell of the retention grid. Set <code>
* computation_scope</code> to the cohort and return period you want to examine.
* computation_scope</code> to the cohort and return period you want to examine. Indexes are
* zero-based, and the cohort index plus the return period index must be lower than the number of
* cohorts between <code>from</code> and <code>to</code>. Make the window long enough to contain
* the return period you ask for.
*
* @param body The retention list query. (required)
* @return ApiResponse&lt;ProductAnalyticsRetentionListResponse&gt;
Expand Down Expand Up @@ -1526,8 +1533,9 @@ public CompletableFuture<ProductAnalyticsSankeyResponse> queryProductAnalyticsSa
}

/**
* Compute a Sankey diagram of how sessions flow between the values of two facets, showing where
* users continue and where they drop off at each step.
* Compute a Sankey diagram of how sessions flow from or to one view, showing where users continue
* and where they drop off at each step. Set either <code>definition.source</code> or <code>
* definition.target</code>, and send the other one as an empty string.
*
* @param body The Sankey diagram query. (required)
* @return ApiResponse&lt;ProductAnalyticsSankeyResponse&gt;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -422,8 +422,8 @@ public CompletableFuture<Void> deleteUserProfileAsync(String userId) {
}

/**
* Delete a Product Analytics user profile. Deletion is asynchronous: the request is accepted and
* the profile is removed shortly after, usually within a few minutes. This only deletes the user
* Delete a Product Analytics user profile. Deletion is asynchronous: Datadog accepts the request
* and removes the profile shortly after, usually within a few minutes. This only deletes the user
* profile. To delete the RUM events of the user, use the RUM data deletion API.
*
* @param userId The ID of the user to delete, as sent in the <code>usr.id</code> attribute.
Expand Down Expand Up @@ -1314,7 +1314,10 @@ public CompletableFuture<QueryResponse> queryEventFilteredUsersAsync(
}

/**
* Query users filtered by both user properties and event platform data
* Query users filtered by both user properties and event platform data. <code>event_query.query
* </code> selects users who have matching events in <code>event_query.time_frame</code>, which is
* in milliseconds. <code>query</code> and <code>select_columns</code> use user profile attribute
* names, not event facets.
*
* @param body (required)
* @return ApiResponse&lt;QueryResponse&gt;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@
import java.util.Map;
import java.util.Objects;

/** Attributes of a journey funnel response. */
/**
* Attributes of a journey funnel response. <code>end_to_end_elapsed_time</code> is omitted when no
* entity converts, for example for a one-step funnel or when conversion is 0.
*/
@JsonPropertyOrder({
ProductAnalyticsJourneyFunnelResponseAttributes.JSON_PROPERTY_END_TO_END_CONVERSION_RATE,
ProductAnalyticsJourneyFunnelResponseAttributes.JSON_PROPERTY_END_TO_END_ELAPSED_TIME,
Expand Down Expand Up @@ -49,19 +52,13 @@ public ProductAnalyticsJourneyFunnelResponseAttributes() {}
public ProductAnalyticsJourneyFunnelResponseAttributes(
@JsonProperty(required = true, value = JSON_PROPERTY_END_TO_END_CONVERSION_RATE)
Double endToEndConversionRate,
@JsonProperty(required = true, value = JSON_PROPERTY_END_TO_END_ELAPSED_TIME)
ProductAnalyticsElapsedTime endToEndElapsedTime,
@JsonProperty(required = true, value = JSON_PROPERTY_FUNNEL_STEPS)
List<ProductAnalyticsJourneyFunnelStep> funnelSteps,
@JsonProperty(required = true, value = JSON_PROPERTY_INITIAL_COUNT) Long initialCount) {
List<ProductAnalyticsJourneyFunnelStep> funnelSteps) {
this.endToEndConversionRate = endToEndConversionRate;
this.endToEndElapsedTime = endToEndElapsedTime;
this.unparsed |= endToEndElapsedTime.unparsed;
this.funnelSteps = funnelSteps;
for (ProductAnalyticsJourneyFunnelStep item : funnelSteps) {
this.unparsed |= item.unparsed;
}
this.initialCount = initialCount;
}

public ProductAnalyticsJourneyFunnelResponseAttributes endToEndConversionRate(
Expand Down Expand Up @@ -97,8 +94,9 @@ public ProductAnalyticsJourneyFunnelResponseAttributes endToEndElapsedTime(
*
* @return endToEndElapsedTime
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_END_TO_END_ELAPSED_TIME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public ProductAnalyticsElapsedTime getEndToEndElapsedTime() {
return endToEndElapsedTime;
}
Expand Down Expand Up @@ -152,12 +150,16 @@ public ProductAnalyticsJourneyFunnelResponseAttributes initialCount(Long initial
}

/**
* Number of entities that entered the funnel.
* Number of entities that entered the funnel. The service does not return this field. Use the
* <code>value</code> of the first entry in <code>funnel_steps</code> only when the query counts
* the joined entity. For rates or other aggregates, run a separate entity-count query to get the
* number of entrants.
*
* @return initialCount
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_INITIAL_COUNT)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Long getInitialCount() {
return initialCount;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ public ProductAnalyticsJourneyFunnelResponseData attributes(
}

/**
* Attributes of a journey funnel response.
* Attributes of a journey funnel response. <code>end_to_end_elapsed_time</code> is omitted when
* no entity converts, for example for a one-step funnel or when conversion is 0.
*
* @return attributes
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@
import java.util.Map;
import java.util.Objects;

/** A single step of the funnel with its conversion counts and timings. */
/**
* A single step of the funnel with its conversion counts and timings. The last step has no <code>
* elapsed_time_to_next_step</code>, in the step and in its groups.
*/
@JsonPropertyOrder({
ProductAnalyticsJourneyFunnelStep.JSON_PROPERTY_ELAPSED_TIME_TO_NEXT_STEP,
ProductAnalyticsJourneyFunnelStep.JSON_PROPERTY_GROUPS,
Expand All @@ -35,7 +38,7 @@ public class ProductAnalyticsJourneyFunnelStep {
private ProductAnalyticsElapsedTime elapsedTimeToNextStep;

public static final String JSON_PROPERTY_GROUPS = "groups";
private List<ProductAnalyticsJourneyFunnelStepGroup> groups = new ArrayList<>();
private List<ProductAnalyticsJourneyFunnelStepGroup> groups = null;

public static final String JSON_PROPERTY_LABEL = "label";
private String label;
Expand All @@ -50,19 +53,9 @@ public ProductAnalyticsJourneyFunnelStep() {}

@JsonCreator
public ProductAnalyticsJourneyFunnelStep(
@JsonProperty(required = true, value = JSON_PROPERTY_ELAPSED_TIME_TO_NEXT_STEP)
ProductAnalyticsElapsedTime elapsedTimeToNextStep,
@JsonProperty(required = true, value = JSON_PROPERTY_GROUPS)
List<ProductAnalyticsJourneyFunnelStepGroup> groups,
@JsonProperty(required = true, value = JSON_PROPERTY_LABEL) String label,
@JsonProperty(required = true, value = JSON_PROPERTY_UNIT) String unit,
@JsonProperty(required = true, value = JSON_PROPERTY_VALUE) Double value) {
this.elapsedTimeToNextStep = elapsedTimeToNextStep;
this.unparsed |= elapsedTimeToNextStep.unparsed;
this.groups = groups;
for (ProductAnalyticsJourneyFunnelStepGroup item : groups) {
this.unparsed |= item.unparsed;
}
this.label = label;
this.unit = unit;
this.value = value;
Expand All @@ -80,8 +73,9 @@ public ProductAnalyticsJourneyFunnelStep elapsedTimeToNextStep(
*
* @return elapsedTimeToNextStep
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_ELAPSED_TIME_TO_NEXT_STEP)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public ProductAnalyticsElapsedTime getElapsedTimeToNextStep() {
return elapsedTimeToNextStep;
}
Expand All @@ -96,26 +90,33 @@ public void setElapsedTimeToNextStep(ProductAnalyticsElapsedTime elapsedTimeToNe
public ProductAnalyticsJourneyFunnelStep groups(
List<ProductAnalyticsJourneyFunnelStepGroup> groups) {
this.groups = groups;
for (ProductAnalyticsJourneyFunnelStepGroup item : groups) {
this.unparsed |= item.unparsed;
if (groups != null) {
for (ProductAnalyticsJourneyFunnelStepGroup item : groups) {
this.unparsed |= item.unparsed;
}
}
return this;
}

public ProductAnalyticsJourneyFunnelStep addGroupsItem(
ProductAnalyticsJourneyFunnelStepGroup groupsItem) {
if (this.groups == null) {
this.groups = new ArrayList<>();
}
this.groups.add(groupsItem);
this.unparsed |= groupsItem.unparsed;
return this;
}

/**
* Breakdown of this step by the requested group-by facets.
* Breakdown of this step by the requested group-by facets. The response omits this field when the
* query has no group-by.
*
* @return groups
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_GROUPS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public List<ProductAnalyticsJourneyFunnelStepGroup> getGroups() {
return groups;
}
Expand Down Expand Up @@ -155,7 +156,8 @@ public ProductAnalyticsJourneyFunnelStep unit(String unit) {
}

/**
* Unit of the elapsed time values.
* The unit of <code>value</code>, such as <code>session</code>, <code>user</code> or <code>%
* </code>, depending on the compute metric.
*
* @return unit
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,9 @@ public ProductAnalyticsJourneyFunnelStepGroup() {}
@JsonCreator
public ProductAnalyticsJourneyFunnelStepGroup(
@JsonProperty(required = true, value = JSON_PROPERTY_CONVERSION_COUNT) Long conversionCount,
@JsonProperty(required = true, value = JSON_PROPERTY_ELAPSED_TIME_TO_NEXT_STEP)
ProductAnalyticsElapsedTime elapsedTimeToNextStep,
@JsonProperty(required = true, value = JSON_PROPERTY_GROUP_TAGS) List<String> groupTags,
@JsonProperty(required = true, value = JSON_PROPERTY_VALUE) Double value) {
this.conversionCount = conversionCount;
this.elapsedTimeToNextStep = elapsedTimeToNextStep;
this.unparsed |= elapsedTimeToNextStep.unparsed;
this.groupTags = groupTags;
this.value = value;
}
Expand Down Expand Up @@ -90,8 +86,9 @@ public ProductAnalyticsJourneyFunnelStepGroup elapsedTimeToNextStep(
*
* @return elapsedTimeToNextStep
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_ELAPSED_TIME_TO_NEXT_STEP)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public ProductAnalyticsElapsedTime getElapsedTimeToNextStep() {
return elapsedTimeToNextStep;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ public ProductAnalyticsJourneyListQuery addEntityColumnsItem(String entityColumn

/**
* Attribute columns to return for each row, in addition to the identity join key and <code>
* timestamp</code>.
* timestamp</code>. For example, <code>@usr.id</code> returns the user of each session.
*
* @return entityColumns
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@

/**
* Narrows a retention query to a single cell, at the intersection of one cohort and one return
* period.
* period. Both indexes are zero-based. The cohort index plus the return period index must be lower
* than the number of cohorts in the query window. For example, return period <code>1</code> of
* cohort <code>0</code> needs a window with at least two cohort intervals, such as two weeks for
* weekly cohorts. Otherwise, the request fails with <code>invalid index</code>.
*/
@JsonPropertyOrder({
ProductAnalyticsRetentionCellScope.JSON_PROPERTY_COHORT_TARGET,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,9 @@ public ProductAnalyticsRetentionCompute metric(ProductAnalyticsRetentionComputeM
}

/**
* The retention metric to compute, either an absolute count or a rate.
* The retention metric to compute. Use <code>__dd.retention</code> for the number of retained
* entities, or <code>__dd.retention_rate</code> for the share of the cohort that was retained.
* The API rejects any other value.
*
* @return metric
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@
import java.util.HashSet;
import java.util.Set;

/** The retention metric to compute, either an absolute count or a rate. */
/**
* The retention metric to compute. Use <code>__dd.retention</code> for the number of retained
* entities, or <code>__dd.retention_rate</code> for the share of the cohort that was retained. The
* API rejects any other value.
*/
@JsonSerialize(
using =
ProductAnalyticsRetentionComputeMetric.ProductAnalyticsRetentionComputeMetricSerializer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,9 @@ public ProductAnalyticsRetentionIndexTarget value(Long value) {
}

/**
* Zero-based index of the targeted cohort or return period. minimum: 0
* Zero-based index of the targeted cohort or return period. It must be lower than the number of
* cohorts in the query window, which is the number of cohort intervals that start between <code>
* from</code> and <code>to</code>. minimum: 0
*
* @return value
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,10 @@ public ProductAnalyticsRetentionListQuery computationScope(

/**
* Narrows a retention query to a single cell, at the intersection of one cohort and one return
* period.
* period. Both indexes are zero-based. The cohort index plus the return period index must be
* lower than the number of cohorts in the query window. For example, return period <code>1</code>
* of cohort <code>0</code> needs a window with at least two cohort intervals, such as two weeks
* for weekly cohorts. Otherwise, the request fails with <code>invalid index</code>.
*
* @return computationScope
*/
Expand Down
Loading
Loading