datadog_api_client 1.10.0 → 1.11.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (111) hide show
  1. checksums.yaml +4 -4
  2. data/.apigentools-info +4 -4
  3. data/.generator/schemas/v1/openapi.yaml +715 -44
  4. data/.generator/schemas/v2/openapi.yaml +458 -44
  5. data/.generator/src/generator/formatter.py +14 -0
  6. data/.github/workflows/test_integration.yml +0 -7
  7. data/CHANGELOG.md +34 -0
  8. data/examples/v1/dashboards/CreateDashboard_1442588603.rb +61 -0
  9. data/examples/v1/dashboards/CreateDashboard_252716965.rb +52 -0
  10. data/examples/v1/dashboards/CreateDashboard_3882428227.rb +60 -0
  11. data/examples/v1/metrics/SubmitDistributionPoints.rb +22 -0
  12. data/examples/v1/metrics/SubmitDistributionPoints_3109558960.rb +25 -0
  13. data/examples/v1/organizations/DowngradeOrg.rb +5 -0
  14. data/examples/v1/organizations/UpdateOrg.rb +1 -0
  15. data/examples/v1/service-level-objectives/SearchSLO.rb +16 -0
  16. data/examples/v1/snapshots/GetGraphSnapshot.rb +2 -0
  17. data/examples/v1/synthetics/CreateSyntheticsAPITest.rb +3 -0
  18. data/examples/v1/synthetics/CreateSyntheticsBrowserTest_2932742688.rb +3 -0
  19. data/examples/v1/synthetics/UpdateBrowserTest.rb +3 -0
  20. data/examples/v2/metrics/CreateTagConfiguration.rb +0 -3
  21. data/examples/v2/metrics/DeleteTagConfiguration.rb +0 -3
  22. data/examples/v2/metrics/ListTagConfigurationByName.rb +0 -3
  23. data/examples/v2/metrics/ListTagConfigurations.rb +0 -3
  24. data/examples/v2/metrics/ListTagConfigurations_103226315.rb +0 -3
  25. data/examples/v2/metrics/ListTagConfigurations_1799362914.rb +0 -3
  26. data/examples/v2/metrics/UpdateTagConfiguration.rb +0 -3
  27. data/examples/v2/opsgenie-integration/CreateOpsgenieService.rb +16 -0
  28. data/examples/v2/opsgenie-integration/DeleteOpsgenieService.rb +8 -0
  29. data/examples/v2/opsgenie-integration/GetOpsgenieService.rb +8 -0
  30. data/examples/v2/opsgenie-integration/ListOpsgenieServices.rb +5 -0
  31. data/examples/v2/opsgenie-integration/UpdateOpsgenieService.rb +21 -0
  32. data/examples/v2/security-monitoring/ListSecurityMonitoringSignals.rb +0 -3
  33. data/examples/v2/security-monitoring/SearchSecurityMonitoringSignals.rb +0 -3
  34. data/examples/v2/security-monitoring/UpdateSecurityMonitoringRule.rb +3 -0
  35. data/examples/v2/usage-metering/GetEstimatedCostByOrg.rb +5 -0
  36. data/examples/v2/usage-metering/GetEstimatedCostByOrg_1171921972.rb +9 -0
  37. data/examples/v2/usage-metering/GetEstimatedCostByOrg_627383212.rb +9 -0
  38. data/lib/datadog_api_client/v1/api/metrics_api.rb +81 -0
  39. data/lib/datadog_api_client/v1/api/organizations_api.rb +74 -1
  40. data/lib/datadog_api_client/v1/api/security_monitoring_api.rb +2 -2
  41. data/lib/datadog_api_client/v1/api/service_level_objectives_api.rb +78 -4
  42. data/lib/datadog_api_client/v1/api/snapshots_api.rb +4 -0
  43. data/lib/datadog_api_client/v1/api/usage_metering_api.rb +9 -5
  44. data/lib/datadog_api_client/v1/configuration.rb +51 -0
  45. data/lib/datadog_api_client/v1/models/distribution_point_item.rb +63 -0
  46. data/lib/datadog_api_client/v1/models/distribution_points_content_encoding.rb +26 -0
  47. data/lib/datadog_api_client/v1/models/distribution_points_payload.rb +124 -0
  48. data/lib/datadog_api_client/v1/models/distribution_points_series.rb +179 -0
  49. data/lib/datadog_api_client/v1/models/distribution_points_type.rb +26 -0
  50. data/lib/datadog_api_client/v1/models/distribution_widget_histogram_request_query.rb +64 -0
  51. data/lib/datadog_api_client/v1/models/distribution_widget_histogram_request_type.rb +26 -0
  52. data/lib/datadog_api_client/v1/models/distribution_widget_request.rb +21 -1
  53. data/lib/datadog_api_client/v1/models/formula_and_function_apm_resource_stat_name.rb +1 -0
  54. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_usage_type.rb +2 -0
  55. data/lib/datadog_api_client/v1/models/ip_prefixes_synthetics_private_locations.rb +125 -0
  56. data/lib/datadog_api_client/v1/models/ip_ranges.rb +11 -1
  57. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_supported_metrics.rb +4 -0
  58. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_values.rb +41 -1
  59. data/lib/datadog_api_client/v1/models/org_downgraded_response.rb +111 -0
  60. data/lib/datadog_api_client/v1/models/organization.rb +14 -4
  61. data/lib/datadog_api_client/v1/models/search_slo_response.rb +131 -0
  62. data/lib/datadog_api_client/v1/models/search_slo_response_data.rb +121 -0
  63. data/lib/datadog_api_client/v1/models/search_slo_response_data_attributes.rb +123 -0
  64. data/lib/datadog_api_client/v1/models/search_slo_response_data_attributes_facets.rb +197 -0
  65. data/lib/datadog_api_client/v1/models/search_slo_response_data_attributes_facets_object_int.rb +121 -0
  66. data/lib/datadog_api_client/v1/models/search_slo_response_data_attributes_facets_object_string.rb +121 -0
  67. data/lib/datadog_api_client/v1/models/search_slo_response_links.rb +151 -0
  68. data/lib/datadog_api_client/v1/models/search_slo_response_meta.rb +111 -0
  69. data/lib/datadog_api_client/v1/models/search_slo_response_meta_page.rb +181 -0
  70. data/lib/datadog_api_client/v1/models/service_level_objective.rb +3 -3
  71. data/lib/datadog_api_client/v1/models/service_level_objective_query.rb +1 -1
  72. data/lib/datadog_api_client/v1/models/service_level_objective_request.rb +3 -3
  73. data/lib/datadog_api_client/v1/models/slo_history_metrics.rb +1 -1
  74. data/lib/datadog_api_client/v1/models/slo_response_data.rb +1 -1
  75. data/lib/datadog_api_client/v1/models/synthetics_api_test.rb +11 -0
  76. data/lib/datadog_api_client/v1/models/synthetics_browser_test.rb +11 -0
  77. data/lib/datadog_api_client/v1/models/synthetics_core_web_vitals.rb +2 -2
  78. data/lib/datadog_api_client/v1/models/synthetics_test_ci_options.rb +111 -0
  79. data/lib/datadog_api_client/v1/models/synthetics_test_options.rb +11 -1
  80. data/lib/datadog_api_client/v1/models/usage_attribution_sort.rb +4 -0
  81. data/lib/datadog_api_client/v1/models/usage_attribution_supported_metrics.rb +4 -0
  82. data/lib/datadog_api_client/v1/models/usage_attribution_values.rb +41 -1
  83. data/lib/datadog_api_client/v1/models/usage_billable_summary_keys.rb +474 -4
  84. data/lib/datadog_api_client/v1.rb +19 -0
  85. data/lib/datadog_api_client/v2/api/cloud_workload_security_api.rb +1 -1
  86. data/lib/datadog_api_client/v2/api/metrics_api.rb +0 -2
  87. data/lib/datadog_api_client/v2/api/opsgenie_integration_api.rb +395 -0
  88. data/lib/datadog_api_client/v2/api/usage_metering_api.rb +76 -0
  89. data/lib/datadog_api_client/v2/configuration.rb +0 -7
  90. data/lib/datadog_api_client/v2/models/intake_payload_accepted.rb +10 -8
  91. data/lib/datadog_api_client/v2/models/metric_tag_configuration_create_attributes.rb +0 -2
  92. data/lib/datadog_api_client/v2/models/metric_tag_configuration_update_attributes.rb +0 -2
  93. data/lib/datadog_api_client/v2/models/opsgenie_service_create_attributes.rb +174 -0
  94. data/lib/datadog_api_client/v2/models/opsgenie_service_create_data.rb +145 -0
  95. data/lib/datadog_api_client/v2/models/opsgenie_service_create_request.rb +122 -0
  96. data/lib/datadog_api_client/v2/models/opsgenie_service_region_type.rb +28 -0
  97. data/lib/datadog_api_client/v2/models/opsgenie_service_response.rb +122 -0
  98. data/lib/datadog_api_client/v2/models/opsgenie_service_response_attributes.rb +132 -0
  99. data/lib/datadog_api_client/v2/models/opsgenie_service_response_data.rb +166 -0
  100. data/lib/datadog_api_client/v2/models/opsgenie_service_type.rb +26 -0
  101. data/lib/datadog_api_client/v2/models/opsgenie_service_update_attributes.rb +142 -0
  102. data/lib/datadog_api_client/v2/models/opsgenie_service_update_data.rb +166 -0
  103. data/lib/datadog_api_client/v2/models/opsgenie_service_update_request.rb +122 -0
  104. data/lib/datadog_api_client/v2/models/opsgenie_services_response.rb +124 -0
  105. data/lib/datadog_api_client/v2/models/security_monitoring_rule_new_value_options.rb +30 -4
  106. data/lib/datadog_api_client/v2/models/security_monitoring_rule_new_value_options_learning_method.rb +27 -0
  107. data/lib/datadog_api_client/v2/models/security_monitoring_rule_new_value_options_learning_threshold.rb +27 -0
  108. data/lib/datadog_api_client/v2/models/security_monitoring_rule_options.rb +13 -1
  109. data/lib/datadog_api_client/v2.rb +15 -0
  110. data/lib/datadog_api_client/version.rb +1 -1
  111. metadata +51 -2
@@ -224,6 +224,13 @@ components:
224
224
  required: true
225
225
  schema:
226
226
  type: string
227
+ OpsgenieServiceIDPathParameter:
228
+ description: The UUID of the service.
229
+ in: path
230
+ name: integration_service_id
231
+ required: true
232
+ schema:
233
+ type: string
227
234
  PageNumber:
228
235
  description: Specific page number to return.
229
236
  in: query
@@ -2605,10 +2612,12 @@ components:
2605
2612
  IntakePayloadAccepted:
2606
2613
  description: The payload accepted for intake.
2607
2614
  properties:
2608
- status:
2609
- description: The status of the intake payload.
2610
- example: ok
2611
- type: string
2615
+ errors:
2616
+ description: A list of errors.
2617
+ items:
2618
+ description: An empty error list.
2619
+ type: string
2620
+ type: array
2612
2621
  type: object
2613
2622
  ListApplicationKeysResponse:
2614
2623
  description: Response for a list of application keys.
@@ -4310,7 +4319,6 @@ components:
4310
4319
  aggregations:
4311
4320
  $ref: '#/components/schemas/MetricCustomAggregations'
4312
4321
  include_percentiles:
4313
- default: false
4314
4322
  description: 'Toggle to include/exclude percentiles for a distribution metric.
4315
4323
 
4316
4324
  Defaults to false. Can only be applied to metrics that have a `metric_type`
@@ -4402,7 +4410,6 @@ components:
4402
4410
  aggregations:
4403
4411
  $ref: '#/components/schemas/MetricCustomAggregations'
4404
4412
  include_percentiles:
4405
- default: false
4406
4413
  description: 'Toggle to include/exclude percentiles for a distribution metric.
4407
4414
 
4408
4415
  Defaults to false. Can only be applied to metrics that have a `metric_type`
@@ -4510,6 +4517,174 @@ components:
4510
4517
  - id
4511
4518
  - type
4512
4519
  type: object
4520
+ OpsgenieServiceCreateAttributes:
4521
+ description: The Opsgenie service attributes for a create request.
4522
+ properties:
4523
+ custom_url:
4524
+ description: The custom URL for a custom region.
4525
+ example: https://example.com
4526
+ type: string
4527
+ name:
4528
+ description: The name for the Opsgenie service.
4529
+ example: fake-opsgenie-service-name
4530
+ type: string
4531
+ opsgenie_api_key:
4532
+ description: The Opsgenie API key for your Opsgenie service.
4533
+ example: 00000000-0000-0000-0000-000000000000
4534
+ type: string
4535
+ region:
4536
+ $ref: '#/components/schemas/OpsgenieServiceRegionType'
4537
+ required:
4538
+ - name
4539
+ - opsgenie_api_key
4540
+ - region
4541
+ type: object
4542
+ OpsgenieServiceCreateData:
4543
+ description: Opsgenie service data for a create request.
4544
+ properties:
4545
+ attributes:
4546
+ $ref: '#/components/schemas/OpsgenieServiceCreateAttributes'
4547
+ type:
4548
+ $ref: '#/components/schemas/OpsgenieServiceType'
4549
+ required:
4550
+ - type
4551
+ - attributes
4552
+ type: object
4553
+ OpsgenieServiceCreateRequest:
4554
+ description: Create request for an Opsgenie service.
4555
+ properties:
4556
+ data:
4557
+ $ref: '#/components/schemas/OpsgenieServiceCreateData'
4558
+ required:
4559
+ - data
4560
+ type: object
4561
+ OpsgenieServiceRegionType:
4562
+ description: The region for the Opsgenie service.
4563
+ enum:
4564
+ - us
4565
+ - eu
4566
+ - custom
4567
+ example: us
4568
+ type: string
4569
+ x-enum-varnames:
4570
+ - US
4571
+ - EU
4572
+ - CUSTOM
4573
+ OpsgenieServiceResponse:
4574
+ description: Response of an Opsgenie service.
4575
+ properties:
4576
+ data:
4577
+ $ref: '#/components/schemas/OpsgenieServiceResponseData'
4578
+ required:
4579
+ - data
4580
+ type: object
4581
+ OpsgenieServiceResponseAttributes:
4582
+ description: The attributes from an Opsgenie service response.
4583
+ properties:
4584
+ custom_url:
4585
+ description: The custom URL for a custom region.
4586
+ example: null
4587
+ nullable: true
4588
+ type: string
4589
+ name:
4590
+ description: The name for the Opsgenie service.
4591
+ example: fake-opsgenie-service-name
4592
+ type: string
4593
+ region:
4594
+ $ref: '#/components/schemas/OpsgenieServiceRegionType'
4595
+ type: object
4596
+ OpsgenieServiceResponseData:
4597
+ description: Opsgenie service data from a response.
4598
+ properties:
4599
+ attributes:
4600
+ $ref: '#/components/schemas/OpsgenieServiceResponseAttributes'
4601
+ id:
4602
+ description: The ID of the Opsgenie service.
4603
+ example: 596da4af-0563-4097-90ff-07230c3f9db3
4604
+ type: string
4605
+ type:
4606
+ $ref: '#/components/schemas/OpsgenieServiceType'
4607
+ required:
4608
+ - id
4609
+ - type
4610
+ - attributes
4611
+ type: object
4612
+ OpsgenieServiceType:
4613
+ default: opsgenie-service
4614
+ description: Opsgenie service resource type.
4615
+ enum:
4616
+ - opsgenie-service
4617
+ example: opsgenie-service
4618
+ type: string
4619
+ x-enum-varnames:
4620
+ - OPSGENIE_SERVICE
4621
+ OpsgenieServiceUpdateAttributes:
4622
+ description: The Opsgenie service attributes for an update request.
4623
+ properties:
4624
+ custom_url:
4625
+ description: The custom URL for a custom region.
4626
+ example: https://example.com
4627
+ nullable: true
4628
+ type: string
4629
+ name:
4630
+ description: The name for the Opsgenie service.
4631
+ example: fake-opsgenie-service-name
4632
+ type: string
4633
+ opsgenie_api_key:
4634
+ description: The Opsgenie API key for your Opsgenie service.
4635
+ example: 00000000-0000-0000-0000-000000000000
4636
+ type: string
4637
+ region:
4638
+ $ref: '#/components/schemas/OpsgenieServiceRegionType'
4639
+ type: object
4640
+ OpsgenieServiceUpdateData:
4641
+ description: Opsgenie service for an update request.
4642
+ properties:
4643
+ attributes:
4644
+ $ref: '#/components/schemas/OpsgenieServiceUpdateAttributes'
4645
+ id:
4646
+ description: The ID of the Opsgenie service.
4647
+ example: 596da4af-0563-4097-90ff-07230c3f9db3
4648
+ type: string
4649
+ type:
4650
+ $ref: '#/components/schemas/OpsgenieServiceType'
4651
+ required:
4652
+ - id
4653
+ - type
4654
+ - attributes
4655
+ type: object
4656
+ OpsgenieServiceUpdateRequest:
4657
+ description: Update request for an Opsgenie service.
4658
+ properties:
4659
+ data:
4660
+ $ref: '#/components/schemas/OpsgenieServiceUpdateData'
4661
+ required:
4662
+ - data
4663
+ type: object
4664
+ OpsgenieServicesResponse:
4665
+ description: Response with a list of Opsgenie services.
4666
+ properties:
4667
+ data:
4668
+ description: An array of Opsgenie services.
4669
+ example:
4670
+ - attributes:
4671
+ custom_url: null
4672
+ name: fake-opsgenie-service-name
4673
+ region: us
4674
+ id: 596da4af-0563-4097-90ff-07230c3f9db3
4675
+ type: opsgenie-service
4676
+ - attributes:
4677
+ custom_url: null
4678
+ name: fake-opsgenie-service-name-2
4679
+ region: eu
4680
+ id: 0d2937f1-b561-44fa-914a-99910f848014
4681
+ type: opsgenie-service
4682
+ items:
4683
+ $ref: '#/components/schemas/OpsgenieServiceResponseData'
4684
+ type: array
4685
+ required:
4686
+ - data
4687
+ type: object
4513
4688
  Organization:
4514
4689
  description: Organization object.
4515
4690
  properties:
@@ -6167,6 +6342,17 @@ components:
6167
6342
  - cases
6168
6343
  - message
6169
6344
  type: object
6345
+ SecurityMonitoringRuleDecreaseCriticalityBasedOnEnv:
6346
+ description: 'If true, signals in non-production environments have a lower severity
6347
+ than what is defined by the rule case, which can reduce signal noise.
6348
+
6349
+ The severity is decreased by one level: `CRITICAL` in production becomes `HIGH`
6350
+ in non-production, `HIGH` becomes `MEDIUM` and so on. `INFO` remains `INFO`.
6351
+
6352
+ The decrement is applied when the environment tag of the signal starts with
6353
+ `staging`, `test` or `dev`.'
6354
+ example: false
6355
+ type: boolean
6170
6356
  SecurityMonitoringRuleDetectionMethod:
6171
6357
  description: The detection method.
6172
6358
  enum:
@@ -6294,6 +6480,10 @@ components:
6294
6480
  $ref: '#/components/schemas/SecurityMonitoringRuleNewValueOptionsForgetAfter'
6295
6481
  learningDuration:
6296
6482
  $ref: '#/components/schemas/SecurityMonitoringRuleNewValueOptionsLearningDuration'
6483
+ learningMethod:
6484
+ $ref: '#/components/schemas/SecurityMonitoringRuleNewValueOptionsLearningMethod'
6485
+ learningThreshold:
6486
+ $ref: '#/components/schemas/SecurityMonitoringRuleNewValueOptionsLearningThreshold'
6297
6487
  type: object
6298
6488
  SecurityMonitoringRuleNewValueOptionsForgetAfter:
6299
6489
  description: The duration in days after which a learned value is forgotten.
@@ -6314,6 +6504,7 @@ components:
6314
6504
  - THREE_WEEKS
6315
6505
  - FOUR_WEEKS
6316
6506
  SecurityMonitoringRuleNewValueOptionsLearningDuration:
6507
+ default: 0
6317
6508
  description: 'The duration in days during which values are learned, and after
6318
6509
  which signals will be generated for values that
6319
6510
 
@@ -6329,9 +6520,34 @@ components:
6329
6520
  - ZERO_DAYS
6330
6521
  - ONE_DAY
6331
6522
  - SEVEN_DAYS
6523
+ SecurityMonitoringRuleNewValueOptionsLearningMethod:
6524
+ default: duration
6525
+ description: The learning method used to determine when signals should be generated
6526
+ for values that weren't learned.
6527
+ enum:
6528
+ - duration
6529
+ - threshold
6530
+ type: string
6531
+ x-enum-varnames:
6532
+ - DURATION
6533
+ - THRESHOLD
6534
+ SecurityMonitoringRuleNewValueOptionsLearningThreshold:
6535
+ default: 0
6536
+ description: A number of occurrences after which signals will be generated for
6537
+ values that weren't learned.
6538
+ enum:
6539
+ - 0
6540
+ - 1
6541
+ format: int32
6542
+ type: integer
6543
+ x-enum-varnames:
6544
+ - ZERO_OCCURRENCES
6545
+ - ONE_OCCURRENCE
6332
6546
  SecurityMonitoringRuleOptions:
6333
6547
  description: Options on rules.
6334
6548
  properties:
6549
+ decreaseCriticalityBasedOnEnv:
6550
+ $ref: '#/components/schemas/SecurityMonitoringRuleDecreaseCriticalityBasedOnEnv'
6335
6551
  detectionMethod:
6336
6552
  $ref: '#/components/schemas/SecurityMonitoringRuleDetectionMethod'
6337
6553
  evaluationWindow:
@@ -7136,7 +7352,6 @@ components:
7136
7352
  authorizationCode:
7137
7353
  authorizationUrl: /oauth2/v1/authorize
7138
7354
  scopes:
7139
- dashboards_public_share: Share dashboards externally.
7140
7355
  dashboards_read: View dashboards.
7141
7356
  dashboards_write: Create and change dashboards.
7142
7357
  events_read: Read Events data.
@@ -7144,6 +7359,8 @@ components:
7144
7359
  incident_settings_write: Configure Incidents settings.
7145
7360
  incident_write: Create, view, and manage incidents in Datadog.
7146
7361
  metrics_read: View custom metrics.
7362
+ monitors_read: View monitors.
7363
+ monitors_write: Edit, mute, and delete individual monitors.
7147
7364
  security_monitoring_filters_read: Read Security Filters.
7148
7365
  security_monitoring_filters_write: Create, edit, and delete Security Filters.
7149
7366
  security_monitoring_rules_read: Read Detection Rules.
@@ -8512,6 +8729,159 @@ paths:
8512
8729
  x-unstable: '**Note**: This endpoint is in public beta.
8513
8730
 
8514
8731
  If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
8732
+ /api/v2/integration/opsgenie/services:
8733
+ get:
8734
+ description: Get a list of all services from the Datadog Opsgenie integration.
8735
+ operationId: ListOpsgenieServices
8736
+ responses:
8737
+ '200':
8738
+ content:
8739
+ application/json:
8740
+ schema:
8741
+ $ref: '#/components/schemas/OpsgenieServicesResponse'
8742
+ description: OK
8743
+ '403':
8744
+ $ref: '#/components/responses/ForbiddenResponse'
8745
+ '429':
8746
+ $ref: '#/components/responses/TooManyRequestsResponse'
8747
+ summary: Get all service objects
8748
+ tags:
8749
+ - Opsgenie Integration
8750
+ x-menu-order: 1
8751
+ x-undo:
8752
+ type: safe
8753
+ post:
8754
+ description: Create a new service object in the Opsgenie integration.
8755
+ operationId: CreateOpsgenieService
8756
+ requestBody:
8757
+ content:
8758
+ application/json:
8759
+ schema:
8760
+ $ref: '#/components/schemas/OpsgenieServiceCreateRequest'
8761
+ description: Opsgenie service payload
8762
+ required: true
8763
+ responses:
8764
+ '201':
8765
+ content:
8766
+ application/json:
8767
+ schema:
8768
+ $ref: '#/components/schemas/OpsgenieServiceResponse'
8769
+ description: CREATED
8770
+ '400':
8771
+ $ref: '#/components/responses/BadRequestResponse'
8772
+ '403':
8773
+ $ref: '#/components/responses/ForbiddenResponse'
8774
+ '409':
8775
+ $ref: '#/components/responses/ConflictResponse'
8776
+ '429':
8777
+ $ref: '#/components/responses/TooManyRequestsResponse'
8778
+ summary: Create a new service object
8779
+ tags:
8780
+ - Opsgenie Integration
8781
+ x-codegen-request-body-name: body
8782
+ x-given:
8783
+ opsgenie_service:
8784
+ parameters:
8785
+ - name: body
8786
+ value: "{\n \"data\": {\n \"attributes\": {\n \"name\": \"{{
8787
+ unique }}\",\n \"opsgenie_api_key\": \"00000000-0000-0000-0000-000000000000\",\n
8788
+ \ \"region\": \"us\"\n },\n \"type\": \"opsgenie-service\"\n
8789
+ \ }\n}"
8790
+ step: there is a valid "opsgenie_service" in the system
8791
+ x-menu-order: 2
8792
+ x-undo:
8793
+ operationId: DeleteOpsgenieService
8794
+ parameters:
8795
+ - name: integration_service_id
8796
+ source: data.id
8797
+ type: unsafe
8798
+ /api/v2/integration/opsgenie/services/{integration_service_id}:
8799
+ delete:
8800
+ description: Delete a single service object in the Datadog Opsgenie integration.
8801
+ operationId: DeleteOpsgenieService
8802
+ parameters:
8803
+ - $ref: '#/components/parameters/OpsgenieServiceIDPathParameter'
8804
+ responses:
8805
+ '204':
8806
+ description: OK
8807
+ '400':
8808
+ $ref: '#/components/responses/BadRequestResponse'
8809
+ '403':
8810
+ $ref: '#/components/responses/ForbiddenResponse'
8811
+ '404':
8812
+ $ref: '#/components/responses/NotFoundResponse'
8813
+ '429':
8814
+ $ref: '#/components/responses/TooManyRequestsResponse'
8815
+ summary: Delete a single service object
8816
+ tags:
8817
+ - Opsgenie Integration
8818
+ x-menu-order: 5
8819
+ x-undo:
8820
+ type: idempotent
8821
+ get:
8822
+ description: Get a single service from the Datadog Opsgenie integration.
8823
+ operationId: GetOpsgenieService
8824
+ parameters:
8825
+ - $ref: '#/components/parameters/OpsgenieServiceIDPathParameter'
8826
+ responses:
8827
+ '200':
8828
+ content:
8829
+ application/json:
8830
+ schema:
8831
+ $ref: '#/components/schemas/OpsgenieServiceResponse'
8832
+ description: OK
8833
+ '400':
8834
+ $ref: '#/components/responses/BadRequestResponse'
8835
+ '403':
8836
+ $ref: '#/components/responses/ForbiddenResponse'
8837
+ '404':
8838
+ $ref: '#/components/responses/NotFoundResponse'
8839
+ '409':
8840
+ $ref: '#/components/responses/ConflictResponse'
8841
+ '429':
8842
+ $ref: '#/components/responses/TooManyRequestsResponse'
8843
+ summary: Get a single service object
8844
+ tags:
8845
+ - Opsgenie Integration
8846
+ x-menu-order: 3
8847
+ x-undo:
8848
+ type: safe
8849
+ patch:
8850
+ description: Update a single service object in the Datadog Opsgenie integration.
8851
+ operationId: UpdateOpsgenieService
8852
+ parameters:
8853
+ - $ref: '#/components/parameters/OpsgenieServiceIDPathParameter'
8854
+ requestBody:
8855
+ content:
8856
+ application/json:
8857
+ schema:
8858
+ $ref: '#/components/schemas/OpsgenieServiceUpdateRequest'
8859
+ description: Opsgenie service payload.
8860
+ required: true
8861
+ responses:
8862
+ '200':
8863
+ content:
8864
+ application/json:
8865
+ schema:
8866
+ $ref: '#/components/schemas/OpsgenieServiceResponse'
8867
+ description: OK
8868
+ '400':
8869
+ $ref: '#/components/responses/BadRequestResponse'
8870
+ '403':
8871
+ $ref: '#/components/responses/ForbiddenResponse'
8872
+ '404':
8873
+ $ref: '#/components/responses/NotFoundResponse'
8874
+ '409':
8875
+ $ref: '#/components/responses/ConflictResponse'
8876
+ '429':
8877
+ $ref: '#/components/responses/TooManyRequestsResponse'
8878
+ summary: Update a single service object
8879
+ tags:
8880
+ - Opsgenie Integration
8881
+ x-codegen-request-body-name: body
8882
+ x-menu-order: 4
8883
+ x-undo:
8884
+ type: idempotent
8515
8885
  /api/v2/logs:
8516
8886
  post:
8517
8887
  description: 'Send your logs to your Datadog platform over HTTP. Limits per
@@ -9575,10 +9945,6 @@ paths:
9575
9945
  x-menu-order: 5
9576
9946
  x-undo:
9577
9947
  type: safe
9578
- x-unstable: "**Note: Use of this endpoint for count/gauge/rate metric types
9579
- is only accessible for Metrics without Limits™ beta customers.\nIf you\u2019re
9580
- interested in Metrics without Limits™, please contact your Customer
9581
- Success Manager.**"
9582
9948
  /api/v2/metrics/config/bulk-tags:
9583
9949
  delete:
9584
9950
  description: 'Delete all custom lists of queryable tag keys for a set of existing
@@ -9885,10 +10251,6 @@ paths:
9885
10251
  x-menu-order: 4
9886
10252
  x-undo:
9887
10253
  type: idempotent
9888
- x-unstable: "**Note: Use of this endpoint for count/gauge/rate metric types
9889
- is only accessible for Metrics without Limits™ beta customers.\nIf you\u2019re
9890
- interested in Metrics without Limits™, please contact your Customer
9891
- Success Manager.**"
9892
10254
  get:
9893
10255
  description: Returns the tag configuration for the given metric name.
9894
10256
  operationId: ListTagConfigurationByName
@@ -9925,10 +10287,6 @@ paths:
9925
10287
  x-menu-order: 2
9926
10288
  x-undo:
9927
10289
  type: safe
9928
- x-unstable: "**Note: Use of this endpoint for count/gauge/rate metric types
9929
- is only accessible for Metrics without Limits™ beta customers.\nIf you\u2019re
9930
- interested in Metrics without Limits™, please contact your Customer
9931
- Success Manager.**"
9932
10290
  patch:
9933
10291
  description: 'Update the tag configuration of a metric or percentile aggregations
9934
10292
  of a distribution metric or custom aggregations
@@ -9984,10 +10342,6 @@ paths:
9984
10342
  x-menu-order: 3
9985
10343
  x-undo:
9986
10344
  type: idempotent
9987
- x-unstable: "**Note: Use of this endpoint for count/gauge/rate metric types
9988
- is only accessible for Metrics without Limits™ beta customers.\nIf you\u2019re
9989
- interested in Metrics without Limits™, please contact your Customer
9990
- Success Manager.**"
9991
10345
  post:
9992
10346
  description: 'Create and define a list of queryable tag keys for an existing
9993
10347
  count/gauge/rate/distribution metric.
@@ -10061,21 +10415,11 @@ paths:
10061
10415
  - name: metric_name
10062
10416
  source: data.id
10063
10417
  type: unsafe
10064
- x-unstable: "**Note: Use of this endpoint for count/gauge/rate metric types
10065
- is only accessible for Metrics without Limits™ beta customers.\nIf you\u2019re
10066
- interested in Metrics without Limits™, please contact your Customer
10067
- Success Manager.**"
10068
10418
  /api/v2/metrics/{metric_name}/volumes:
10069
10419
  get:
10070
10420
  description: 'View distinct metrics volumes for the given metric name.
10071
10421
 
10072
10422
 
10073
- Custom distribution metrics will return both ingested and indexed custom metric
10074
- volumes.
10075
-
10076
- For Metrics without Limits™ beta customers, all metrics will return
10077
- both ingested/indexed volumes.
10078
-
10079
10423
  Custom metrics generated in-app from other products will return `null` for
10080
10424
  ingested volumes.'
10081
10425
  operationId: ListVolumesByMetricName
@@ -11096,11 +11440,6 @@ paths:
11096
11440
  $ref: '#/components/responses/NotAuthorizedResponse'
11097
11441
  '429':
11098
11442
  $ref: '#/components/responses/TooManyRequestsResponse'
11099
- security:
11100
- - apiKeyAuth: []
11101
- appKeyAuth: []
11102
- - AuthZ:
11103
- - security_monitoring_rules_read
11104
11443
  summary: Get the latest Cloud Workload Security policy
11105
11444
  tags:
11106
11445
  - Cloud Workload Security
@@ -11702,9 +12041,6 @@ paths:
11702
12041
  resultsPath: data
11703
12042
  x-undo:
11704
12043
  type: safe
11705
- x-unstable: '**Note**: This endpoint is in public beta.
11706
-
11707
- If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
11708
12044
  /api/v2/security_monitoring/signals/search:
11709
12045
  post:
11710
12046
  description: 'Returns security signals that match a search query.
@@ -11749,9 +12085,6 @@ paths:
11749
12085
  resultsPath: data
11750
12086
  x-undo:
11751
12087
  type: safe
11752
- x-unstable: '**Note**: This endpoint is in public beta.
11753
-
11754
- If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
11755
12088
  /api/v2/series:
11756
12089
  post:
11757
12090
  description: "The metrics end-point allows you to post time-series data that
@@ -12615,6 +12948,81 @@ paths:
12615
12948
  x-menu-order: 39
12616
12949
  x-undo:
12617
12950
  type: safe
12951
+ /api/v2/usage/estimated_cost_by_org:
12952
+ get:
12953
+ description: Get estimated cost across multi-org account.
12954
+ operationId: GetEstimatedCostByOrg
12955
+ parameters:
12956
+ - description: 'Datetime in ISO-8601 format, UTC, precise to month: `[YYYY-MM]`
12957
+ for cost beginning this month. Either start_month or start_date should be
12958
+ specified, but not both.'
12959
+ in: query
12960
+ name: start_month
12961
+ required: false
12962
+ schema:
12963
+ format: date-time
12964
+ type: string
12965
+ - description: 'Datetime in ISO-8601 format, UTC, precise to month: `[YYYY-MM]`
12966
+ for cost ending this month.'
12967
+ in: query
12968
+ name: end_month
12969
+ required: false
12970
+ schema:
12971
+ format: date-time
12972
+ type: string
12973
+ - description: 'Datetime in ISO-8601 format, UTC, precise to day: `[YYYY-MM-DD]`
12974
+ for cost beginning this day. Either start_month or start_date should be
12975
+ specified, but not both.'
12976
+ in: query
12977
+ name: start_date
12978
+ required: false
12979
+ schema:
12980
+ format: date-time
12981
+ type: string
12982
+ - description: 'Datetime in ISO-8601 format, UTC, precise to day: `[YYYY-MM-DD]`
12983
+ for cost ending this day.'
12984
+ in: query
12985
+ name: end_date
12986
+ required: false
12987
+ schema:
12988
+ format: date-time
12989
+ type: string
12990
+ responses:
12991
+ '200':
12992
+ content:
12993
+ application/json;datetime-format=rfc3339:
12994
+ schema:
12995
+ $ref: '#/components/schemas/CostByOrgResponse'
12996
+ description: OK
12997
+ '400':
12998
+ content:
12999
+ application/json;datetime-format=rfc3339:
13000
+ schema:
13001
+ $ref: '#/components/schemas/APIErrorResponse'
13002
+ description: Bad Request
13003
+ '403':
13004
+ content:
13005
+ application/json;datetime-format=rfc3339:
13006
+ schema:
13007
+ $ref: '#/components/schemas/APIErrorResponse'
13008
+ description: Forbidden - User is not authorized
13009
+ '429':
13010
+ content:
13011
+ application/json;datetime-format=rfc3339:
13012
+ schema:
13013
+ $ref: '#/components/schemas/APIErrorResponse'
13014
+ description: Too many requests
13015
+ security:
13016
+ - apiKeyAuth: []
13017
+ appKeyAuth: []
13018
+ - AuthZ:
13019
+ - usage_read
13020
+ summary: Get estimated cost across multi-org account
13021
+ tags:
13022
+ - Usage Metering
13023
+ x-menu-order: 39
13024
+ x-undo:
13025
+ type: safe
12618
13026
  /api/v2/usage/lambda_traced_invocations:
12619
13027
  get:
12620
13028
  description: Get hourly usage for Lambda Traced Invocations.
@@ -13273,6 +13681,12 @@ tags:
13273
13681
  that set number.\n\nThe Post, Patch, and Delete `manage_tags` API methods can
13274
13682
  only be performed by\na user who has the `Manage Tags for Metrics` permission."
13275
13683
  name: Metrics
13684
+ - description: 'Configure your [Datadog Opsgenie integration](https://docs.datadoghq.com/integrations/opsgenie/)
13685
+
13686
+ directly through the Datadog API.'
13687
+ externalDocs:
13688
+ url: https://docs.datadoghq.com/api/latest/opsgenie-integration
13689
+ name: Opsgenie Integration
13276
13690
  - description: Create, edit, and manage your organizations. Read more about [multi-org
13277
13691
  accounts](https://docs.datadoghq.com/account_management/multi_organization).
13278
13692
  externalDocs:
@@ -273,6 +273,20 @@ def format_data_with_schema_list(
273
273
  ):
274
274
  name = get_name(schema)
275
275
 
276
+ if "oneOf" in schema:
277
+ for sub_schema in schema["oneOf"]:
278
+ try:
279
+ value = format_data_with_schema(
280
+ data,
281
+ sub_schema,
282
+ replace_values=replace_values,
283
+ default_name=name,
284
+ )
285
+ except (KeyError, ValueError) as e:
286
+ continue
287
+ return value
288
+ raise ValueError(f"{data} is not valid oneOf {schema}")
289
+
276
290
  parameters = ""
277
291
  for d in data:
278
292
  value = format_data_with_schema(
@@ -49,13 +49,6 @@ jobs:
49
49
  repo: datadog-api-spec
50
50
  status: pending
51
51
  context: integration
52
- - name: Report source code metadata
53
- run: |
54
- curl -L "https://github.com/DataDog/datadog-ci/releases/latest/download/datadog-ci_linux-x64" --output ./datadog-ci
55
- chmod +x "./datadog-ci"
56
- ./datadog-ci git-metadata upload
57
- env:
58
- DATADOG_API_KEY: ${{ secrets.DD_API_KEY }}
59
52
  - name: Set up Ruby 3.1
60
53
  uses: ruby/setup-ruby@v1
61
54
  with: