Skip to content

Commit a396ce8

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit fc4004e of spec repo
1 parent 812b65c commit a396ce8

File tree

37 files changed

+4401
-0
lines changed

37 files changed

+4401
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 319 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39232,6 +39232,95 @@ components:
3923239232
type: string
3923339233
x-enum-varnames:
3923439234
- RULESET
39235+
ResolveVulnerableSymbolsRequest:
39236+
properties:
39237+
data:
39238+
$ref: '#/components/schemas/ResolveVulnerableSymbolsRequestData'
39239+
type: object
39240+
ResolveVulnerableSymbolsRequestData:
39241+
properties:
39242+
attributes:
39243+
$ref: '#/components/schemas/ResolveVulnerableSymbolsRequestDataAttributes'
39244+
id:
39245+
type: string
39246+
type:
39247+
$ref: '#/components/schemas/ResolveVulnerableSymbolsRequestDataType'
39248+
required:
39249+
- type
39250+
type: object
39251+
ResolveVulnerableSymbolsRequestDataAttributes:
39252+
properties:
39253+
purls:
39254+
items:
39255+
type: string
39256+
type: array
39257+
type: object
39258+
ResolveVulnerableSymbolsRequestDataType:
39259+
default: resolve-vulnerable-symbols-request
39260+
enum:
39261+
- resolve-vulnerable-symbols-request
39262+
example: resolve-vulnerable-symbols-request
39263+
type: string
39264+
x-enum-varnames:
39265+
- RESOLVE_VULNERABLE_SYMBOLS_REQUEST
39266+
ResolveVulnerableSymbolsResponse:
39267+
properties:
39268+
data:
39269+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponseData'
39270+
type: object
39271+
ResolveVulnerableSymbolsResponseData:
39272+
properties:
39273+
attributes:
39274+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponseDataAttributes'
39275+
id:
39276+
type: string
39277+
type:
39278+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponseDataType'
39279+
required:
39280+
- type
39281+
type: object
39282+
ResolveVulnerableSymbolsResponseDataAttributes:
39283+
properties:
39284+
results:
39285+
items:
39286+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponseResults'
39287+
type: array
39288+
type: object
39289+
ResolveVulnerableSymbolsResponseDataType:
39290+
default: resolve-vulnerable-symbols-response
39291+
enum:
39292+
- resolve-vulnerable-symbols-response
39293+
example: resolve-vulnerable-symbols-response
39294+
type: string
39295+
x-enum-varnames:
39296+
- RESOLVE_VULNERABLE_SYMBOLS_RESPONSE
39297+
ResolveVulnerableSymbolsResponseResults:
39298+
properties:
39299+
purl:
39300+
type: string
39301+
vulnerable_symbols:
39302+
items:
39303+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponseResultsVulnerableSymbols'
39304+
type: array
39305+
type: object
39306+
ResolveVulnerableSymbolsResponseResultsVulnerableSymbols:
39307+
properties:
39308+
advisory_id:
39309+
type: string
39310+
symbols:
39311+
items:
39312+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponseResultsVulnerableSymbolsSymbols'
39313+
type: array
39314+
type: object
39315+
ResolveVulnerableSymbolsResponseResultsVulnerableSymbolsSymbols:
39316+
properties:
39317+
name:
39318+
type: string
39319+
type:
39320+
type: string
39321+
value:
39322+
type: string
39323+
type: object
3923539324
ResourceFilterAttributes:
3923639325
description: Attributes of a resource filter.
3923739326
example:
@@ -41666,6 +41755,184 @@ components:
4166641755
example: report_id
4166741756
type: string
4166841757
type: object
41758+
ScaRequest:
41759+
properties:
41760+
data:
41761+
$ref: '#/components/schemas/ScaRequestData'
41762+
type: object
41763+
ScaRequestData:
41764+
properties:
41765+
attributes:
41766+
$ref: '#/components/schemas/ScaRequestDataAttributes'
41767+
id:
41768+
type: string
41769+
type:
41770+
$ref: '#/components/schemas/ScaRequestDataType'
41771+
required:
41772+
- type
41773+
type: object
41774+
ScaRequestDataAttributes:
41775+
properties:
41776+
commit:
41777+
$ref: '#/components/schemas/ScaRequestDataAttributesCommit'
41778+
dependencies:
41779+
items:
41780+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItems'
41781+
type: array
41782+
env:
41783+
type: string
41784+
files:
41785+
items:
41786+
$ref: '#/components/schemas/ScaRequestDataAttributesFilesItems'
41787+
type: array
41788+
relations:
41789+
items:
41790+
$ref: '#/components/schemas/ScaRequestDataAttributesRelationsItems'
41791+
type: array
41792+
repository:
41793+
$ref: '#/components/schemas/ScaRequestDataAttributesRepository'
41794+
service:
41795+
type: string
41796+
tags:
41797+
additionalProperties:
41798+
type: string
41799+
type: object
41800+
vulnerabilities:
41801+
items:
41802+
$ref: '#/components/schemas/ScaRequestDataAttributesVulnerabilitiesItems'
41803+
type: array
41804+
type: object
41805+
ScaRequestDataAttributesCommit:
41806+
properties:
41807+
author_date:
41808+
type: string
41809+
author_email:
41810+
type: string
41811+
author_name:
41812+
type: string
41813+
branch:
41814+
type: string
41815+
committer_email:
41816+
type: string
41817+
committer_name:
41818+
type: string
41819+
sha:
41820+
type: string
41821+
type: object
41822+
ScaRequestDataAttributesDependenciesItems:
41823+
properties:
41824+
exclusions:
41825+
items:
41826+
type: string
41827+
type: array
41828+
group:
41829+
type: string
41830+
is_dev:
41831+
type: boolean
41832+
is_direct:
41833+
type: boolean
41834+
language:
41835+
type: string
41836+
locations:
41837+
items:
41838+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItems'
41839+
type: array
41840+
name:
41841+
type: string
41842+
package_manager:
41843+
type: string
41844+
purl:
41845+
type: string
41846+
reachable_symbol_properties:
41847+
items:
41848+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsReachableSymbolPropertiesItems'
41849+
type: array
41850+
version:
41851+
type: string
41852+
type: object
41853+
ScaRequestDataAttributesDependenciesItemsLocationsItems:
41854+
properties:
41855+
block:
41856+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItemsFilePosition'
41857+
name:
41858+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItemsFilePosition'
41859+
namespace:
41860+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItemsFilePosition'
41861+
version:
41862+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItemsFilePosition'
41863+
type: object
41864+
ScaRequestDataAttributesDependenciesItemsLocationsItemsFilePosition:
41865+
properties:
41866+
end:
41867+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItemsPosition'
41868+
file_name:
41869+
type: string
41870+
start:
41871+
$ref: '#/components/schemas/ScaRequestDataAttributesDependenciesItemsLocationsItemsPosition'
41872+
type: object
41873+
ScaRequestDataAttributesDependenciesItemsLocationsItemsPosition:
41874+
properties:
41875+
col:
41876+
format: int32
41877+
maximum: 2147483647
41878+
type: integer
41879+
line:
41880+
format: int32
41881+
maximum: 2147483647
41882+
type: integer
41883+
type: object
41884+
ScaRequestDataAttributesDependenciesItemsReachableSymbolPropertiesItems:
41885+
properties:
41886+
name:
41887+
type: string
41888+
value:
41889+
type: string
41890+
type: object
41891+
ScaRequestDataAttributesFilesItems:
41892+
properties:
41893+
name:
41894+
type: string
41895+
purl:
41896+
type: string
41897+
type: object
41898+
ScaRequestDataAttributesRelationsItems:
41899+
properties:
41900+
depends_on:
41901+
items:
41902+
type: string
41903+
type: array
41904+
ref:
41905+
type: string
41906+
type: object
41907+
ScaRequestDataAttributesRepository:
41908+
properties:
41909+
url:
41910+
type: string
41911+
type: object
41912+
ScaRequestDataAttributesVulnerabilitiesItems:
41913+
properties:
41914+
affects:
41915+
items:
41916+
$ref: '#/components/schemas/ScaRequestDataAttributesVulnerabilitiesItemsAffectsItems'
41917+
type: array
41918+
bom_ref:
41919+
type: string
41920+
id:
41921+
type: string
41922+
type: object
41923+
ScaRequestDataAttributesVulnerabilitiesItemsAffectsItems:
41924+
properties:
41925+
ref:
41926+
type: string
41927+
type: object
41928+
ScaRequestDataType:
41929+
default: scarequests
41930+
enum:
41931+
- scarequests
41932+
example: scarequests
41933+
type: string
41934+
x-enum-varnames:
41935+
- SCAREQUESTS
4166941936
ScalarColumn:
4167041937
description: A single column in a scalar query response.
4167141938
oneOf:
@@ -76575,6 +76842,56 @@ paths:
7657576842
cursorPath: meta.page.after
7657676843
limitParam: body.data.attributes.page.limit
7657776844
resultsPath: data
76845+
/api/v2/static-analysis-sca/dependencies:
76846+
post:
76847+
operationId: CreateSCAResult
76848+
requestBody:
76849+
content:
76850+
application/json:
76851+
schema:
76852+
$ref: '#/components/schemas/ScaRequest'
76853+
required: true
76854+
responses:
76855+
'200':
76856+
description: OK
76857+
'429':
76858+
$ref: '#/components/responses/TooManyRequestsResponse'
76859+
security:
76860+
- apiKeyAuth: []
76861+
appKeyAuth: []
76862+
- AuthZ:
76863+
- code_analysis_read
76864+
summary: Post dependencies for analysis
76865+
tags:
76866+
- Static Analysis
76867+
x-unstable: '**Note**: This endpoint may be subject to changes.'
76868+
/api/v2/static-analysis-sca/vulnerabilities/resolve-vulnerable-symbols:
76869+
post:
76870+
operationId: CreateSCAResolveVulnerableSymbols
76871+
requestBody:
76872+
content:
76873+
application/json:
76874+
schema:
76875+
$ref: '#/components/schemas/ResolveVulnerableSymbolsRequest'
76876+
required: true
76877+
responses:
76878+
'200':
76879+
content:
76880+
application/json:
76881+
schema:
76882+
$ref: '#/components/schemas/ResolveVulnerableSymbolsResponse'
76883+
description: OK
76884+
'429':
76885+
$ref: '#/components/responses/TooManyRequestsResponse'
76886+
security:
76887+
- apiKeyAuth: []
76888+
appKeyAuth: []
76889+
- AuthZ:
76890+
- code_analysis_read
76891+
summary: POST request to resolve vulnerable symbols
76892+
tags:
76893+
- Static Analysis
76894+
x-unstable: '**Note**: This endpoint may be subject to changes.'
7657876895
/api/v2/synthetics/settings/on_demand_concurrency_cap:
7657976896
get:
7658076897
description: Get the on-demand concurrency cap.
@@ -80100,6 +80417,8 @@ tags:
8010080417
description: Find out more at
8010180418
url: https://docs.datadoghq.com/tracing/metrics/metrics_namespace/
8010280419
name: Spans Metrics
80420+
- description: API for static analysis
80421+
name: Static Analysis
8010380422
- description: "Datadog Synthetics uses simulated user requests and browser rendering
8010480423
to help you ensure uptime,\nidentify regional issues, and track your application
8010580424
performance. Datadog Synthetics tests come in\ntwo different flavors, [API tests](https://docs.datadoghq.com/synthetics/api_tests/)\nand
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// POST request to resolve vulnerable symbols returns "OK" response
2+
use datadog_api_client::datadog;
3+
use datadog_api_client::datadogV2::api_static_analysis::StaticAnalysisAPI;
4+
use datadog_api_client::datadogV2::model::ResolveVulnerableSymbolsRequest;
5+
use datadog_api_client::datadogV2::model::ResolveVulnerableSymbolsRequestData;
6+
use datadog_api_client::datadogV2::model::ResolveVulnerableSymbolsRequestDataAttributes;
7+
use datadog_api_client::datadogV2::model::ResolveVulnerableSymbolsRequestDataType;
8+
9+
#[tokio::main]
10+
async fn main() {
11+
let body = ResolveVulnerableSymbolsRequest::new().data(
12+
ResolveVulnerableSymbolsRequestData::new(
13+
ResolveVulnerableSymbolsRequestDataType::RESOLVE_VULNERABLE_SYMBOLS_REQUEST,
14+
)
15+
.attributes(ResolveVulnerableSymbolsRequestDataAttributes::new().purls(vec![])),
16+
);
17+
let mut configuration = datadog::Configuration::new();
18+
configuration.set_unstable_operation_enabled("v2.CreateSCAResolveVulnerableSymbols", true);
19+
let api = StaticAnalysisAPI::with_config(configuration);
20+
let resp = api.create_sca_resolve_vulnerable_symbols(body).await;
21+
if let Ok(value) = resp {
22+
println!("{:#?}", value);
23+
} else {
24+
println!("{:#?}", resp.unwrap_err());
25+
}
26+
}

0 commit comments

Comments
 (0)