From 83f57772e9c6ad92646befa15bfd721460a1dd71 Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Fri, 8 May 2026 08:20:47 +0000 Subject: [PATCH] Regenerate client from commit 5d07320 of spec repo --- .generator/schemas/v2/openapi.yaml | 789 ++++++++++++++++++ docs/datadog_api_client.v2.api.rst | 14 + docs/datadog_api_client.v2.model.rst | 168 ++++ .../GetReplayAnalysisIssue.py | 16 + .../ListReplayAnalysisIssueSessions.py | 16 + .../ListReplayAnalysisIssues.py | 14 + .../v2/rum-replay/GenerateReplaySummary.py | 25 + src/datadog_api_client/configuration.py | 4 + .../v2/api/rum_replay_analysis_api.py | 262 ++++++ .../v2/api/rum_replay_api.py | 96 +++ src/datadog_api_client/v2/apis/__init__.py | 4 + .../model/replay_analysis_affected_session.py | 46 + .../v2/model/replay_analysis_issue_data.py | 56 ++ .../replay_analysis_issue_data_attributes.py | 141 ++++ .../model/replay_analysis_issue_data_type.py | 35 + .../v2/model/replay_analysis_issue_meta.py | 40 + .../model/replay_analysis_issue_response.py | 40 + .../replay_analysis_issue_session_data.py | 66 ++ ..._analysis_issue_session_data_attributes.py | 52 ++ ...replay_analysis_issue_session_data_type.py | 35 + ...replay_analysis_issue_sessions_response.py | 48 ++ .../model/replay_analysis_issues_response.py | 48 ++ .../v2/model/replay_analysis_llm_details.py | 40 + .../v2/model/replay_analysis_page_meta.py | 33 + .../replay_analysis_representative_session.py | 95 +++ .../v2/model/replay_analysis_screenshot.py | 51 ++ .../v2/model/replay_analysis_signal.py | 51 ++ .../v2/model/replay_summary_chapter.py | 45 + ...replay_summary_data_attributes_response.py | 72 ++ .../v2/model/replay_summary_data_request.py | 40 + .../v2/model/replay_summary_data_response.py | 58 ++ .../v2/model/replay_summary_request.py | 40 + .../v2/model/replay_summary_request_type.py | 35 + .../v2/model/replay_summary_response.py | 40 + .../v2/model/replay_summary_response_type.py | 35 + src/datadog_api_client/v2/models/__init__.py | 50 ++ tests/v2/features/rum_replay.feature | 32 + tests/v2/features/rum_replay_analysis.feature | 72 ++ tests/v2/features/undo.json | 24 + 39 files changed, 2828 insertions(+) create mode 100644 examples/v2/rum-replay-analysis/GetReplayAnalysisIssue.py create mode 100644 examples/v2/rum-replay-analysis/ListReplayAnalysisIssueSessions.py create mode 100644 examples/v2/rum-replay-analysis/ListReplayAnalysisIssues.py create mode 100644 examples/v2/rum-replay/GenerateReplaySummary.py create mode 100644 src/datadog_api_client/v2/api/rum_replay_analysis_api.py create mode 100644 src/datadog_api_client/v2/api/rum_replay_api.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_affected_session.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_data.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_data_attributes.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_data_type.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_meta.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_response.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_session_data.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_session_data_attributes.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_session_data_type.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issue_sessions_response.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_issues_response.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_llm_details.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_page_meta.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_representative_session.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_screenshot.py create mode 100644 src/datadog_api_client/v2/model/replay_analysis_signal.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_chapter.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_data_attributes_response.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_data_request.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_data_response.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_request.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_request_type.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_response.py create mode 100644 src/datadog_api_client/v2/model/replay_summary_response_type.py create mode 100644 tests/v2/features/rum_replay.feature create mode 100644 tests/v2/features/rum_replay_analysis.feature diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index ecadd5414e..d71c0845fb 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -58474,6 +58474,430 @@ components: type: string x-enum-varnames: - RULESET + ReplayAnalysisAffectedSession: + description: A session affected by a replay analysis issue. + properties: + session_id: + description: Unique identifier of the affected session. + example: 00000000-0000-0000-0000-000000000001 + type: string + session_start_timestamp_ms: + description: Session start timestamp in milliseconds. + example: 1776415149520 + format: int64 + nullable: true + type: integer + required: + - session_id + type: object + ReplayAnalysisIssueData: + description: Data object representing a RUM replay analysis issue. + properties: + attributes: + $ref: "#/components/schemas/ReplayAnalysisIssueDataAttributes" + id: + description: Unique identifier of the issue. + example: 00000000-0000-0000-0000-000000000001 + type: string + type: + $ref: "#/components/schemas/ReplayAnalysisIssueDataType" + required: + - id + - type + - attributes + type: object + ReplayAnalysisIssueDataAttributes: + description: Attributes of a RUM replay analysis issue. + properties: + affected_sessions: + description: Up to three sample sessions affected by this issue. + items: + $ref: "#/components/schemas/ReplayAnalysisAffectedSession" + type: array + application_id: + description: Unique identifier of the application where the issue was detected. + example: 00000000-0000-0000-0000-000000000001 + type: string + created_at: + description: Timestamp when the issue was first detected. + example: "2025-01-01T00:00:00Z" + format: date-time + type: string + description: + description: Human-readable description of the issue. + example: User is unable to complete checkout. + type: string + journey_query: + additionalProperties: {} + description: Journey query associated with the issue. + nullable: true + type: object + name: + description: Name of the issue. + example: Checkout failure + type: string + representative_session: + $ref: "#/components/schemas/ReplayAnalysisRepresentativeSession" + session_count: + description: Total number of sessions affected by this issue. + example: 42 + format: int64 + type: integer + severity: + description: Severity level of the issue. Valid values are `high`, `medium`, and `low`. + example: high + type: string + updated_at: + description: Timestamp when the issue was last updated. + example: "2025-01-01T00:00:00Z" + format: date-time + type: string + validation_verdict: + description: Validation status of the issue. + example: confirmed + type: string + required: + - application_id + - name + - description + - severity + - validation_verdict + - created_at + - updated_at + - session_count + - affected_sessions + - representative_session + type: object + ReplayAnalysisIssueDataType: + default: issues + description: RUM replay analysis issue resource type. + enum: + - issues + example: issues + type: string + x-enum-varnames: + - ISSUES + ReplayAnalysisIssueMeta: + description: Metadata object for paginated issue list responses. + properties: + page: + $ref: "#/components/schemas/ReplayAnalysisPageMeta" + required: + - page + type: object + ReplayAnalysisIssueResponse: + description: A single RUM replay analysis issue. + properties: + data: + $ref: "#/components/schemas/ReplayAnalysisIssueData" + required: + - data + type: object + ReplayAnalysisIssueSessionData: + description: Data object representing a session related to a RUM replay analysis issue. + properties: + attributes: + $ref: "#/components/schemas/ReplayAnalysisIssueSessionDataAttributes" + id: + description: Unique identifier of the session. + example: 00000000-0000-0000-0000-000000000001 + type: string + type: + $ref: "#/components/schemas/ReplayAnalysisIssueSessionDataType" + required: + - id + - type + - attributes + type: object + ReplayAnalysisIssueSessionDataAttributes: + description: Attributes of a session related to a RUM replay analysis issue. + properties: + session_start_timestamp_ms: + description: Session start timestamp in milliseconds. + example: 1776415149520 + format: int64 + type: integer + signals: + description: List of signals observed in this session. + items: + $ref: "#/components/schemas/ReplayAnalysisSignal" + type: array + view_name: + description: Name of the view where the issue was observed. + example: checkout + type: string + required: + - session_start_timestamp_ms + - view_name + - signals + type: object + ReplayAnalysisIssueSessionDataType: + default: sessions + description: RUM replay analysis issue session resource type. + enum: + - sessions + example: sessions + type: string + x-enum-varnames: + - SESSIONS + ReplayAnalysisIssueSessionsResponse: + description: A paginated list of sessions related to a RUM replay analysis issue. + properties: + data: + description: Array of session data objects related to the issue. + items: + $ref: "#/components/schemas/ReplayAnalysisIssueSessionData" + type: array + meta: + $ref: "#/components/schemas/ReplayAnalysisIssueMeta" + required: + - data + - meta + type: object + ReplayAnalysisIssuesResponse: + description: A paginated list of RUM replay analysis issues. + properties: + data: + description: Array of RUM replay analysis issue data objects. + items: + $ref: "#/components/schemas/ReplayAnalysisIssueData" + type: array + meta: + $ref: "#/components/schemas/ReplayAnalysisIssueMeta" + required: + - data + - meta + type: object + ReplayAnalysisLLMDetails: + description: AI-generated analysis details for a replay issue. + properties: + intent: + description: Interpreted user intent derived from session analysis. + example: Add item to cart. + type: string + user_pattern: + description: List of user behavior steps observed in the session. + example: + - Navigated to checkout + - Clicked buy button + items: + type: string + type: array + required: + - intent + - user_pattern + type: object + ReplayAnalysisPageMeta: + description: Pagination metadata for a RUM replay analysis response. + properties: + total_filtered_count: + description: Total number of items matching the current filters. + example: 100 + format: int64 + type: integer + required: + - total_filtered_count + type: object + ReplayAnalysisRepresentativeSession: + description: A representative session illustrating a replay analysis issue. + properties: + issue_category: + description: Category of the issue observed in this session. + example: usability + type: string + llm_analysis_details: + $ref: "#/components/schemas/ReplayAnalysisLLMDetails" + screenshot: + $ref: "#/components/schemas/ReplayAnalysisScreenshot" + session_id: + description: Unique identifier of the representative session. + example: 00000000-0000-0000-0000-000000000001 + type: string + session_start_timestamp_ms: + description: Session start timestamp in milliseconds. + example: 1776415149520 + format: int64 + type: integer + signals: + description: List of signals observed in the representative session. + items: + $ref: "#/components/schemas/ReplayAnalysisSignal" + type: array + view_name: + description: Name of the view where the issue was observed. + example: checkout + nullable: true + type: string + required: + - session_id + - issue_category + - session_start_timestamp_ms + - llm_analysis_details + - signals + type: object + ReplayAnalysisScreenshot: + description: A screenshot captured during a replay session. + properties: + screenshot_key: + description: Filename or key identifier of the screenshot. + example: ts.webp + type: string + session_id: + description: Unique identifier of the session where the screenshot was taken. + example: 00000000-0000-0000-0000-000000000001 + type: string + timestamp_ms: + description: Timestamp of the screenshot in milliseconds. + example: 1700000000000 + format: int64 + type: integer + view_id: + description: Unique identifier of the view where the screenshot was taken. + example: 00000000-0000-0000-0000-000000000002 + type: string + required: + - session_id + - view_id + - screenshot_key + - timestamp_ms + type: object + ReplayAnalysisSignal: + description: A signal associated with a replay issue, capturing user interaction details. + properties: + event: + description: Event name associated with the signal. + example: button + type: string + signal_type: + description: Type of signal captured. + example: click + type: string + timestamp_ms: + description: Absolute timestamp of the signal in milliseconds. + example: 1776415149620 + format: int64 + type: integer + user_pattern: + description: User behavior pattern identified for the signal. + example: rage click + type: string + required: + - signal_type + - event + - user_pattern + - timestamp_ms + type: object + ReplaySummaryChapter: + description: A chapter within a RUM replay summary, representing a distinct segment of user activity. + properties: + end_ms: + description: End time of the chapter in milliseconds. + example: 60000 + format: int64 + type: integer + start_ms: + description: Start time of the chapter in milliseconds. + example: 0 + format: int64 + type: integer + text: + description: Description of user activity during this chapter. + example: Browsing + type: string + required: + - text + - start_ms + - end_ms + type: object + ReplaySummaryDataAttributesResponse: + description: Attributes of a RUM replay summary response. + properties: + chapters: + description: List of chapters breaking down the session into distinct activity segments. + items: + $ref: "#/components/schemas/ReplaySummaryChapter" + type: array + has_enough_activity: + description: Whether the session contained sufficient user activity to generate a summary. + example: true + type: boolean + has_too_many_events: + description: Whether the session exceeded the event count limit for summary generation. + example: false + type: boolean + summary: + description: AI-generated summary of the replay session. + example: User browsed the home page and attempted to add an item to the cart. + type: string + version: + description: Version of the prompt used to generate the summary. + example: 3-65f24320d95eb8d3 + type: string + required: + - summary + - chapters + - version + - has_enough_activity + - has_too_many_events + type: object + ReplaySummaryDataRequest: + description: Data object for a RUM replay summary request. + properties: + type: + $ref: "#/components/schemas/ReplaySummaryRequestType" + required: + - type + type: object + ReplaySummaryDataResponse: + description: Data object for a RUM replay summary response. + properties: + attributes: + $ref: "#/components/schemas/ReplaySummaryDataAttributesResponse" + id: + description: Unique identifier of the generated summary. + example: 00000000-0000-0000-0000-000000000001 + type: string + type: + $ref: "#/components/schemas/ReplaySummaryResponseType" + required: + - id + - type + - attributes + type: object + ReplaySummaryRequest: + description: Request body for generating a RUM replay summary. + properties: + data: + $ref: "#/components/schemas/ReplaySummaryDataRequest" + required: + - data + type: object + ReplaySummaryRequestType: + default: replay_summary_request + description: RUM replay summary request resource type. + enum: + - replay_summary_request + example: replay_summary_request + type: string + x-enum-varnames: + - REPLAY_SUMMARY_REQUEST + ReplaySummaryResponse: + description: Response containing a generated RUM replay summary. + properties: + data: + $ref: "#/components/schemas/ReplaySummaryDataResponse" + required: + - data + type: object + ReplaySummaryResponseType: + default: summary_response + description: RUM replay summary response resource type. + enum: + - summary_response + example: summary_response + type: string + x-enum-varnames: + - SUMMARY_RESPONSE ResolveVulnerableSymbolsRequest: description: The top-level request object for resolving vulnerable symbols in a set of packages. properties: @@ -123854,6 +124278,278 @@ paths: summary: Update a Workload Protection policy tags: ["CSM Threats"] x-codegen-request-body-name: body + /api/v2/replay/analysis/issues: + get: + description: Retrieve a paginated list of RUM replay analysis issues, optionally filtered by application, severity, view name, or issue category. + operationId: ListReplayAnalysisIssues + parameters: + - description: Filter issues by application UUID. + in: query + name: filter[application_id] + schema: + example: 00000000-0000-0000-0000-000000000001 + type: string + - description: Filter issues by comma-separated severity values. Valid values are `high`, `medium`, and `low`. + in: query + name: filter[severity] + schema: + example: high,medium + type: string + - description: Filter issues by comma-separated view names. + in: query + name: filter[view_name] + schema: + example: checkout,cart + type: string + - description: Filter issues by comma-separated issue categories. + in: query + name: filter[issue_category] + schema: + example: user_confusion,system_failure + type: string + - description: Sort order for the results. Valid values are `created_at`, `-created_at`, `severity`, `-severity`, `session_count`, and `-session_count`. Defaults to `-created_at`. + in: query + name: sort + schema: + default: -created_at + example: -created_at + type: string + - description: Page number for pagination (0-indexed). + in: query + name: page[number] + schema: + default: 0 + example: 0 + minimum: 0 + type: integer + - description: Number of items per page. Must be between 1 and 100. + in: query + name: page[size] + schema: + default: 15 + example: 15 + maximum: 100 + minimum: 1 + type: integer + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + - attributes: + affected_sessions: + - session_id: 00000000-0000-0000-0000-000000000002 + session_start_timestamp_ms: 1776415149520 + application_id: 00000000-0000-0000-0000-000000000001 + created_at: "2025-01-01T00:00:00Z" + description: User is unable to complete checkout. + name: Checkout failure + representative_session: + issue_category: usability + llm_analysis_details: + intent: Add item to cart. + user_pattern: + - Navigated to checkout + - Clicked buy button + session_id: 00000000-0000-0000-0000-000000000002 + session_start_timestamp_ms: 1776415149520 + signals: + - event: button + signal_type: click + timestamp_ms: 1776415149620 + user_pattern: rage click + session_count: 42 + severity: high + updated_at: "2025-01-01T00:00:00Z" + validation_verdict: confirmed + id: 00000000-0000-0000-0000-000000000001 + type: issues + meta: + page: + total_filtered_count: 100 + schema: + $ref: "#/components/schemas/ReplayAnalysisIssuesResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: List replay analysis issues + tags: + - Rum Replay Analysis + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). + /api/v2/replay/analysis/issues/{issue_id}: + get: + description: Retrieve details of a specific RUM replay analysis issue by its identifier. + operationId: GetReplayAnalysisIssue + parameters: + - description: Unique identifier of the issue. + in: path + name: issue_id + required: true + schema: + example: 00000000-0000-0000-0000-000000000001 + type: string + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + attributes: + affected_sessions: + - session_id: 00000000-0000-0000-0000-000000000002 + session_start_timestamp_ms: 1776415149520 + application_id: 00000000-0000-0000-0000-000000000001 + created_at: "2025-01-01T00:00:00Z" + description: User is unable to complete checkout. + name: Checkout failure + representative_session: + issue_category: usability + llm_analysis_details: + intent: Add item to cart. + user_pattern: + - Navigated to checkout + - Clicked buy button + session_id: 00000000-0000-0000-0000-000000000002 + session_start_timestamp_ms: 1776415149520 + signals: + - event: button + signal_type: click + timestamp_ms: 1776415149620 + user_pattern: rage click + session_count: 42 + severity: high + updated_at: "2025-01-01T00:00:00Z" + validation_verdict: confirmed + id: 00000000-0000-0000-0000-000000000001 + type: issues + schema: + $ref: "#/components/schemas/ReplayAnalysisIssueResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Get replay analysis issue + tags: + - Rum Replay Analysis + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). + /api/v2/replay/analysis/issues/{issue_id}/sessions: + get: + description: Retrieve a paginated list of sessions related to a specific RUM replay analysis issue. + operationId: ListReplayAnalysisIssueSessions + parameters: + - description: Unique identifier of the issue. + in: path + name: issue_id + required: true + schema: + example: 00000000-0000-0000-0000-000000000001 + type: string + - description: Sort order for the results. Valid values are `last_seen_at`, `-last_seen_at`, `proximity`, and `-proximity`. Defaults to `-last_seen_at`. + in: query + name: sort + schema: + default: -last_seen_at + example: -last_seen_at + type: string + - description: Page number for pagination (0-indexed). + in: query + name: page[number] + schema: + default: 0 + example: 0 + minimum: 0 + type: integer + - description: Number of items per page. Must be between 1 and 100. + in: query + name: page[size] + schema: + default: 15 + example: 15 + maximum: 100 + minimum: 1 + type: integer + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + - attributes: + session_start_timestamp_ms: 1776415149520 + signals: + - event: button + signal_type: click + timestamp_ms: 1776415149620 + user_pattern: rage click + view_name: checkout + id: 00000000-0000-0000-0000-000000000001 + type: sessions + meta: + page: + total_filtered_count: 100 + schema: + $ref: "#/components/schemas/ReplayAnalysisIssueSessionsResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: List replay analysis issue sessions + tags: + - Rum Replay Analysis + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/replay/heatmap/snapshots: get: description: List heatmap snapshots. @@ -124038,6 +124734,95 @@ paths: summary: Update replay heatmap snapshot tags: - Rum Replay Heatmaps + /api/v2/replay/summary/{session_id}: + post: + description: Generate an AI-powered summary for a RUM replay session, including chapter breakdowns and behavioral analysis. + operationId: GenerateReplaySummary + parameters: + - description: Unique identifier of the session. + in: path + name: session_id + required: true + schema: + example: 00000000-0000-0000-0000-000000000001 + type: string + - description: Data source for the session. Valid values are `rum`, `product_analytics`, and `replay`. + in: query + name: data_source + required: true + schema: + example: rum + type: string + - description: Server-side timestamp in milliseconds. + in: query + name: ts + schema: + example: 1704067200000 + format: int64 + type: integer + requestBody: + content: + application/json: + examples: + default: + value: + data: + type: replay_summary_request + schema: + $ref: "#/components/schemas/ReplaySummaryRequest" + required: true + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + attributes: + chapters: + - end_ms: 60000 + start_ms: 0 + text: Browsing + has_enough_activity: true + has_too_many_events: false + summary: User browsed the home page and attempted to add an item to the cart. + version: 3-65f24320d95eb8d3 + id: 00000000-0000-0000-0000-000000000001 + type: summary_response + schema: + $ref: "#/components/schemas/ReplaySummaryResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "403": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Forbidden + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + security: + - apiKeyAuth: [] + appKeyAuth: [] + - AuthZ: [] + summary: Generate replay summary + tags: + - Rum Replay + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/restriction_policy/{resource_id}: delete: description: Deletes the restriction policy associated with a specified resource. @@ -146293,6 +147078,10 @@ tags: description: Find out more at url: https://docs.datadoghq.com/real_user_monitoring/platform/generate_metrics/ name: Rum Metrics + - description: Generate and retrieve AI-powered summaries of RUM replay sessions. + name: Rum Replay + - description: Analyze RUM replay sessions to identify and investigate user-facing issues. Retrieve issues detected by AI analysis, get details for individual issues, and explore the sessions associated with each issue. + name: Rum Replay Analysis - description: Manage heatmap snapshots for RUM replay sessions. Create, update, delete, and retrieve snapshots to visualize user interactions on specific views. name: Rum Replay Heatmaps - description: Create and manage playlists of RUM replay sessions. Organize, categorize, and share collections of replay sessions for analysis and collaboration. diff --git a/docs/datadog_api_client.v2.api.rst b/docs/datadog_api_client.v2.api.rst index 81b5337963..bfe1561761 100644 --- a/docs/datadog_api_client.v2.api.rst +++ b/docs/datadog_api_client.v2.api.rst @@ -592,6 +592,20 @@ datadog\_api\_client.v2.api.rum\_metrics\_api module :members: :show-inheritance: +datadog\_api\_client.v2.api.rum\_replay\_analysis\_api module +------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.api.rum_replay_analysis_api + :members: + :show-inheritance: + +datadog\_api\_client.v2.api.rum\_replay\_api module +--------------------------------------------------- + +.. automodule:: datadog_api_client.v2.api.rum_replay_api + :members: + :show-inheritance: + datadog\_api\_client.v2.api.rum\_replay\_heatmaps\_api module ------------------------------------------------------------- diff --git a/docs/datadog_api_client.v2.model.rst b/docs/datadog_api_client.v2.model.rst index 4acfd1f380..f00284cabd 100644 --- a/docs/datadog_api_client.v2.model.rst +++ b/docs/datadog_api_client.v2.model.rst @@ -25596,6 +25596,174 @@ datadog\_api\_client.v2.model.reorder\_ruleset\_resource\_data\_type module :members: :show-inheritance: +datadog\_api\_client.v2.model.replay\_analysis\_affected\_session module +------------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.replay_analysis_affected_session + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_data module +------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_data + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_data\_attributes module +------------------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_data_attributes + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_data\_type module +------------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_data_type + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_meta module +------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_meta + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_response module +---------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_session\_data module +--------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_session_data + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_session\_data\_attributes module +--------------------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_session_data_attributes + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_session\_data\_type module +--------------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_session_data_type + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issue\_sessions\_response module +-------------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issue_sessions_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_issues\_response module +----------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_issues_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_llm\_details module +------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_llm_details + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_page\_meta module +----------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_page_meta + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_representative\_session module +------------------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.replay_analysis_representative_session + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_screenshot module +----------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_screenshot + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_analysis\_signal module +------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_analysis_signal + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_chapter module +------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_chapter + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_data\_attributes\_response module +-------------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_data_attributes_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_data\_request module +------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_data_request + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_data\_response module +-------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_data_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_request module +------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_request + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_request\_type module +------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_request_type + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_response module +-------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.replay\_summary\_response\_type module +-------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.replay_summary_response_type + :members: + :show-inheritance: + datadog\_api\_client.v2.model.resolve\_vulnerable\_symbols\_request module -------------------------------------------------------------------------- diff --git a/examples/v2/rum-replay-analysis/GetReplayAnalysisIssue.py b/examples/v2/rum-replay-analysis/GetReplayAnalysisIssue.py new file mode 100644 index 0000000000..cb82a6f932 --- /dev/null +++ b/examples/v2/rum-replay-analysis/GetReplayAnalysisIssue.py @@ -0,0 +1,16 @@ +""" +Get replay analysis issue returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.rum_replay_analysis_api import RumReplayAnalysisApi + +configuration = Configuration() +configuration.unstable_operations["get_replay_analysis_issue"] = True +with ApiClient(configuration) as api_client: + api_instance = RumReplayAnalysisApi(api_client) + response = api_instance.get_replay_analysis_issue( + issue_id="00000000-0000-0000-0000-000000000001", + ) + + print(response) diff --git a/examples/v2/rum-replay-analysis/ListReplayAnalysisIssueSessions.py b/examples/v2/rum-replay-analysis/ListReplayAnalysisIssueSessions.py new file mode 100644 index 0000000000..72d5ca7699 --- /dev/null +++ b/examples/v2/rum-replay-analysis/ListReplayAnalysisIssueSessions.py @@ -0,0 +1,16 @@ +""" +List replay analysis issue sessions returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.rum_replay_analysis_api import RumReplayAnalysisApi + +configuration = Configuration() +configuration.unstable_operations["list_replay_analysis_issue_sessions"] = True +with ApiClient(configuration) as api_client: + api_instance = RumReplayAnalysisApi(api_client) + response = api_instance.list_replay_analysis_issue_sessions( + issue_id="00000000-0000-0000-0000-000000000001", + ) + + print(response) diff --git a/examples/v2/rum-replay-analysis/ListReplayAnalysisIssues.py b/examples/v2/rum-replay-analysis/ListReplayAnalysisIssues.py new file mode 100644 index 0000000000..bc3a3b5e39 --- /dev/null +++ b/examples/v2/rum-replay-analysis/ListReplayAnalysisIssues.py @@ -0,0 +1,14 @@ +""" +List replay analysis issues returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.rum_replay_analysis_api import RumReplayAnalysisApi + +configuration = Configuration() +configuration.unstable_operations["list_replay_analysis_issues"] = True +with ApiClient(configuration) as api_client: + api_instance = RumReplayAnalysisApi(api_client) + response = api_instance.list_replay_analysis_issues() + + print(response) diff --git a/examples/v2/rum-replay/GenerateReplaySummary.py b/examples/v2/rum-replay/GenerateReplaySummary.py new file mode 100644 index 0000000000..6ded101408 --- /dev/null +++ b/examples/v2/rum-replay/GenerateReplaySummary.py @@ -0,0 +1,25 @@ +""" +Generate replay summary returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.rum_replay_api import RumReplayApi +from datadog_api_client.v2.model.replay_summary_data_request import ReplaySummaryDataRequest +from datadog_api_client.v2.model.replay_summary_request import ReplaySummaryRequest +from datadog_api_client.v2.model.replay_summary_request_type import ReplaySummaryRequestType + +body = ReplaySummaryRequest( + data=ReplaySummaryDataRequest( + type=ReplaySummaryRequestType.REPLAY_SUMMARY_REQUEST, + ), +) + +configuration = Configuration() +configuration.unstable_operations["generate_replay_summary"] = True +with ApiClient(configuration) as api_client: + api_instance = RumReplayApi(api_client) + response = api_instance.generate_replay_summary( + session_id="00000000-0000-0000-0000-000000000001", data_source="rum", body=body + ) + + print(response) diff --git a/src/datadog_api_client/configuration.py b/src/datadog_api_client/configuration.py index 36e9294b5b..71b332e570 100644 --- a/src/datadog_api_client/configuration.py +++ b/src/datadog_api_client/configuration.py @@ -493,6 +493,10 @@ def __init__( "v2.query_event_filtered_users": False, "v2.query_users": False, "v2.update_connection": False, + "v2.get_replay_analysis_issue": False, + "v2.list_replay_analysis_issues": False, + "v2.list_replay_analysis_issue_sessions": False, + "v2.generate_replay_summary": False, "v2.create_scorecard_outcomes_batch": False, "v2.list_entity_risk_scores": False, "v2.create_incident_service": False, diff --git a/src/datadog_api_client/v2/api/rum_replay_analysis_api.py b/src/datadog_api_client/v2/api/rum_replay_analysis_api.py new file mode 100644 index 0000000000..c168cfe783 --- /dev/null +++ b/src/datadog_api_client/v2/api/rum_replay_analysis_api.py @@ -0,0 +1,262 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import Any, Dict, Union + +from datadog_api_client.api_client import ApiClient, Endpoint as _Endpoint +from datadog_api_client.configuration import Configuration +from datadog_api_client.model_utils import ( + UnsetType, + unset, +) +from datadog_api_client.v2.model.replay_analysis_issues_response import ReplayAnalysisIssuesResponse +from datadog_api_client.v2.model.replay_analysis_issue_response import ReplayAnalysisIssueResponse +from datadog_api_client.v2.model.replay_analysis_issue_sessions_response import ReplayAnalysisIssueSessionsResponse + + +class RumReplayAnalysisApi: + """ + Analyze RUM replay sessions to identify and investigate user-facing issues. Retrieve issues detected by AI analysis, get details for individual issues, and explore the sessions associated with each issue. + """ + + def __init__(self, api_client=None): + if api_client is None: + api_client = ApiClient(Configuration()) + self.api_client = api_client + + self._get_replay_analysis_issue_endpoint = _Endpoint( + settings={ + "response_type": (ReplayAnalysisIssueResponse,), + "auth": ["apiKeyAuth", "appKeyAuth", "AuthZ"], + "endpoint_path": "/api/v2/replay/analysis/issues/{issue_id}", + "operation_id": "get_replay_analysis_issue", + "http_method": "GET", + "version": "v2", + }, + params_map={ + "issue_id": { + "required": True, + "openapi_types": (str,), + "attribute": "issue_id", + "location": "path", + }, + }, + headers_map={ + "accept": ["application/json"], + }, + api_client=api_client, + ) + + self._list_replay_analysis_issues_endpoint = _Endpoint( + settings={ + "response_type": (ReplayAnalysisIssuesResponse,), + "auth": ["apiKeyAuth", "appKeyAuth", "AuthZ"], + "endpoint_path": "/api/v2/replay/analysis/issues", + "operation_id": "list_replay_analysis_issues", + "http_method": "GET", + "version": "v2", + }, + params_map={ + "filter_application_id": { + "openapi_types": (str,), + "attribute": "filter[application_id]", + "location": "query", + }, + "filter_severity": { + "openapi_types": (str,), + "attribute": "filter[severity]", + "location": "query", + }, + "filter_view_name": { + "openapi_types": (str,), + "attribute": "filter[view_name]", + "location": "query", + }, + "filter_issue_category": { + "openapi_types": (str,), + "attribute": "filter[issue_category]", + "location": "query", + }, + "sort": { + "openapi_types": (str,), + "attribute": "sort", + "location": "query", + }, + "page_number": { + "validation": { + "inclusive_minimum": 0, + }, + "openapi_types": (int,), + "attribute": "page[number]", + "location": "query", + }, + "page_size": { + "validation": { + "inclusive_maximum": 100, + "inclusive_minimum": 1, + }, + "openapi_types": (int,), + "attribute": "page[size]", + "location": "query", + }, + }, + headers_map={ + "accept": ["application/json"], + }, + api_client=api_client, + ) + + self._list_replay_analysis_issue_sessions_endpoint = _Endpoint( + settings={ + "response_type": (ReplayAnalysisIssueSessionsResponse,), + "auth": ["apiKeyAuth", "appKeyAuth", "AuthZ"], + "endpoint_path": "/api/v2/replay/analysis/issues/{issue_id}/sessions", + "operation_id": "list_replay_analysis_issue_sessions", + "http_method": "GET", + "version": "v2", + }, + params_map={ + "issue_id": { + "required": True, + "openapi_types": (str,), + "attribute": "issue_id", + "location": "path", + }, + "sort": { + "openapi_types": (str,), + "attribute": "sort", + "location": "query", + }, + "page_number": { + "validation": { + "inclusive_minimum": 0, + }, + "openapi_types": (int,), + "attribute": "page[number]", + "location": "query", + }, + "page_size": { + "validation": { + "inclusive_maximum": 100, + "inclusive_minimum": 1, + }, + "openapi_types": (int,), + "attribute": "page[size]", + "location": "query", + }, + }, + headers_map={ + "accept": ["application/json"], + }, + api_client=api_client, + ) + + def get_replay_analysis_issue( + self, + issue_id: str, + ) -> ReplayAnalysisIssueResponse: + """Get replay analysis issue. + + Retrieve details of a specific RUM replay analysis issue by its identifier. + + :param issue_id: Unique identifier of the issue. + :type issue_id: str + :rtype: ReplayAnalysisIssueResponse + """ + kwargs: Dict[str, Any] = {} + kwargs["issue_id"] = issue_id + + return self._get_replay_analysis_issue_endpoint.call_with_http_info(**kwargs) + + def list_replay_analysis_issues( + self, + *, + filter_application_id: Union[str, UnsetType] = unset, + filter_severity: Union[str, UnsetType] = unset, + filter_view_name: Union[str, UnsetType] = unset, + filter_issue_category: Union[str, UnsetType] = unset, + sort: Union[str, UnsetType] = unset, + page_number: Union[int, UnsetType] = unset, + page_size: Union[int, UnsetType] = unset, + ) -> ReplayAnalysisIssuesResponse: + """List replay analysis issues. + + Retrieve a paginated list of RUM replay analysis issues, optionally filtered by application, severity, view name, or issue category. + + :param filter_application_id: Filter issues by application UUID. + :type filter_application_id: str, optional + :param filter_severity: Filter issues by comma-separated severity values. Valid values are ``high`` , ``medium`` , and ``low``. + :type filter_severity: str, optional + :param filter_view_name: Filter issues by comma-separated view names. + :type filter_view_name: str, optional + :param filter_issue_category: Filter issues by comma-separated issue categories. + :type filter_issue_category: str, optional + :param sort: Sort order for the results. Valid values are ``created_at`` , ``-created_at`` , ``severity`` , ``-severity`` , ``session_count`` , and ``-session_count``. Defaults to ``-created_at``. + :type sort: str, optional + :param page_number: Page number for pagination (0-indexed). + :type page_number: int, optional + :param page_size: Number of items per page. Must be between 1 and 100. + :type page_size: int, optional + :rtype: ReplayAnalysisIssuesResponse + """ + kwargs: Dict[str, Any] = {} + if filter_application_id is not unset: + kwargs["filter_application_id"] = filter_application_id + + if filter_severity is not unset: + kwargs["filter_severity"] = filter_severity + + if filter_view_name is not unset: + kwargs["filter_view_name"] = filter_view_name + + if filter_issue_category is not unset: + kwargs["filter_issue_category"] = filter_issue_category + + if sort is not unset: + kwargs["sort"] = sort + + if page_number is not unset: + kwargs["page_number"] = page_number + + if page_size is not unset: + kwargs["page_size"] = page_size + + return self._list_replay_analysis_issues_endpoint.call_with_http_info(**kwargs) + + def list_replay_analysis_issue_sessions( + self, + issue_id: str, + *, + sort: Union[str, UnsetType] = unset, + page_number: Union[int, UnsetType] = unset, + page_size: Union[int, UnsetType] = unset, + ) -> ReplayAnalysisIssueSessionsResponse: + """List replay analysis issue sessions. + + Retrieve a paginated list of sessions related to a specific RUM replay analysis issue. + + :param issue_id: Unique identifier of the issue. + :type issue_id: str + :param sort: Sort order for the results. Valid values are ``last_seen_at`` , ``-last_seen_at`` , ``proximity`` , and ``-proximity``. Defaults to ``-last_seen_at``. + :type sort: str, optional + :param page_number: Page number for pagination (0-indexed). + :type page_number: int, optional + :param page_size: Number of items per page. Must be between 1 and 100. + :type page_size: int, optional + :rtype: ReplayAnalysisIssueSessionsResponse + """ + kwargs: Dict[str, Any] = {} + kwargs["issue_id"] = issue_id + + if sort is not unset: + kwargs["sort"] = sort + + if page_number is not unset: + kwargs["page_number"] = page_number + + if page_size is not unset: + kwargs["page_size"] = page_size + + return self._list_replay_analysis_issue_sessions_endpoint.call_with_http_info(**kwargs) diff --git a/src/datadog_api_client/v2/api/rum_replay_api.py b/src/datadog_api_client/v2/api/rum_replay_api.py new file mode 100644 index 0000000000..911884c905 --- /dev/null +++ b/src/datadog_api_client/v2/api/rum_replay_api.py @@ -0,0 +1,96 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import Any, Dict, Union + +from datadog_api_client.api_client import ApiClient, Endpoint as _Endpoint +from datadog_api_client.configuration import Configuration +from datadog_api_client.model_utils import ( + UnsetType, + unset, +) +from datadog_api_client.v2.model.replay_summary_response import ReplaySummaryResponse +from datadog_api_client.v2.model.replay_summary_request import ReplaySummaryRequest + + +class RumReplayApi: + """ + Generate and retrieve AI-powered summaries of RUM replay sessions. + """ + + def __init__(self, api_client=None): + if api_client is None: + api_client = ApiClient(Configuration()) + self.api_client = api_client + + self._generate_replay_summary_endpoint = _Endpoint( + settings={ + "response_type": (ReplaySummaryResponse,), + "auth": ["apiKeyAuth", "appKeyAuth", "AuthZ"], + "endpoint_path": "/api/v2/replay/summary/{session_id}", + "operation_id": "generate_replay_summary", + "http_method": "POST", + "version": "v2", + }, + params_map={ + "session_id": { + "required": True, + "openapi_types": (str,), + "attribute": "session_id", + "location": "path", + }, + "data_source": { + "required": True, + "openapi_types": (str,), + "attribute": "data_source", + "location": "query", + }, + "ts": { + "openapi_types": (int,), + "attribute": "ts", + "location": "query", + }, + "body": { + "required": True, + "openapi_types": (ReplaySummaryRequest,), + "location": "body", + }, + }, + headers_map={"accept": ["application/json"], "content_type": ["application/json"]}, + api_client=api_client, + ) + + def generate_replay_summary( + self, + session_id: str, + data_source: str, + body: ReplaySummaryRequest, + *, + ts: Union[int, UnsetType] = unset, + ) -> ReplaySummaryResponse: + """Generate replay summary. + + Generate an AI-powered summary for a RUM replay session, including chapter breakdowns and behavioral analysis. + + :param session_id: Unique identifier of the session. + :type session_id: str + :param data_source: Data source for the session. Valid values are ``rum`` , ``product_analytics`` , and ``replay``. + :type data_source: str + :type body: ReplaySummaryRequest + :param ts: Server-side timestamp in milliseconds. + :type ts: int, optional + :rtype: ReplaySummaryResponse + """ + kwargs: Dict[str, Any] = {} + kwargs["session_id"] = session_id + + kwargs["data_source"] = data_source + + if ts is not unset: + kwargs["ts"] = ts + + kwargs["body"] = body + + return self._generate_replay_summary_endpoint.call_with_http_info(**kwargs) diff --git a/src/datadog_api_client/v2/apis/__init__.py b/src/datadog_api_client/v2/apis/__init__.py index 4a24c3b8d3..70fa99ef05 100644 --- a/src/datadog_api_client/v2/apis/__init__.py +++ b/src/datadog_api_client/v2/apis/__init__.py @@ -82,6 +82,8 @@ from datadog_api_client.v2.api.roles_api import RolesApi from datadog_api_client.v2.api.rum_audience_management_api import RumAudienceManagementApi from datadog_api_client.v2.api.rum_metrics_api import RumMetricsApi +from datadog_api_client.v2.api.rum_replay_api import RumReplayApi +from datadog_api_client.v2.api.rum_replay_analysis_api import RumReplayAnalysisApi from datadog_api_client.v2.api.rum_replay_heatmaps_api import RumReplayHeatmapsApi from datadog_api_client.v2.api.rum_replay_playlists_api import RumReplayPlaylistsApi from datadog_api_client.v2.api.rum_replay_sessions_api import RumReplaySessionsApi @@ -195,6 +197,8 @@ "RolesApi", "RumAudienceManagementApi", "RumMetricsApi", + "RumReplayApi", + "RumReplayAnalysisApi", "RumReplayHeatmapsApi", "RumReplayPlaylistsApi", "RumReplaySessionsApi", diff --git a/src/datadog_api_client/v2/model/replay_analysis_affected_session.py b/src/datadog_api_client/v2/model/replay_analysis_affected_session.py new file mode 100644 index 0000000000..b8e0c2c51f --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_affected_session.py @@ -0,0 +1,46 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import Union + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + none_type, + unset, + UnsetType, +) + + +class ReplayAnalysisAffectedSession(ModelNormal): + @cached_property + def openapi_types(_): + return { + "session_id": (str,), + "session_start_timestamp_ms": (int, none_type), + } + + attribute_map = { + "session_id": "session_id", + "session_start_timestamp_ms": "session_start_timestamp_ms", + } + + def __init__( + self_, session_id: str, session_start_timestamp_ms: Union[int, none_type, UnsetType] = unset, **kwargs + ): + """ + A session affected by a replay analysis issue. + + :param session_id: Unique identifier of the affected session. + :type session_id: str + + :param session_start_timestamp_ms: Session start timestamp in milliseconds. + :type session_start_timestamp_ms: int, none_type, optional + """ + if session_start_timestamp_ms is not unset: + kwargs["session_start_timestamp_ms"] = session_start_timestamp_ms + super().__init__(kwargs) + + self_.session_id = session_id diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_data.py b/src/datadog_api_client/v2/model/replay_analysis_issue_data.py new file mode 100644 index 0000000000..304ba9e074 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_data.py @@ -0,0 +1,56 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_issue_data_attributes import ReplayAnalysisIssueDataAttributes + from datadog_api_client.v2.model.replay_analysis_issue_data_type import ReplayAnalysisIssueDataType + + +class ReplayAnalysisIssueData(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_issue_data_attributes import ReplayAnalysisIssueDataAttributes + from datadog_api_client.v2.model.replay_analysis_issue_data_type import ReplayAnalysisIssueDataType + + return { + "attributes": (ReplayAnalysisIssueDataAttributes,), + "id": (str,), + "type": (ReplayAnalysisIssueDataType,), + } + + attribute_map = { + "attributes": "attributes", + "id": "id", + "type": "type", + } + + def __init__( + self_, attributes: ReplayAnalysisIssueDataAttributes, id: str, type: ReplayAnalysisIssueDataType, **kwargs + ): + """ + Data object representing a RUM replay analysis issue. + + :param attributes: Attributes of a RUM replay analysis issue. + :type attributes: ReplayAnalysisIssueDataAttributes + + :param id: Unique identifier of the issue. + :type id: str + + :param type: RUM replay analysis issue resource type. + :type type: ReplayAnalysisIssueDataType + """ + super().__init__(kwargs) + + self_.attributes = attributes + self_.id = id + self_.type = type diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_data_attributes.py b/src/datadog_api_client/v2/model/replay_analysis_issue_data_attributes.py new file mode 100644 index 0000000000..e2a76e6576 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_data_attributes.py @@ -0,0 +1,141 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import Any, Dict, List, Union, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + date, + datetime, + none_type, + unset, + UnsetType, + UUID, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_affected_session import ReplayAnalysisAffectedSession + from datadog_api_client.v2.model.replay_analysis_representative_session import ReplayAnalysisRepresentativeSession + + +class ReplayAnalysisIssueDataAttributes(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_affected_session import ReplayAnalysisAffectedSession + from datadog_api_client.v2.model.replay_analysis_representative_session import ( + ReplayAnalysisRepresentativeSession, + ) + + return { + "affected_sessions": ([ReplayAnalysisAffectedSession],), + "application_id": (str,), + "created_at": (datetime,), + "description": (str,), + "journey_query": ( + { + str: ( + bool, + date, + datetime, + dict, + float, + int, + list, + str, + UUID, + none_type, + ) + }, + none_type, + ), + "name": (str,), + "representative_session": (ReplayAnalysisRepresentativeSession,), + "session_count": (int,), + "severity": (str,), + "updated_at": (datetime,), + "validation_verdict": (str,), + } + + attribute_map = { + "affected_sessions": "affected_sessions", + "application_id": "application_id", + "created_at": "created_at", + "description": "description", + "journey_query": "journey_query", + "name": "name", + "representative_session": "representative_session", + "session_count": "session_count", + "severity": "severity", + "updated_at": "updated_at", + "validation_verdict": "validation_verdict", + } + + def __init__( + self_, + affected_sessions: List[ReplayAnalysisAffectedSession], + application_id: str, + created_at: datetime, + description: str, + name: str, + representative_session: ReplayAnalysisRepresentativeSession, + session_count: int, + severity: str, + updated_at: datetime, + validation_verdict: str, + journey_query: Union[Dict[str, Any], none_type, UnsetType] = unset, + **kwargs, + ): + """ + Attributes of a RUM replay analysis issue. + + :param affected_sessions: Up to three sample sessions affected by this issue. + :type affected_sessions: [ReplayAnalysisAffectedSession] + + :param application_id: Unique identifier of the application where the issue was detected. + :type application_id: str + + :param created_at: Timestamp when the issue was first detected. + :type created_at: datetime + + :param description: Human-readable description of the issue. + :type description: str + + :param journey_query: Journey query associated with the issue. + :type journey_query: {str: (bool, date, datetime, dict, float, int, list, str, UUID, none_type,)}, none_type, optional + + :param name: Name of the issue. + :type name: str + + :param representative_session: A representative session illustrating a replay analysis issue. + :type representative_session: ReplayAnalysisRepresentativeSession + + :param session_count: Total number of sessions affected by this issue. + :type session_count: int + + :param severity: Severity level of the issue. Valid values are ``high`` , ``medium`` , and ``low``. + :type severity: str + + :param updated_at: Timestamp when the issue was last updated. + :type updated_at: datetime + + :param validation_verdict: Validation status of the issue. + :type validation_verdict: str + """ + if journey_query is not unset: + kwargs["journey_query"] = journey_query + super().__init__(kwargs) + + self_.affected_sessions = affected_sessions + self_.application_id = application_id + self_.created_at = created_at + self_.description = description + self_.name = name + self_.representative_session = representative_session + self_.session_count = session_count + self_.severity = severity + self_.updated_at = updated_at + self_.validation_verdict = validation_verdict diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_data_type.py b/src/datadog_api_client/v2/model/replay_analysis_issue_data_type.py new file mode 100644 index 0000000000..ecdb2bb391 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_data_type.py @@ -0,0 +1,35 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelSimple, + cached_property, +) + +from typing import ClassVar + + +class ReplayAnalysisIssueDataType(ModelSimple): + """ + RUM replay analysis issue resource type. + + :param value: If omitted defaults to "issues". Must be one of ["issues"]. + :type value: str + """ + + allowed_values = { + "issues", + } + ISSUES: ClassVar["ReplayAnalysisIssueDataType"] + + @cached_property + def openapi_types(_): + return { + "value": (str,), + } + + +ReplayAnalysisIssueDataType.ISSUES = ReplayAnalysisIssueDataType("issues") diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_meta.py b/src/datadog_api_client/v2/model/replay_analysis_issue_meta.py new file mode 100644 index 0000000000..36a8341924 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_meta.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_page_meta import ReplayAnalysisPageMeta + + +class ReplayAnalysisIssueMeta(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_page_meta import ReplayAnalysisPageMeta + + return { + "page": (ReplayAnalysisPageMeta,), + } + + attribute_map = { + "page": "page", + } + + def __init__(self_, page: ReplayAnalysisPageMeta, **kwargs): + """ + Metadata object for paginated issue list responses. + + :param page: Pagination metadata for a RUM replay analysis response. + :type page: ReplayAnalysisPageMeta + """ + super().__init__(kwargs) + + self_.page = page diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_response.py b/src/datadog_api_client/v2/model/replay_analysis_issue_response.py new file mode 100644 index 0000000000..186521efc4 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_response.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_issue_data import ReplayAnalysisIssueData + + +class ReplayAnalysisIssueResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_issue_data import ReplayAnalysisIssueData + + return { + "data": (ReplayAnalysisIssueData,), + } + + attribute_map = { + "data": "data", + } + + def __init__(self_, data: ReplayAnalysisIssueData, **kwargs): + """ + A single RUM replay analysis issue. + + :param data: Data object representing a RUM replay analysis issue. + :type data: ReplayAnalysisIssueData + """ + super().__init__(kwargs) + + self_.data = data diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_session_data.py b/src/datadog_api_client/v2/model/replay_analysis_issue_session_data.py new file mode 100644 index 0000000000..6902432f42 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_session_data.py @@ -0,0 +1,66 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_issue_session_data_attributes import ( + ReplayAnalysisIssueSessionDataAttributes, + ) + from datadog_api_client.v2.model.replay_analysis_issue_session_data_type import ReplayAnalysisIssueSessionDataType + + +class ReplayAnalysisIssueSessionData(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_issue_session_data_attributes import ( + ReplayAnalysisIssueSessionDataAttributes, + ) + from datadog_api_client.v2.model.replay_analysis_issue_session_data_type import ( + ReplayAnalysisIssueSessionDataType, + ) + + return { + "attributes": (ReplayAnalysisIssueSessionDataAttributes,), + "id": (str,), + "type": (ReplayAnalysisIssueSessionDataType,), + } + + attribute_map = { + "attributes": "attributes", + "id": "id", + "type": "type", + } + + def __init__( + self_, + attributes: ReplayAnalysisIssueSessionDataAttributes, + id: str, + type: ReplayAnalysisIssueSessionDataType, + **kwargs, + ): + """ + Data object representing a session related to a RUM replay analysis issue. + + :param attributes: Attributes of a session related to a RUM replay analysis issue. + :type attributes: ReplayAnalysisIssueSessionDataAttributes + + :param id: Unique identifier of the session. + :type id: str + + :param type: RUM replay analysis issue session resource type. + :type type: ReplayAnalysisIssueSessionDataType + """ + super().__init__(kwargs) + + self_.attributes = attributes + self_.id = id + self_.type = type diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_session_data_attributes.py b/src/datadog_api_client/v2/model/replay_analysis_issue_session_data_attributes.py new file mode 100644 index 0000000000..bb75abe815 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_session_data_attributes.py @@ -0,0 +1,52 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_signal import ReplayAnalysisSignal + + +class ReplayAnalysisIssueSessionDataAttributes(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_signal import ReplayAnalysisSignal + + return { + "session_start_timestamp_ms": (int,), + "signals": ([ReplayAnalysisSignal],), + "view_name": (str,), + } + + attribute_map = { + "session_start_timestamp_ms": "session_start_timestamp_ms", + "signals": "signals", + "view_name": "view_name", + } + + def __init__(self_, session_start_timestamp_ms: int, signals: List[ReplayAnalysisSignal], view_name: str, **kwargs): + """ + Attributes of a session related to a RUM replay analysis issue. + + :param session_start_timestamp_ms: Session start timestamp in milliseconds. + :type session_start_timestamp_ms: int + + :param signals: List of signals observed in this session. + :type signals: [ReplayAnalysisSignal] + + :param view_name: Name of the view where the issue was observed. + :type view_name: str + """ + super().__init__(kwargs) + + self_.session_start_timestamp_ms = session_start_timestamp_ms + self_.signals = signals + self_.view_name = view_name diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_session_data_type.py b/src/datadog_api_client/v2/model/replay_analysis_issue_session_data_type.py new file mode 100644 index 0000000000..2c44245eb6 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_session_data_type.py @@ -0,0 +1,35 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelSimple, + cached_property, +) + +from typing import ClassVar + + +class ReplayAnalysisIssueSessionDataType(ModelSimple): + """ + RUM replay analysis issue session resource type. + + :param value: If omitted defaults to "sessions". Must be one of ["sessions"]. + :type value: str + """ + + allowed_values = { + "sessions", + } + SESSIONS: ClassVar["ReplayAnalysisIssueSessionDataType"] + + @cached_property + def openapi_types(_): + return { + "value": (str,), + } + + +ReplayAnalysisIssueSessionDataType.SESSIONS = ReplayAnalysisIssueSessionDataType("sessions") diff --git a/src/datadog_api_client/v2/model/replay_analysis_issue_sessions_response.py b/src/datadog_api_client/v2/model/replay_analysis_issue_sessions_response.py new file mode 100644 index 0000000000..381b5c978d --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issue_sessions_response.py @@ -0,0 +1,48 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_issue_session_data import ReplayAnalysisIssueSessionData + from datadog_api_client.v2.model.replay_analysis_issue_meta import ReplayAnalysisIssueMeta + + +class ReplayAnalysisIssueSessionsResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_issue_session_data import ReplayAnalysisIssueSessionData + from datadog_api_client.v2.model.replay_analysis_issue_meta import ReplayAnalysisIssueMeta + + return { + "data": ([ReplayAnalysisIssueSessionData],), + "meta": (ReplayAnalysisIssueMeta,), + } + + attribute_map = { + "data": "data", + "meta": "meta", + } + + def __init__(self_, data: List[ReplayAnalysisIssueSessionData], meta: ReplayAnalysisIssueMeta, **kwargs): + """ + A paginated list of sessions related to a RUM replay analysis issue. + + :param data: Array of session data objects related to the issue. + :type data: [ReplayAnalysisIssueSessionData] + + :param meta: Metadata object for paginated issue list responses. + :type meta: ReplayAnalysisIssueMeta + """ + super().__init__(kwargs) + + self_.data = data + self_.meta = meta diff --git a/src/datadog_api_client/v2/model/replay_analysis_issues_response.py b/src/datadog_api_client/v2/model/replay_analysis_issues_response.py new file mode 100644 index 0000000000..25f3f091dd --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_issues_response.py @@ -0,0 +1,48 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_issue_data import ReplayAnalysisIssueData + from datadog_api_client.v2.model.replay_analysis_issue_meta import ReplayAnalysisIssueMeta + + +class ReplayAnalysisIssuesResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_issue_data import ReplayAnalysisIssueData + from datadog_api_client.v2.model.replay_analysis_issue_meta import ReplayAnalysisIssueMeta + + return { + "data": ([ReplayAnalysisIssueData],), + "meta": (ReplayAnalysisIssueMeta,), + } + + attribute_map = { + "data": "data", + "meta": "meta", + } + + def __init__(self_, data: List[ReplayAnalysisIssueData], meta: ReplayAnalysisIssueMeta, **kwargs): + """ + A paginated list of RUM replay analysis issues. + + :param data: Array of RUM replay analysis issue data objects. + :type data: [ReplayAnalysisIssueData] + + :param meta: Metadata object for paginated issue list responses. + :type meta: ReplayAnalysisIssueMeta + """ + super().__init__(kwargs) + + self_.data = data + self_.meta = meta diff --git a/src/datadog_api_client/v2/model/replay_analysis_llm_details.py b/src/datadog_api_client/v2/model/replay_analysis_llm_details.py new file mode 100644 index 0000000000..8b80e74771 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_llm_details.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +class ReplayAnalysisLLMDetails(ModelNormal): + @cached_property + def openapi_types(_): + return { + "intent": (str,), + "user_pattern": ([str],), + } + + attribute_map = { + "intent": "intent", + "user_pattern": "user_pattern", + } + + def __init__(self_, intent: str, user_pattern: List[str], **kwargs): + """ + AI-generated analysis details for a replay issue. + + :param intent: Interpreted user intent derived from session analysis. + :type intent: str + + :param user_pattern: List of user behavior steps observed in the session. + :type user_pattern: [str] + """ + super().__init__(kwargs) + + self_.intent = intent + self_.user_pattern = user_pattern diff --git a/src/datadog_api_client/v2/model/replay_analysis_page_meta.py b/src/datadog_api_client/v2/model/replay_analysis_page_meta.py new file mode 100644 index 0000000000..783ab8bea1 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_page_meta.py @@ -0,0 +1,33 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +class ReplayAnalysisPageMeta(ModelNormal): + @cached_property + def openapi_types(_): + return { + "total_filtered_count": (int,), + } + + attribute_map = { + "total_filtered_count": "total_filtered_count", + } + + def __init__(self_, total_filtered_count: int, **kwargs): + """ + Pagination metadata for a RUM replay analysis response. + + :param total_filtered_count: Total number of items matching the current filters. + :type total_filtered_count: int + """ + super().__init__(kwargs) + + self_.total_filtered_count = total_filtered_count diff --git a/src/datadog_api_client/v2/model/replay_analysis_representative_session.py b/src/datadog_api_client/v2/model/replay_analysis_representative_session.py new file mode 100644 index 0000000000..c8c75d7446 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_representative_session.py @@ -0,0 +1,95 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, Union, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + none_type, + unset, + UnsetType, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_analysis_llm_details import ReplayAnalysisLLMDetails + from datadog_api_client.v2.model.replay_analysis_screenshot import ReplayAnalysisScreenshot + from datadog_api_client.v2.model.replay_analysis_signal import ReplayAnalysisSignal + + +class ReplayAnalysisRepresentativeSession(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_analysis_llm_details import ReplayAnalysisLLMDetails + from datadog_api_client.v2.model.replay_analysis_screenshot import ReplayAnalysisScreenshot + from datadog_api_client.v2.model.replay_analysis_signal import ReplayAnalysisSignal + + return { + "issue_category": (str,), + "llm_analysis_details": (ReplayAnalysisLLMDetails,), + "screenshot": (ReplayAnalysisScreenshot,), + "session_id": (str,), + "session_start_timestamp_ms": (int,), + "signals": ([ReplayAnalysisSignal],), + "view_name": (str, none_type), + } + + attribute_map = { + "issue_category": "issue_category", + "llm_analysis_details": "llm_analysis_details", + "screenshot": "screenshot", + "session_id": "session_id", + "session_start_timestamp_ms": "session_start_timestamp_ms", + "signals": "signals", + "view_name": "view_name", + } + + def __init__( + self_, + issue_category: str, + llm_analysis_details: ReplayAnalysisLLMDetails, + session_id: str, + session_start_timestamp_ms: int, + signals: List[ReplayAnalysisSignal], + screenshot: Union[ReplayAnalysisScreenshot, UnsetType] = unset, + view_name: Union[str, none_type, UnsetType] = unset, + **kwargs, + ): + """ + A representative session illustrating a replay analysis issue. + + :param issue_category: Category of the issue observed in this session. + :type issue_category: str + + :param llm_analysis_details: AI-generated analysis details for a replay issue. + :type llm_analysis_details: ReplayAnalysisLLMDetails + + :param screenshot: A screenshot captured during a replay session. + :type screenshot: ReplayAnalysisScreenshot, optional + + :param session_id: Unique identifier of the representative session. + :type session_id: str + + :param session_start_timestamp_ms: Session start timestamp in milliseconds. + :type session_start_timestamp_ms: int + + :param signals: List of signals observed in the representative session. + :type signals: [ReplayAnalysisSignal] + + :param view_name: Name of the view where the issue was observed. + :type view_name: str, none_type, optional + """ + if screenshot is not unset: + kwargs["screenshot"] = screenshot + if view_name is not unset: + kwargs["view_name"] = view_name + super().__init__(kwargs) + + self_.issue_category = issue_category + self_.llm_analysis_details = llm_analysis_details + self_.session_id = session_id + self_.session_start_timestamp_ms = session_start_timestamp_ms + self_.signals = signals diff --git a/src/datadog_api_client/v2/model/replay_analysis_screenshot.py b/src/datadog_api_client/v2/model/replay_analysis_screenshot.py new file mode 100644 index 0000000000..4016738c55 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_screenshot.py @@ -0,0 +1,51 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +class ReplayAnalysisScreenshot(ModelNormal): + @cached_property + def openapi_types(_): + return { + "screenshot_key": (str,), + "session_id": (str,), + "timestamp_ms": (int,), + "view_id": (str,), + } + + attribute_map = { + "screenshot_key": "screenshot_key", + "session_id": "session_id", + "timestamp_ms": "timestamp_ms", + "view_id": "view_id", + } + + def __init__(self_, screenshot_key: str, session_id: str, timestamp_ms: int, view_id: str, **kwargs): + """ + A screenshot captured during a replay session. + + :param screenshot_key: Filename or key identifier of the screenshot. + :type screenshot_key: str + + :param session_id: Unique identifier of the session where the screenshot was taken. + :type session_id: str + + :param timestamp_ms: Timestamp of the screenshot in milliseconds. + :type timestamp_ms: int + + :param view_id: Unique identifier of the view where the screenshot was taken. + :type view_id: str + """ + super().__init__(kwargs) + + self_.screenshot_key = screenshot_key + self_.session_id = session_id + self_.timestamp_ms = timestamp_ms + self_.view_id = view_id diff --git a/src/datadog_api_client/v2/model/replay_analysis_signal.py b/src/datadog_api_client/v2/model/replay_analysis_signal.py new file mode 100644 index 0000000000..d8cdc06762 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_analysis_signal.py @@ -0,0 +1,51 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +class ReplayAnalysisSignal(ModelNormal): + @cached_property + def openapi_types(_): + return { + "event": (str,), + "signal_type": (str,), + "timestamp_ms": (int,), + "user_pattern": (str,), + } + + attribute_map = { + "event": "event", + "signal_type": "signal_type", + "timestamp_ms": "timestamp_ms", + "user_pattern": "user_pattern", + } + + def __init__(self_, event: str, signal_type: str, timestamp_ms: int, user_pattern: str, **kwargs): + """ + A signal associated with a replay issue, capturing user interaction details. + + :param event: Event name associated with the signal. + :type event: str + + :param signal_type: Type of signal captured. + :type signal_type: str + + :param timestamp_ms: Absolute timestamp of the signal in milliseconds. + :type timestamp_ms: int + + :param user_pattern: User behavior pattern identified for the signal. + :type user_pattern: str + """ + super().__init__(kwargs) + + self_.event = event + self_.signal_type = signal_type + self_.timestamp_ms = timestamp_ms + self_.user_pattern = user_pattern diff --git a/src/datadog_api_client/v2/model/replay_summary_chapter.py b/src/datadog_api_client/v2/model/replay_summary_chapter.py new file mode 100644 index 0000000000..25dbc0d722 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_chapter.py @@ -0,0 +1,45 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +class ReplaySummaryChapter(ModelNormal): + @cached_property + def openapi_types(_): + return { + "end_ms": (int,), + "start_ms": (int,), + "text": (str,), + } + + attribute_map = { + "end_ms": "end_ms", + "start_ms": "start_ms", + "text": "text", + } + + def __init__(self_, end_ms: int, start_ms: int, text: str, **kwargs): + """ + A chapter within a RUM replay summary, representing a distinct segment of user activity. + + :param end_ms: End time of the chapter in milliseconds. + :type end_ms: int + + :param start_ms: Start time of the chapter in milliseconds. + :type start_ms: int + + :param text: Description of user activity during this chapter. + :type text: str + """ + super().__init__(kwargs) + + self_.end_ms = end_ms + self_.start_ms = start_ms + self_.text = text diff --git a/src/datadog_api_client/v2/model/replay_summary_data_attributes_response.py b/src/datadog_api_client/v2/model/replay_summary_data_attributes_response.py new file mode 100644 index 0000000000..0b8e43ce98 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_data_attributes_response.py @@ -0,0 +1,72 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_summary_chapter import ReplaySummaryChapter + + +class ReplaySummaryDataAttributesResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_summary_chapter import ReplaySummaryChapter + + return { + "chapters": ([ReplaySummaryChapter],), + "has_enough_activity": (bool,), + "has_too_many_events": (bool,), + "summary": (str,), + "version": (str,), + } + + attribute_map = { + "chapters": "chapters", + "has_enough_activity": "has_enough_activity", + "has_too_many_events": "has_too_many_events", + "summary": "summary", + "version": "version", + } + + def __init__( + self_, + chapters: List[ReplaySummaryChapter], + has_enough_activity: bool, + has_too_many_events: bool, + summary: str, + version: str, + **kwargs, + ): + """ + Attributes of a RUM replay summary response. + + :param chapters: List of chapters breaking down the session into distinct activity segments. + :type chapters: [ReplaySummaryChapter] + + :param has_enough_activity: Whether the session contained sufficient user activity to generate a summary. + :type has_enough_activity: bool + + :param has_too_many_events: Whether the session exceeded the event count limit for summary generation. + :type has_too_many_events: bool + + :param summary: AI-generated summary of the replay session. + :type summary: str + + :param version: Version of the prompt used to generate the summary. + :type version: str + """ + super().__init__(kwargs) + + self_.chapters = chapters + self_.has_enough_activity = has_enough_activity + self_.has_too_many_events = has_too_many_events + self_.summary = summary + self_.version = version diff --git a/src/datadog_api_client/v2/model/replay_summary_data_request.py b/src/datadog_api_client/v2/model/replay_summary_data_request.py new file mode 100644 index 0000000000..de32ae5f5b --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_data_request.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_summary_request_type import ReplaySummaryRequestType + + +class ReplaySummaryDataRequest(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_summary_request_type import ReplaySummaryRequestType + + return { + "type": (ReplaySummaryRequestType,), + } + + attribute_map = { + "type": "type", + } + + def __init__(self_, type: ReplaySummaryRequestType, **kwargs): + """ + Data object for a RUM replay summary request. + + :param type: RUM replay summary request resource type. + :type type: ReplaySummaryRequestType + """ + super().__init__(kwargs) + + self_.type = type diff --git a/src/datadog_api_client/v2/model/replay_summary_data_response.py b/src/datadog_api_client/v2/model/replay_summary_data_response.py new file mode 100644 index 0000000000..cb3c5256c3 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_data_response.py @@ -0,0 +1,58 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_summary_data_attributes_response import ReplaySummaryDataAttributesResponse + from datadog_api_client.v2.model.replay_summary_response_type import ReplaySummaryResponseType + + +class ReplaySummaryDataResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_summary_data_attributes_response import ( + ReplaySummaryDataAttributesResponse, + ) + from datadog_api_client.v2.model.replay_summary_response_type import ReplaySummaryResponseType + + return { + "attributes": (ReplaySummaryDataAttributesResponse,), + "id": (str,), + "type": (ReplaySummaryResponseType,), + } + + attribute_map = { + "attributes": "attributes", + "id": "id", + "type": "type", + } + + def __init__( + self_, attributes: ReplaySummaryDataAttributesResponse, id: str, type: ReplaySummaryResponseType, **kwargs + ): + """ + Data object for a RUM replay summary response. + + :param attributes: Attributes of a RUM replay summary response. + :type attributes: ReplaySummaryDataAttributesResponse + + :param id: Unique identifier of the generated summary. + :type id: str + + :param type: RUM replay summary response resource type. + :type type: ReplaySummaryResponseType + """ + super().__init__(kwargs) + + self_.attributes = attributes + self_.id = id + self_.type = type diff --git a/src/datadog_api_client/v2/model/replay_summary_request.py b/src/datadog_api_client/v2/model/replay_summary_request.py new file mode 100644 index 0000000000..c3a2be5ecc --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_request.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_summary_data_request import ReplaySummaryDataRequest + + +class ReplaySummaryRequest(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_summary_data_request import ReplaySummaryDataRequest + + return { + "data": (ReplaySummaryDataRequest,), + } + + attribute_map = { + "data": "data", + } + + def __init__(self_, data: ReplaySummaryDataRequest, **kwargs): + """ + Request body for generating a RUM replay summary. + + :param data: Data object for a RUM replay summary request. + :type data: ReplaySummaryDataRequest + """ + super().__init__(kwargs) + + self_.data = data diff --git a/src/datadog_api_client/v2/model/replay_summary_request_type.py b/src/datadog_api_client/v2/model/replay_summary_request_type.py new file mode 100644 index 0000000000..a8ea8e9b68 --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_request_type.py @@ -0,0 +1,35 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelSimple, + cached_property, +) + +from typing import ClassVar + + +class ReplaySummaryRequestType(ModelSimple): + """ + RUM replay summary request resource type. + + :param value: If omitted defaults to "replay_summary_request". Must be one of ["replay_summary_request"]. + :type value: str + """ + + allowed_values = { + "replay_summary_request", + } + REPLAY_SUMMARY_REQUEST: ClassVar["ReplaySummaryRequestType"] + + @cached_property + def openapi_types(_): + return { + "value": (str,), + } + + +ReplaySummaryRequestType.REPLAY_SUMMARY_REQUEST = ReplaySummaryRequestType("replay_summary_request") diff --git a/src/datadog_api_client/v2/model/replay_summary_response.py b/src/datadog_api_client/v2/model/replay_summary_response.py new file mode 100644 index 0000000000..d70709335b --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_response.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.replay_summary_data_response import ReplaySummaryDataResponse + + +class ReplaySummaryResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.replay_summary_data_response import ReplaySummaryDataResponse + + return { + "data": (ReplaySummaryDataResponse,), + } + + attribute_map = { + "data": "data", + } + + def __init__(self_, data: ReplaySummaryDataResponse, **kwargs): + """ + Response containing a generated RUM replay summary. + + :param data: Data object for a RUM replay summary response. + :type data: ReplaySummaryDataResponse + """ + super().__init__(kwargs) + + self_.data = data diff --git a/src/datadog_api_client/v2/model/replay_summary_response_type.py b/src/datadog_api_client/v2/model/replay_summary_response_type.py new file mode 100644 index 0000000000..97175a376f --- /dev/null +++ b/src/datadog_api_client/v2/model/replay_summary_response_type.py @@ -0,0 +1,35 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelSimple, + cached_property, +) + +from typing import ClassVar + + +class ReplaySummaryResponseType(ModelSimple): + """ + RUM replay summary response resource type. + + :param value: If omitted defaults to "summary_response". Must be one of ["summary_response"]. + :type value: str + """ + + allowed_values = { + "summary_response", + } + SUMMARY_RESPONSE: ClassVar["ReplaySummaryResponseType"] + + @cached_property + def openapi_types(_): + return { + "value": (str,), + } + + +ReplaySummaryResponseType.SUMMARY_RESPONSE = ReplaySummaryResponseType("summary_response") diff --git a/src/datadog_api_client/v2/models/__init__.py b/src/datadog_api_client/v2/models/__init__.py index 05eb4d066a..772630543d 100644 --- a/src/datadog_api_client/v2/models/__init__.py +++ b/src/datadog_api_client/v2/models/__init__.py @@ -5256,6 +5256,32 @@ from datadog_api_client.v2.model.reorder_ruleset_resource_array import ReorderRulesetResourceArray from datadog_api_client.v2.model.reorder_ruleset_resource_data import ReorderRulesetResourceData from datadog_api_client.v2.model.reorder_ruleset_resource_data_type import ReorderRulesetResourceDataType +from datadog_api_client.v2.model.replay_analysis_affected_session import ReplayAnalysisAffectedSession +from datadog_api_client.v2.model.replay_analysis_issue_data import ReplayAnalysisIssueData +from datadog_api_client.v2.model.replay_analysis_issue_data_attributes import ReplayAnalysisIssueDataAttributes +from datadog_api_client.v2.model.replay_analysis_issue_data_type import ReplayAnalysisIssueDataType +from datadog_api_client.v2.model.replay_analysis_issue_meta import ReplayAnalysisIssueMeta +from datadog_api_client.v2.model.replay_analysis_issue_response import ReplayAnalysisIssueResponse +from datadog_api_client.v2.model.replay_analysis_issue_session_data import ReplayAnalysisIssueSessionData +from datadog_api_client.v2.model.replay_analysis_issue_session_data_attributes import ( + ReplayAnalysisIssueSessionDataAttributes, +) +from datadog_api_client.v2.model.replay_analysis_issue_session_data_type import ReplayAnalysisIssueSessionDataType +from datadog_api_client.v2.model.replay_analysis_issue_sessions_response import ReplayAnalysisIssueSessionsResponse +from datadog_api_client.v2.model.replay_analysis_issues_response import ReplayAnalysisIssuesResponse +from datadog_api_client.v2.model.replay_analysis_llm_details import ReplayAnalysisLLMDetails +from datadog_api_client.v2.model.replay_analysis_page_meta import ReplayAnalysisPageMeta +from datadog_api_client.v2.model.replay_analysis_representative_session import ReplayAnalysisRepresentativeSession +from datadog_api_client.v2.model.replay_analysis_screenshot import ReplayAnalysisScreenshot +from datadog_api_client.v2.model.replay_analysis_signal import ReplayAnalysisSignal +from datadog_api_client.v2.model.replay_summary_chapter import ReplaySummaryChapter +from datadog_api_client.v2.model.replay_summary_data_attributes_response import ReplaySummaryDataAttributesResponse +from datadog_api_client.v2.model.replay_summary_data_request import ReplaySummaryDataRequest +from datadog_api_client.v2.model.replay_summary_data_response import ReplaySummaryDataResponse +from datadog_api_client.v2.model.replay_summary_request import ReplaySummaryRequest +from datadog_api_client.v2.model.replay_summary_request_type import ReplaySummaryRequestType +from datadog_api_client.v2.model.replay_summary_response import ReplaySummaryResponse +from datadog_api_client.v2.model.replay_summary_response_type import ReplaySummaryResponseType from datadog_api_client.v2.model.resolve_vulnerable_symbols_request import ResolveVulnerableSymbolsRequest from datadog_api_client.v2.model.resolve_vulnerable_symbols_request_data import ResolveVulnerableSymbolsRequestData from datadog_api_client.v2.model.resolve_vulnerable_symbols_request_data_attributes import ( @@ -11221,6 +11247,30 @@ "ReorderRulesetResourceArray", "ReorderRulesetResourceData", "ReorderRulesetResourceDataType", + "ReplayAnalysisAffectedSession", + "ReplayAnalysisIssueData", + "ReplayAnalysisIssueDataAttributes", + "ReplayAnalysisIssueDataType", + "ReplayAnalysisIssueMeta", + "ReplayAnalysisIssueResponse", + "ReplayAnalysisIssueSessionData", + "ReplayAnalysisIssueSessionDataAttributes", + "ReplayAnalysisIssueSessionDataType", + "ReplayAnalysisIssueSessionsResponse", + "ReplayAnalysisIssuesResponse", + "ReplayAnalysisLLMDetails", + "ReplayAnalysisPageMeta", + "ReplayAnalysisRepresentativeSession", + "ReplayAnalysisScreenshot", + "ReplayAnalysisSignal", + "ReplaySummaryChapter", + "ReplaySummaryDataAttributesResponse", + "ReplaySummaryDataRequest", + "ReplaySummaryDataResponse", + "ReplaySummaryRequest", + "ReplaySummaryRequestType", + "ReplaySummaryResponse", + "ReplaySummaryResponseType", "ResolveVulnerableSymbolsRequest", "ResolveVulnerableSymbolsRequestData", "ResolveVulnerableSymbolsRequestDataAttributes", diff --git a/tests/v2/features/rum_replay.feature b/tests/v2/features/rum_replay.feature new file mode 100644 index 0000000000..f051e15370 --- /dev/null +++ b/tests/v2/features/rum_replay.feature @@ -0,0 +1,32 @@ +@endpoint(rum-replay) @endpoint(rum-replay-v2) +Feature: Rum Replay + Generate and retrieve AI-powered summaries of RUM replay sessions. + + Background: + Given a valid "apiKeyAuth" key in the system + And a valid "appKeyAuth" key in the system + And an instance of "RumReplay" API + And operation "GenerateReplaySummary" enabled + And new "GenerateReplaySummary" request + And body with value {"data": {"type": "replay_summary_request"}} + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: Generate replay summary returns "Bad Request" response + Given request contains "session_id" parameter from "REPLACE.ME" + And request contains "data_source" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: Generate replay summary returns "Not Found" response + Given request contains "session_id" parameter from "REPLACE.ME" + And request contains "data_source" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: Generate replay summary returns "OK" response + Given request contains "session_id" parameter from "REPLACE.ME" + And request contains "data_source" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK diff --git a/tests/v2/features/rum_replay_analysis.feature b/tests/v2/features/rum_replay_analysis.feature new file mode 100644 index 0000000000..e1556fcebf --- /dev/null +++ b/tests/v2/features/rum_replay_analysis.feature @@ -0,0 +1,72 @@ +@endpoint(rum-replay-analysis) @endpoint(rum-replay-analysis-v2) +Feature: Rum Replay Analysis + Analyze RUM replay sessions to identify and investigate user-facing + issues. Retrieve issues detected by AI analysis, get details for + individual issues, and explore the sessions associated with each issue. + + Background: + Given a valid "apiKeyAuth" key in the system + And a valid "appKeyAuth" key in the system + And an instance of "RumReplayAnalysis" API + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: Get replay analysis issue returns "Bad Request" response + Given operation "GetReplayAnalysisIssue" enabled + And new "GetReplayAnalysisIssue" request + And request contains "issue_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: Get replay analysis issue returns "Not Found" response + Given operation "GetReplayAnalysisIssue" enabled + And new "GetReplayAnalysisIssue" request + And request contains "issue_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: Get replay analysis issue returns "OK" response + Given operation "GetReplayAnalysisIssue" enabled + And new "GetReplayAnalysisIssue" request + And request contains "issue_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: List replay analysis issue sessions returns "Bad Request" response + Given operation "ListReplayAnalysisIssueSessions" enabled + And new "ListReplayAnalysisIssueSessions" request + And request contains "issue_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: List replay analysis issue sessions returns "Not Found" response + Given operation "ListReplayAnalysisIssueSessions" enabled + And new "ListReplayAnalysisIssueSessions" request + And request contains "issue_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: List replay analysis issue sessions returns "OK" response + Given operation "ListReplayAnalysisIssueSessions" enabled + And new "ListReplayAnalysisIssueSessions" request + And request contains "issue_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: List replay analysis issues returns "Bad Request" response + Given operation "ListReplayAnalysisIssues" enabled + And new "ListReplayAnalysisIssues" request + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/product-analytics-backend @team:DataDog/rum-backend @team:DataDog/session-replay-backend + Scenario: List replay analysis issues returns "OK" response + Given operation "ListReplayAnalysisIssues" enabled + And new "ListReplayAnalysisIssues" request + When the request is sent + Then the response status is 200 OK diff --git a/tests/v2/features/undo.json b/tests/v2/features/undo.json index 96d9f3eb5d..2732c40dfb 100644 --- a/tests/v2/features/undo.json +++ b/tests/v2/features/undo.json @@ -4792,6 +4792,24 @@ "type": "idempotent" } }, + "ListReplayAnalysisIssues": { + "tag": "Rum Replay Analysis", + "undo": { + "type": "safe" + } + }, + "GetReplayAnalysisIssue": { + "tag": "Rum Replay Analysis", + "undo": { + "type": "safe" + } + }, + "ListReplayAnalysisIssueSessions": { + "tag": "Rum Replay Analysis", + "undo": { + "type": "safe" + } + }, "ListReplayHeatmapSnapshots": { "tag": "Rum Replay Heatmaps", "undo": { @@ -4823,6 +4841,12 @@ "type": "idempotent" } }, + "GenerateReplaySummary": { + "tag": "Rum Replay", + "undo": { + "type": "idempotent" + } + }, "DeleteRestrictionPolicy": { "tag": "Restriction Policies", "undo": {