Skip to content

Commit 8bf5752

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit ff181ed of spec repo (#3794)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 73111f3 commit 8bf5752

17 files changed

+1130
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 252 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64486,6 +64486,214 @@ components:
6448664486
description: The direction and type of synchronization for this property.
6448764487
type: string
6448864488
type: object
64489+
SyntheticsFastTestAssertionResult:
64490+
additionalProperties: {}
64491+
description: Result of a single assertion evaluated during a fast test run.
64492+
type: object
64493+
SyntheticsFastTestResult:
64494+
description: |-
64495+
Fast test result response. Returns `null` if the result is not yet available
64496+
(the test is still running or timed out before completing).
64497+
nullable: true
64498+
properties:
64499+
data:
64500+
$ref: "#/components/schemas/SyntheticsFastTestResultData"
64501+
type: object
64502+
SyntheticsFastTestResultAttributes:
64503+
description: Attributes of the fast test result.
64504+
properties:
64505+
device:
64506+
$ref: "#/components/schemas/SyntheticsFastTestResultDevice"
64507+
location:
64508+
$ref: "#/components/schemas/SyntheticsFastTestResultLocation"
64509+
result:
64510+
$ref: "#/components/schemas/SyntheticsFastTestResultDetail"
64511+
test_sub_type:
64512+
$ref: "#/components/schemas/SyntheticsFastTestSubType"
64513+
test_type:
64514+
description: The type of the Synthetic test that produced this result (for example, `api` or `browser`).
64515+
example: api
64516+
type: string
64517+
test_version:
64518+
description: Version of the test at the time the fast test was triggered.
64519+
format: int64
64520+
type: integer
64521+
type: object
64522+
SyntheticsFastTestResultData:
64523+
description: Fast test result data object (JSON:API format).
64524+
properties:
64525+
attributes:
64526+
$ref: "#/components/schemas/SyntheticsFastTestResultAttributes"
64527+
id:
64528+
description: The UUID of the fast test, used as the result identifier.
64529+
example: abc12345-1234-1234-1234-abc123456789
64530+
type: string
64531+
type:
64532+
$ref: "#/components/schemas/SyntheticsFastTestResultType"
64533+
type: object
64534+
SyntheticsFastTestResultDetail:
64535+
description: |-
64536+
Detailed result data for the fast test run. The exact shape of nested fields
64537+
(`request`, `response`, `assertions`, etc.) depends on the test subtype.
64538+
properties:
64539+
assertions:
64540+
description: Results of each assertion evaluated during the test.
64541+
items:
64542+
$ref: "#/components/schemas/SyntheticsFastTestAssertionResult"
64543+
type: array
64544+
call_type:
64545+
description: gRPC call type (for example, `unary`, `healthCheck`, or `reflection`).
64546+
type: string
64547+
cert:
64548+
additionalProperties: {}
64549+
description: TLS certificate details, present for SSL tests.
64550+
type: object
64551+
duration:
64552+
description: Total duration of the test in milliseconds.
64553+
format: double
64554+
type: number
64555+
failure:
64556+
$ref: "#/components/schemas/SyntheticsFastTestResultFailure"
64557+
finished_at:
64558+
description: Unix timestamp (ms) of when the test finished.
64559+
format: int64
64560+
type: integer
64561+
id:
64562+
description: The result ID. Set to the fast test UUID because no persistent result ID exists for fast tests.
64563+
type: string
64564+
is_fast_retry:
64565+
description: Whether this result is from an automatic fast retry.
64566+
type: boolean
64567+
request:
64568+
additionalProperties: {}
64569+
description: Details of the outgoing request made during the test.
64570+
type: object
64571+
resolved_ip:
64572+
description: IP address resolved for the target host.
64573+
example: "1.2.3.4"
64574+
type: string
64575+
response:
64576+
additionalProperties: {}
64577+
description: Details of the response received during the test.
64578+
type: object
64579+
run_type:
64580+
description: Run type indicating how this test was triggered (for example, `fast`).
64581+
type: string
64582+
started_at:
64583+
description: Unix timestamp (ms) of when the test started.
64584+
format: int64
64585+
type: integer
64586+
status:
64587+
description: Status of the test result (`passed` or `failed`).
64588+
example: passed
64589+
type: string
64590+
steps:
64591+
description: Step results for multistep API tests.
64592+
items:
64593+
$ref: "#/components/schemas/SyntheticsFastTestStepResult"
64594+
type: array
64595+
timings:
64596+
additionalProperties: {}
64597+
description: Timing breakdown of the test request phases (for example, DNS, TCP, TLS, first byte).
64598+
type: object
64599+
traceroute:
64600+
description: Traceroute hop results, present for ICMP and TCP tests.
64601+
items:
64602+
$ref: "#/components/schemas/SyntheticsFastTestTracerouteHop"
64603+
type: array
64604+
triggered_at:
64605+
description: Unix timestamp (ms) of when the test was triggered.
64606+
format: int64
64607+
type: integer
64608+
tunnel:
64609+
description: Whether the test was run through a Synthetics tunnel.
64610+
type: boolean
64611+
type: object
64612+
SyntheticsFastTestResultDevice:
64613+
description: Device information for browser-based fast tests.
64614+
properties:
64615+
id:
64616+
description: Device identifier.
64617+
example: chrome.laptop_large
64618+
type: string
64619+
name:
64620+
description: Display name of the device.
64621+
example: Laptop Large
64622+
type: string
64623+
type: object
64624+
SyntheticsFastTestResultFailure:
64625+
description: Failure details if the fast test did not pass.
64626+
properties:
64627+
code:
64628+
description: Error code identifying the failure type.
64629+
example: TIMEOUT
64630+
type: string
64631+
message:
64632+
description: Human-readable description of the failure.
64633+
example: Connection timed out
64634+
type: string
64635+
type: object
64636+
SyntheticsFastTestResultLocation:
64637+
description: Location from which the fast test was executed.
64638+
properties:
64639+
id:
64640+
description: ID of the location.
64641+
example: aws:us-east-1
64642+
type: string
64643+
name:
64644+
description: Display name of the location.
64645+
example: N. Virginia (AWS)
64646+
type: string
64647+
version:
64648+
description: Agent version running at this location.
64649+
type: string
64650+
worker_id:
64651+
description: Identifier of the specific worker that ran the test.
64652+
type: string
64653+
type: object
64654+
SyntheticsFastTestResultType:
64655+
default: result
64656+
description: JSON:API type for a fast test result.
64657+
enum:
64658+
- result
64659+
example: result
64660+
type: string
64661+
x-enum-varnames:
64662+
- RESULT
64663+
SyntheticsFastTestStepResult:
64664+
additionalProperties: {}
64665+
description: Result of a single step in a multistep fast test run.
64666+
type: object
64667+
SyntheticsFastTestSubType:
64668+
description: Subtype of the Synthetic test that produced this result.
64669+
enum:
64670+
- dns
64671+
- grpc
64672+
- http
64673+
- icmp
64674+
- mcp
64675+
- multi
64676+
- ssl
64677+
- tcp
64678+
- udp
64679+
- websocket
64680+
example: http
64681+
type: string
64682+
x-enum-varnames:
64683+
- DNS
64684+
- GRPC
64685+
- HTTP
64686+
- ICMP
64687+
- MCP
64688+
- MULTI
64689+
- SSL
64690+
- TCP
64691+
- UDP
64692+
- WEBSOCKET
64693+
SyntheticsFastTestTracerouteHop:
64694+
additionalProperties: {}
64695+
description: A single traceroute hop result from a fast test run.
64696+
type: object
6448964697
SyntheticsGlobalVariable:
6449064698
description: Synthetic global variable.
6449164699
properties:
@@ -106234,6 +106442,50 @@ paths:
106234106442
operator: OR
106235106443
permissions:
106236106444
- synthetics_write
106445+
/api/v2/synthetics/tests/fast/{id}:
106446+
get:
106447+
operationId: GetSyntheticsFastTestResult
106448+
parameters:
106449+
- description: The UUID of the fast test to retrieve the result for.
106450+
in: path
106451+
name: id
106452+
required: true
106453+
schema:
106454+
example: abc12345-1234-1234-1234-abc123456789
106455+
type: string
106456+
responses:
106457+
"200":
106458+
content:
106459+
application/json:
106460+
schema:
106461+
$ref: "#/components/schemas/SyntheticsFastTestResult"
106462+
description: OK
106463+
"400":
106464+
content:
106465+
application/json:
106466+
schema:
106467+
$ref: "#/components/schemas/APIErrorResponse"
106468+
description: API error response.
106469+
"404":
106470+
content:
106471+
application/json:
106472+
schema:
106473+
$ref: "#/components/schemas/APIErrorResponse"
106474+
description: API error response.
106475+
"429":
106476+
$ref: "#/components/responses/TooManyRequestsResponse"
106477+
security:
106478+
- apiKeyAuth: []
106479+
appKeyAuth: []
106480+
- AuthZ:
106481+
- synthetics_read
106482+
summary: Get a fast test result
106483+
tags:
106484+
- Synthetics
106485+
x-permission:
106486+
operator: OR
106487+
permissions:
106488+
- synthetics_read
106237106489
/api/v2/synthetics/tests/network:
106238106490
post:
106239106491
operationId: CreateSyntheticsNetworkTest
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/**
2+
* Get a fast test result returns "OK" response
3+
*/
4+
5+
import { client, v2 } from "@datadog/datadog-api-client";
6+
7+
const configuration = client.createConfiguration();
8+
const apiInstance = new v2.SyntheticsApi(configuration);
9+
10+
const params: v2.SyntheticsApiGetSyntheticsFastTestResultRequest = {
11+
id: "abc12345-1234-1234-1234-abc123456789",
12+
};
13+
14+
apiInstance
15+
.getSyntheticsFastTestResult(params)
16+
.then((data: v2.SyntheticsFastTestResult) => {
17+
console.log(
18+
"API called successfully. Returned data: " + JSON.stringify(data)
19+
);
20+
})
21+
.catch((error: any) => console.error(error));

features/support/scenarios_model_mapping.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11168,6 +11168,13 @@ export const ScenariosModelMappings: {[key: string]: {[key: string]: any}} = {
1116811168
},
1116911169
"operationResponseType": "DeletedTestsResponse",
1117011170
},
11171+
"v2.GetSyntheticsFastTestResult": {
11172+
"id": {
11173+
"type": "string",
11174+
"format": "",
11175+
},
11176+
"operationResponseType": "SyntheticsFastTestResult",
11177+
},
1117111178
"v2.CreateSyntheticsNetworkTest": {
1117211179
"body": {
1117311180
"type": "SyntheticsNetworkTestEditRequest",

features/v2/synthetics.feature

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,20 @@ Feature: Synthetics
119119
When the request is sent
120120
Then the response status is 200 OK
121121

122+
@generated @skip @team:DataDog/synthetics-managing
123+
Scenario: Get a fast test result returns "API error response." response
124+
Given new "GetSyntheticsFastTestResult" request
125+
And request contains "id" parameter from "REPLACE.ME"
126+
When the request is sent
127+
Then the response status is 404 API error response.
128+
129+
@generated @skip @team:DataDog/synthetics-managing
130+
Scenario: Get a fast test result returns "OK" response
131+
Given new "GetSyntheticsFastTestResult" request
132+
And request contains "id" parameter from "REPLACE.ME"
133+
When the request is sent
134+
Then the response status is 200 OK
135+
122136
@generated @skip @team:DataDog/synthetics-managing
123137
Scenario: Get a suite returns "API error response." response
124138
Given new "GetSyntheticsSuite" request

features/v2/undo.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5864,6 +5864,12 @@
58645864
"type": "idempotent"
58655865
}
58665866
},
5867+
"GetSyntheticsFastTestResult": {
5868+
"tag": "Synthetics",
5869+
"undo": {
5870+
"type": "safe"
5871+
}
5872+
},
58675873
"CreateSyntheticsNetworkTest": {
58685874
"tag": "Synthetics",
58695875
"undo": {

0 commit comments

Comments
 (0)