Skip to content

Commit e591d5f

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit cbdc279 of spec repo
1 parent fb48d9e commit e591d5f

22 files changed

Lines changed: 2958 additions & 56 deletions

.generator/schemas/v2/openapi.yaml

Lines changed: 332 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38523,6 +38523,157 @@ components:
3852338523
format: int64
3852438524
type: integer
3852538525
type: object
38526+
FileCoverageLines:
38527+
description: Per-file line coverage data including executable, covered, and added lines.
38528+
properties:
38529+
added_lines:
38530+
description: Line numbers that were added in the specified scope (for example, in a PR diff).
38531+
example: [11, 12]
38532+
items:
38533+
format: int64
38534+
type: integer
38535+
type: array
38536+
covered_lines:
38537+
description: Line numbers that were covered by tests.
38538+
example: [10, 11, 15]
38539+
items:
38540+
format: int64
38541+
type: integer
38542+
type: array
38543+
executable_lines:
38544+
description: Line numbers that are executable (can be covered).
38545+
example: [10, 11, 12, 15, 20]
38546+
items:
38547+
format: int64
38548+
type: integer
38549+
type: array
38550+
type: object
38551+
FilesCoverageAttributes:
38552+
description: Attributes of the per-file code coverage response.
38553+
properties:
38554+
base_commit_sha:
38555+
description: The SHA of the base commit used for comparison (for example, the merge base for a PR).
38556+
example: abc1234567890abcdef1234567890abcdef12345
38557+
type: string
38558+
event_timestamp:
38559+
description: Unix timestamp (milliseconds) of the coverage event.
38560+
example: 1709564000000
38561+
format: int64
38562+
type: integer
38563+
files:
38564+
additionalProperties:
38565+
$ref: "#/components/schemas/FileCoverageLines"
38566+
description: Map of file paths to per-file coverage line data.
38567+
type: object
38568+
head_commit_sha:
38569+
description: The SHA of the head commit for which coverage was evaluated.
38570+
example: 66adc9350f2cc9b250b69abddab733dd55e1a588
38571+
type: string
38572+
report_count:
38573+
description: Number of coverage reports evaluated.
38574+
example: 3
38575+
format: int64
38576+
type: integer
38577+
type: object
38578+
FilesCoverageData:
38579+
description: Data object for files coverage response.
38580+
properties:
38581+
attributes:
38582+
$ref: "#/components/schemas/FilesCoverageAttributes"
38583+
id:
38584+
description: Unique identifier for the files coverage response.
38585+
example: ZGQxMjM0NV9tYWluXzE3MDk1NjQwMDA=
38586+
type: string
38587+
type:
38588+
$ref: "#/components/schemas/FilesCoverageResponseType"
38589+
type: object
38590+
FilesCoverageRequest:
38591+
description: Request object for getting per-file code coverage data.
38592+
properties:
38593+
data:
38594+
$ref: "#/components/schemas/FilesCoverageRequestData"
38595+
required:
38596+
- data
38597+
type: object
38598+
FilesCoverageRequestAttributes:
38599+
description: Attributes for requesting per-file code coverage data. Exactly one of `commit_sha`, `branch`, or `pr_number` must be provided. At most one of `service`, `codeowner`, or `flag` may be provided.
38600+
properties:
38601+
branch:
38602+
description: The branch name.
38603+
example: main
38604+
type: string
38605+
changed_only:
38606+
description: When true, return coverage data only for files that were changed in the specified scope.
38607+
example: true
38608+
type: boolean
38609+
codeowner:
38610+
description: Filter coverage by code owner. At most one of `service`, `codeowner`, or `flag` may be provided.
38611+
example: "@my-team"
38612+
type: string
38613+
commit_sha:
38614+
description: The commit SHA (40-character hexadecimal string).
38615+
example: 66adc9350f2cc9b250b69abddab733dd55e1a588
38616+
pattern: "^[a-fA-F0-9]{40}$"
38617+
type: string
38618+
flag:
38619+
description: Filter coverage by coverage flag. At most one of `service`, `codeowner`, or `flag` may be provided.
38620+
example: unit-tests
38621+
type: string
38622+
pr_number:
38623+
description: The pull request number. Must be a positive integer.
38624+
example: 42
38625+
format: int64
38626+
minimum: 1
38627+
type: integer
38628+
repository_id:
38629+
deprecated: true
38630+
description: "Deprecated: use `repository_url` instead. The repository URL."
38631+
example: github.com/datadog/shopist
38632+
minLength: 1
38633+
type: string
38634+
repository_url:
38635+
description: The repository URL. Accepts a full URL with or without a scheme (for example, `https://github.com/org/repo` or `github.com/org/repo`).
38636+
example: https://github.com/datadog/shopist
38637+
minLength: 1
38638+
type: string
38639+
service:
38640+
description: Filter coverage by service name. At most one of `service`, `codeowner`, or `flag` may be provided.
38641+
example: my-service
38642+
type: string
38643+
type: object
38644+
FilesCoverageRequestData:
38645+
description: Data object for files coverage request.
38646+
properties:
38647+
attributes:
38648+
$ref: "#/components/schemas/FilesCoverageRequestAttributes"
38649+
type:
38650+
$ref: "#/components/schemas/FilesCoverageRequestType"
38651+
required:
38652+
- type
38653+
- attributes
38654+
type: object
38655+
FilesCoverageRequestType:
38656+
description: JSON:API type for files coverage request. The value must always be `ci_app_coverage_files_request`.
38657+
enum:
38658+
- ci_app_coverage_files_request
38659+
example: ci_app_coverage_files_request
38660+
type: string
38661+
x-enum-varnames:
38662+
- CI_APP_COVERAGE_FILES_REQUEST
38663+
FilesCoverageResponse:
38664+
description: Response object containing per-file code coverage data.
38665+
properties:
38666+
data:
38667+
$ref: "#/components/schemas/FilesCoverageData"
38668+
type: object
38669+
FilesCoverageResponseType:
38670+
description: JSON:API type for files coverage response. The value must always be `ci_app_coverage_files`.
38671+
enum:
38672+
- ci_app_coverage_files
38673+
example: ci_app_coverage_files
38674+
type: string
38675+
x-enum-varnames:
38676+
- CI_APP_COVERAGE_FILES
3852638677
FiltersPerProduct:
3852738678
description: Product-specific filters for the dataset.
3852838679
properties:
@@ -79919,6 +80070,51 @@ components:
7991980070
type: string
7992080071
x-enum-varnames:
7992180072
- OWNERSHIP_UNTAGGED_FINDINGS
80073+
PRCoverageSummaryRequest:
80074+
description: Request object for getting code coverage summary for a pull request.
80075+
properties:
80076+
data:
80077+
$ref: "#/components/schemas/PRCoverageSummaryRequestData"
80078+
required:
80079+
- data
80080+
type: object
80081+
PRCoverageSummaryRequestAttributes:
80082+
description: Attributes for requesting code coverage summary for a pull request.
80083+
properties:
80084+
pr_number:
80085+
description: The pull request number. Must be a positive integer.
80086+
example: 42
80087+
format: int64
80088+
minimum: 1
80089+
type: integer
80090+
repository_url:
80091+
description: The repository URL. Accepts a full URL with or without a scheme (for example, `https://github.com/org/repo` or `github.com/org/repo`).
80092+
example: https://github.com/datadog/shopist
80093+
minLength: 1
80094+
type: string
80095+
required:
80096+
- repository_url
80097+
- pr_number
80098+
type: object
80099+
PRCoverageSummaryRequestData:
80100+
description: Data object for PR summary request.
80101+
properties:
80102+
attributes:
80103+
$ref: "#/components/schemas/PRCoverageSummaryRequestAttributes"
80104+
type:
80105+
$ref: "#/components/schemas/PRCoverageSummaryRequestType"
80106+
required:
80107+
- type
80108+
- attributes
80109+
type: object
80110+
PRCoverageSummaryRequestType:
80111+
description: JSON:API type for PR coverage summary request. The value must always be `ci_app_coverage_pr_summary_request`.
80112+
enum:
80113+
- ci_app_coverage_pr_summary_request
80114+
example: ci_app_coverage_pr_summary_request
80115+
type: string
80116+
x-enum-varnames:
80117+
- CI_APP_COVERAGE_PR_SUMMARY_REQUEST
7992280118
PageAnnotationsAttributes:
7992380119
description: Attributes of the annotations on a page.
7992480120
properties:
@@ -132319,9 +132515,6 @@ paths:
132319132515
operator: OR
132320132516
permissions:
132321132517
- code_coverage_read
132322-
x-unstable: |-
132323-
**Note**: This endpoint is in preview and may be subject to change.
132324-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
132325132518
/api/v2/code-coverage/commit/summary:
132326132519
post:
132327132520
description: |-
@@ -132389,9 +132582,142 @@ paths:
132389132582
operator: OR
132390132583
permissions:
132391132584
- code_coverage_read
132392-
x-unstable: |-
132393-
**Note**: This endpoint is in preview and may be subject to change.
132394-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
132585+
/api/v2/code-coverage/files:
132586+
post:
132587+
description: |-
132588+
Retrieve per-file code coverage data for a specific commit, branch, or pull request.
132589+
Exactly one of `commit_sha`, `branch`, or `pr_number` must be provided.
132590+
Optionally filter by `service`, `codeowner`, or `flag` (at most one).
132591+
operationId: GetCodeCoverageFiles
132592+
requestBody:
132593+
content:
132594+
application/json:
132595+
examples:
132596+
default:
132597+
value:
132598+
data:
132599+
attributes:
132600+
changed_only: true
132601+
commit_sha: 66adc9350f2cc9b250b69abddab733dd55e1a588
132602+
repository_url: https://github.com/datadog/test-service
132603+
type: ci_app_coverage_files_request
132604+
schema:
132605+
$ref: "#/components/schemas/FilesCoverageRequest"
132606+
required: true
132607+
responses:
132608+
"200":
132609+
content:
132610+
application/json:
132611+
examples:
132612+
default:
132613+
value:
132614+
data:
132615+
attributes:
132616+
base_commit_sha: abc1234567890abcdef1234567890abcdef12345
132617+
event_timestamp: 1709564000000
132618+
files:
132619+
src/main.go:
132620+
added_lines: [11, 12]
132621+
covered_lines: [10, 11, 15]
132622+
executable_lines: [10, 11, 12, 15, 20]
132623+
head_commit_sha: 66adc9350f2cc9b250b69abddab733dd55e1a588
132624+
report_count: 3
132625+
id: ZGQxMjM0NV9tYWluXzE3MDk1NjQwMDA=
132626+
type: ci_app_coverage_files
132627+
schema:
132628+
$ref: "#/components/schemas/FilesCoverageResponse"
132629+
description: OK
132630+
"400":
132631+
$ref: "#/components/responses/BadRequestResponse"
132632+
"403":
132633+
$ref: "#/components/responses/NotAuthorizedResponse"
132634+
"404":
132635+
$ref: "#/components/responses/NotFoundResponse"
132636+
"429":
132637+
$ref: "#/components/responses/TooManyRequestsResponse"
132638+
"500":
132639+
content:
132640+
application/json:
132641+
schema:
132642+
$ref: "#/components/schemas/APIErrorResponse"
132643+
description: Internal server error
132644+
security:
132645+
- apiKeyAuth: []
132646+
appKeyAuth: []
132647+
- AuthZ:
132648+
- code_coverage_read
132649+
summary: Get per-file code coverage data
132650+
tags: ["Code Coverage"]
132651+
x-codegen-request-body-name: body
132652+
x-permission:
132653+
operator: OR
132654+
permissions:
132655+
- code_coverage_read
132656+
/api/v2/code-coverage/pr/summary:
132657+
post:
132658+
description: |-
132659+
Retrieve aggregated code coverage statistics for a specific pull request in a repository.
132660+
This endpoint provides overall coverage metrics as well as breakdowns by service
132661+
and code owner.
132662+
operationId: GetCodeCoveragePRSummary
132663+
requestBody:
132664+
content:
132665+
application/json:
132666+
examples:
132667+
default:
132668+
value:
132669+
data:
132670+
attributes:
132671+
pr_number: 42
132672+
repository_url: https://github.com/datadog/test-service
132673+
type: ci_app_coverage_pr_summary_request
132674+
schema:
132675+
$ref: "#/components/schemas/PRCoverageSummaryRequest"
132676+
required: true
132677+
responses:
132678+
"200":
132679+
content:
132680+
application/json:
132681+
examples:
132682+
default:
132683+
value:
132684+
data:
132685+
attributes:
132686+
evaluated_flags_count: 3
132687+
evaluated_reports_count: 5
132688+
patch_coverage: 65.2
132689+
total_coverage: 78.6
132690+
id: ZGQxMjM0NV9wcl80Ml8xNzA5NTY0MDAw
132691+
type: ci_app_coverage_summary
132692+
schema:
132693+
$ref: "#/components/schemas/CoverageSummaryResponse"
132694+
description: OK
132695+
"400":
132696+
$ref: "#/components/responses/BadRequestResponse"
132697+
"403":
132698+
$ref: "#/components/responses/NotAuthorizedResponse"
132699+
"404":
132700+
$ref: "#/components/responses/NotFoundResponse"
132701+
"429":
132702+
$ref: "#/components/responses/TooManyRequestsResponse"
132703+
"500":
132704+
content:
132705+
application/json:
132706+
schema:
132707+
$ref: "#/components/schemas/APIErrorResponse"
132708+
description: Internal server error
132709+
security:
132710+
- apiKeyAuth: []
132711+
appKeyAuth: []
132712+
- AuthZ:
132713+
- code_coverage_read
132714+
summary: Get code coverage summary for a pull request
132715+
tags: ["Code Coverage"]
132716+
x-codegen-request-body-name: body
132717+
x-permission:
132718+
operator: OR
132719+
permissions:
132720+
- code_coverage_read
132395132721
/api/v2/compliance_findings/rule_based_view:
132396132722
get:
132397132723
deprecated: true

examples/v2/code-coverage/GetCodeCoverageBranchSummary.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
public class Example {
1313
public static void main(String[] args) {
1414
ApiClient defaultClient = ApiClient.getDefaultApiClient();
15-
defaultClient.setUnstableOperationEnabled("v2.getCodeCoverageBranchSummary", true);
1615
CodeCoverageApi apiInstance = new CodeCoverageApi(defaultClient);
1716

1817
BranchCoverageSummaryRequest body =

examples/v2/code-coverage/GetCodeCoverageCommitSummary.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
public class Example {
1313
public static void main(String[] args) {
1414
ApiClient defaultClient = ApiClient.getDefaultApiClient();
15-
defaultClient.setUnstableOperationEnabled("v2.getCodeCoverageCommitSummary", true);
1615
CodeCoverageApi apiInstance = new CodeCoverageApi(defaultClient);
1716

1817
CommitCoverageSummaryRequest body =

0 commit comments

Comments
 (0)