From a58f9fa86dceb56210ed1ad7ac1b5ce97135b66a Mon Sep 17 00:00:00 2001 From: Adam E <159158755+adam-saucelabs@users.noreply.github.com> Date: Mon, 25 Nov 2024 08:39:49 -0600 Subject: [PATCH 1/3] Update insights endpoints to clarify optional/required params adding note to two endpoints that did not have information about XOR on start/end or time_range --- docs/dev/api/insights.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/dev/api/insights.md b/docs/dev/api/insights.md index 67d624d925..0062f1c456 100644 --- a/docs/dev/api/insights.md +++ b/docs/dev/api/insights.md @@ -24,6 +24,10 @@ Return run data for all tests that match the request criteria. #### Parameters +:::note +This call requires start and end parameters OR the time_range parameter. +::: + @@ -412,6 +416,10 @@ Return a set of data "buckets" representing tests that were run in each time int #### Parameters +:::note +This call requires start and end parameters OR the time_range parameter. +::: +
From de3a004e46386af7fb7358ae8269d962ee75299b Mon Sep 17 00:00:00 2001 From: Adam E <159158755+adam-saucelabs@users.noreply.github.com> Date: Mon, 25 Nov 2024 10:08:13 -0600 Subject: [PATCH 2/3] start/end/time_range consistency updates updating copy for start/end/time_range and parameter sorting for - /v1/analytics/tests - /v1/analytics/insights/test-metrics - /v1/analytics/trends/tests - /v1/analytics/trends/builds_tests --- docs/dev/api/insights.md | 75 +++++++++++++++++++--------------------- 1 file changed, 36 insertions(+), 39 deletions(-) diff --git a/docs/dev/api/insights.md b/docs/dev/api/insights.md index 0062f1c456..9727a49997 100644 --- a/docs/dev/api/insights.md +++ b/docs/dev/api/insights.md @@ -29,6 +29,24 @@ This call requires start and end parameters OR the + + + + + + + + + + + + + + + + + + @@ -47,12 +65,6 @@ This call requires start and end parameters OR the

| QUERY | OPTIONAL | BOOLEAN |

Sort results by test creation time. Default value is true.

- - - - - - @@ -99,12 +111,6 @@ This call requires start and end parameters OR the

| QUERY | OPTIONAL | INTEGER |

The maximum number of results to return. Default value is 10

- - - - - - @@ -122,15 +128,6 @@ This call requires start and end parameters OR the - - - - - -
start

| QUERY | REQUIRED | DATE |

The starting date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

end

| QUERY | REQUIRED | DATE |

The ending date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

time_range

| QUERY | REQUIRED | DURATION + UNIT |

The amount of time backward from the current time that represents the period during which the test runs are executed. Acceptable units include d (day); h (hour); m (minute); s (second).

build
end

| QUERY | OPTIONAL | DATE |

The ending date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

error
start

| QUERY | OPTIONAL | DATE |

The starting date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

status
time_range -

| QUERY | OPTIONAL | STRING |

-

The amount of time backward from the current time that represents the period during which the test runs are executed. Acceptable units include d (day); h (hour); m (minute); s (second).

-
start and end parameters OR the + + + start +

| QUERY | REQUIRED | DATE |

The starting date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

+ + + + + end +

| QUERY | REQUIRED | DATE |

The ending date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

+ + + + + time_range +

| QUERY | REQUIRED | DURATION + UNIT |

The amount of time backward from the current time that represents the period during which the test runs are executed. Acceptable units include d (day); h (hour); m (minute); s (second).

+ + scope @@ -446,24 +461,6 @@ This call requires start and end parameters OR the - - - time_range -

| QUERY | OPTIONAL | STRING |

The amount of time backward from the current time that represents the period during which the test runs are executed. Acceptable units include d (day); h (hour); m (minute); s (second).

- - - - - start -

| QUERY | OPTIONAL | DATE |

The starting date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

- - - - - end -

| QUERY | OPTIONAL | DATE |

The ending date of the period during which the test runs executed, in YYYY-MM-DDTHH:mm:ssZ (UTC) format.

- - browser From 8df24ba118cc43b51478c39f57e918519fe7352b Mon Sep 17 00:00:00 2001 From: Adam E <159158755+adam-saucelabs@users.noreply.github.com> Date: Mon, 25 Nov 2024 10:15:54 -0600 Subject: [PATCH 3/3] update interval parameter for all endpoints --- docs/dev/api/insights.md | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/docs/dev/api/insights.md b/docs/dev/api/insights.md index 9727a49997..0495d94207 100644 --- a/docs/dev/api/insights.md +++ b/docs/dev/api/insights.md @@ -457,7 +457,7 @@ This call requires start and end parameters OR the interval

| QUERY | OPTIONAL | STRING |

-

Relative date filter. Available values are:

  • 1m (1 month)
  • 15m (15 months)
  • 1h (1 hour)
  • 6h (6 hours)
  • 12h (12 hours)
  • 1d (1 day)
  • 7d (7 days)
  • 30d (30 days)
Default value is 1d

+

Relative date filter. Available values are:

  • 1m (1 minute)
  • 15m (15 minutes)
  • 1h (1 hour)
  • 6h (6 hours)
  • 12h (12 hours)
  • 1d (1 day)
  • 7d (7 days)
  • 30d (30 days)
Default value is 1d

@@ -1803,8 +1803,8 @@ Return an array of errors with occurrence count on all tests run in the specifie

| QUERY | OPTIONAL | STRING |

Relative date filter. Available values are:

    -
  • 1m (1 month)
  • -
  • 15m (15 months)
  • +
  • 1m (1 minute)
  • +
  • 15m (15 minutes)
  • 1h (1 hour)
  • 6h (6 hours)
  • 12h (12 hours)
  • @@ -1970,7 +1970,7 @@ Return past and current data about errors for comparison. interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -2595,7 +2595,7 @@ Return an array of test cases (grouped by name) with statistical details. interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -2811,7 +2811,7 @@ Return an array of test cases (grouped by name) with statistical details as a CS interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -3007,7 +3007,7 @@ Return an array of test cases (grouped by name) with statistical details. interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -3521,7 +3521,7 @@ Return information about tests coverage for the specified coverage_field interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -3805,7 +3805,7 @@ Return information about tests coverage for the specified `coverage_field` in a interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -4041,7 +4041,7 @@ Return an array of buckets with aggregations, such as number of tests run on a s interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -4327,7 +4327,7 @@ Return an array of buckets with aggregations, such as the number of tests from a interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -4625,7 +4625,7 @@ Return statistics for errors that occurred in tests run in the specified period. interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    @@ -5009,7 +5009,7 @@ Return information about builds and tests run included in the build. Also, it pr interval -

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 month)
    • 15m (15 months)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d

    +

    | QUERY | OPTIONAL | STRING |

    Relative date filter. Available values are:

    • 1m (1 minute)
    • 15m (15 minutes)
    • 1h (1 hour)
    • 6h (6 hours)
    • 12h (12 hours)
    • 1d (1 day)
    • 7d (7 days)
    • 30d (30 days)
    Default value is 1d