Skip to content

Commit 87cfa93

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit 41ffb5f of spec repo (#3200)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 088a162 commit 87cfa93

16 files changed

+6863
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32179,6 +32179,53 @@ components:
3217932179
type: string
3218032180
type: array
3218132181
type: object
32182+
Integration:
32183+
description: Integration resource object.
32184+
properties:
32185+
attributes:
32186+
$ref: '#/components/schemas/IntegrationAttributes'
32187+
id:
32188+
description: The unique identifier of the integration.
32189+
example: calico
32190+
type: string
32191+
links:
32192+
$ref: '#/components/schemas/IntegrationLinks'
32193+
type:
32194+
$ref: '#/components/schemas/IntegrationType'
32195+
required:
32196+
- type
32197+
- id
32198+
- attributes
32199+
type: object
32200+
IntegrationAttributes:
32201+
description: Attributes for an integration.
32202+
properties:
32203+
categories:
32204+
description: List of categories associated with the integration.
32205+
example:
32206+
- Category::Kubernetes
32207+
- Category::Log Collection
32208+
items:
32209+
type: string
32210+
type: array
32211+
description:
32212+
description: A description of the integration.
32213+
example: Calico is a networking and network security solution for containers.
32214+
type: string
32215+
installed:
32216+
description: Whether the integration is installed.
32217+
example: true
32218+
type: boolean
32219+
title:
32220+
description: The name of the integration.
32221+
example: calico
32222+
type: string
32223+
required:
32224+
- title
32225+
- description
32226+
- categories
32227+
- installed
32228+
type: object
3218232229
IntegrationIncident:
3218332230
description: Incident integration settings
3218432231
properties:
@@ -32284,6 +32331,14 @@ components:
3228432331
value:
3228532332
$ref: '#/components/schemas/AnyValue'
3228632333
type: object
32334+
IntegrationLinks:
32335+
description: Links for the integration resource.
32336+
properties:
32337+
self:
32338+
description: Link to the integration resource.
32339+
example: /integrations?integrationId=calico
32340+
type: string
32341+
type: object
3228732342
IntegrationMonitor:
3228832343
description: Monitor integration settings
3228932344
properties:
@@ -32385,6 +32440,15 @@ components:
3238532440
type: string
3238632441
type: object
3238732442
type: object
32443+
IntegrationType:
32444+
default: integration
32445+
description: Integration resource type.
32446+
enum:
32447+
- integration
32448+
example: integration
32449+
type: string
32450+
x-enum-varnames:
32451+
- INTEGRATION
3238832452
InterfaceAttributes:
3238932453
description: The interface attributes
3239032454
properties:
@@ -34776,6 +34840,17 @@ components:
3477634840
- data
3477734841
- meta
3477834842
type: object
34843+
ListIntegrationsResponse:
34844+
description: Response containing information about multiple integrations.
34845+
properties:
34846+
data:
34847+
description: Array of integration objects.
34848+
items:
34849+
$ref: '#/components/schemas/Integration'
34850+
type: array
34851+
required:
34852+
- data
34853+
type: object
3477934854
ListInterfaceTagsResponse:
3478034855
description: Response for listing interface tags.
3478134856
properties:
@@ -84205,6 +84280,24 @@ paths:
8420584280
x-unstable: '**Note**: This endpoint is in public beta and is subject to change.
8420684281

8420784282
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
84283+
/api/v2/integrations:
84284+
get:
84285+
operationId: ListIntegrations
84286+
responses:
84287+
'200':
84288+
content:
84289+
application/json:
84290+
schema:
84291+
$ref: '#/components/schemas/ListIntegrationsResponse'
84292+
description: Successful Response.
84293+
'429':
84294+
$ref: '#/components/responses/TooManyRequestsResponse'
84295+
security:
84296+
- apiKeyAuth: []
84297+
appKeyAuth: []
84298+
summary: List Integrations
84299+
tags:
84300+
- Integrations
8420884301
/api/v2/integrations/cloudflare/accounts:
8420984302
get:
8421084303
description: List Cloudflare accounts.
@@ -106288,6 +106381,10 @@ tags:
106288106381
and todos. See the [Incident Management page](https://docs.datadoghq.com/service_management/incident_management/)
106289106382
for more information.
106290106383
name: Incidents
106384+
- description: 'The Integrations API is used to list available integrations
106385+
106386+
and retrieve information about their installation status.'
106387+
name: Integrations
106291106388
- description: Manage your Jira Integration. Atlassian Jira is a project management
106292106389
and issue tracking tool for teams to coordinate work and handle tasks efficiently.
106293106390
name: Jira Integration

docs/datadog_api_client.v2.api.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -326,6 +326,13 @@ datadog\_api\_client.v2.api.incidents\_api module
326326
:members:
327327
:show-inheritance:
328328

329+
datadog\_api\_client.v2.api.integrations\_api module
330+
----------------------------------------------------
331+
332+
.. automodule:: datadog_api_client.v2.api.integrations_api
333+
:members:
334+
:show-inheritance:
335+
329336
datadog\_api\_client.v2.api.ip\_allowlist\_api module
330337
-----------------------------------------------------
331338

docs/datadog_api_client.v2.model.rst

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13640,6 +13640,20 @@ datadog\_api\_client.v2.model.intake\_payload\_accepted module
1364013640
:members:
1364113641
:show-inheritance:
1364213642

13643+
datadog\_api\_client.v2.model.integration module
13644+
------------------------------------------------
13645+
13646+
.. automodule:: datadog_api_client.v2.model.integration
13647+
:members:
13648+
:show-inheritance:
13649+
13650+
datadog\_api\_client.v2.model.integration\_attributes module
13651+
------------------------------------------------------------
13652+
13653+
.. automodule:: datadog_api_client.v2.model.integration_attributes
13654+
:members:
13655+
:show-inheritance:
13656+
1364313657
datadog\_api\_client.v2.model.integration\_incident module
1364413658
----------------------------------------------------------
1364513659

@@ -13710,6 +13724,13 @@ datadog\_api\_client.v2.model.integration\_jira\_sync\_properties\_custom\_field
1371013724
:members:
1371113725
:show-inheritance:
1371213726

13727+
datadog\_api\_client.v2.model.integration\_links module
13728+
-------------------------------------------------------
13729+
13730+
.. automodule:: datadog_api_client.v2.model.integration_links
13731+
:members:
13732+
:show-inheritance:
13733+
1371313734
datadog\_api\_client.v2.model.integration\_monitor module
1371413735
---------------------------------------------------------
1371513736

@@ -13773,6 +13794,13 @@ datadog\_api\_client.v2.model.integration\_service\_now\_sync\_config\_priority
1377313794
:members:
1377413795
:show-inheritance:
1377513796

13797+
datadog\_api\_client.v2.model.integration\_type module
13798+
------------------------------------------------------
13799+
13800+
.. automodule:: datadog_api_client.v2.model.integration_type
13801+
:members:
13802+
:show-inheritance:
13803+
1377613804
datadog\_api\_client.v2.model.interface\_attributes module
1377713805
----------------------------------------------------------
1377813806

@@ -14970,6 +14998,13 @@ datadog\_api\_client.v2.model.list\_findings\_response module
1497014998
:members:
1497114999
:show-inheritance:
1497215000

15001+
datadog\_api\_client.v2.model.list\_integrations\_response module
15002+
-----------------------------------------------------------------
15003+
15004+
.. automodule:: datadog_api_client.v2.model.list_integrations_response
15005+
:members:
15006+
:show-inheritance:
15007+
1497315008
datadog\_api\_client.v2.model.list\_interface\_tags\_response module
1497415009
--------------------------------------------------------------------
1497515010

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
"""
2+
List Integrations returns "Successful Response." response
3+
"""
4+
5+
from datadog_api_client import ApiClient, Configuration
6+
from datadog_api_client.v2.api.integrations_api import IntegrationsApi
7+
8+
configuration = Configuration()
9+
with ApiClient(configuration) as api_client:
10+
api_instance = IntegrationsApi(api_client)
11+
response = api_instance.list_integrations()
12+
13+
print(response)
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
from typing import Any, Dict
7+
8+
from datadog_api_client.api_client import ApiClient, Endpoint as _Endpoint
9+
from datadog_api_client.configuration import Configuration
10+
from datadog_api_client.v2.model.list_integrations_response import ListIntegrationsResponse
11+
12+
13+
class IntegrationsApi:
14+
"""
15+
The Integrations API is used to list available integrations
16+
and retrieve information about their installation status.
17+
"""
18+
19+
def __init__(self, api_client=None):
20+
if api_client is None:
21+
api_client = ApiClient(Configuration())
22+
self.api_client = api_client
23+
24+
self._list_integrations_endpoint = _Endpoint(
25+
settings={
26+
"response_type": (ListIntegrationsResponse,),
27+
"auth": ["apiKeyAuth", "appKeyAuth"],
28+
"endpoint_path": "/api/v2/integrations",
29+
"operation_id": "list_integrations",
30+
"http_method": "GET",
31+
"version": "v2",
32+
},
33+
params_map={},
34+
headers_map={
35+
"accept": ["application/json"],
36+
},
37+
api_client=api_client,
38+
)
39+
40+
def list_integrations(
41+
self,
42+
) -> ListIntegrationsResponse:
43+
"""List Integrations.
44+
45+
:rtype: ListIntegrationsResponse
46+
"""
47+
kwargs: Dict[str, Any] = {}
48+
return self._list_integrations_endpoint.call_with_http_info(**kwargs)

src/datadog_api_client/v2/apis/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@
4545
from datadog_api_client.v2.api.incident_services_api import IncidentServicesApi
4646
from datadog_api_client.v2.api.incident_teams_api import IncidentTeamsApi
4747
from datadog_api_client.v2.api.incidents_api import IncidentsApi
48+
from datadog_api_client.v2.api.integrations_api import IntegrationsApi
4849
from datadog_api_client.v2.api.jira_integration_api import JiraIntegrationApi
4950
from datadog_api_client.v2.api.key_management_api import KeyManagementApi
5051
from datadog_api_client.v2.api.logs_api import LogsApi
@@ -148,6 +149,7 @@
148149
"IncidentServicesApi",
149150
"IncidentTeamsApi",
150151
"IncidentsApi",
152+
"IntegrationsApi",
151153
"JiraIntegrationApi",
152154
"KeyManagementApi",
153155
"LogsApi",
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
from typing import Union, TYPE_CHECKING
7+
8+
from datadog_api_client.model_utils import (
9+
ModelNormal,
10+
cached_property,
11+
unset,
12+
UnsetType,
13+
)
14+
15+
16+
if TYPE_CHECKING:
17+
from datadog_api_client.v2.model.integration_attributes import IntegrationAttributes
18+
from datadog_api_client.v2.model.integration_links import IntegrationLinks
19+
from datadog_api_client.v2.model.integration_type import IntegrationType
20+
21+
22+
class Integration(ModelNormal):
23+
@cached_property
24+
def openapi_types(_):
25+
from datadog_api_client.v2.model.integration_attributes import IntegrationAttributes
26+
from datadog_api_client.v2.model.integration_links import IntegrationLinks
27+
from datadog_api_client.v2.model.integration_type import IntegrationType
28+
29+
return {
30+
"attributes": (IntegrationAttributes,),
31+
"id": (str,),
32+
"links": (IntegrationLinks,),
33+
"type": (IntegrationType,),
34+
}
35+
36+
attribute_map = {
37+
"attributes": "attributes",
38+
"id": "id",
39+
"links": "links",
40+
"type": "type",
41+
}
42+
43+
def __init__(
44+
self_,
45+
attributes: IntegrationAttributes,
46+
id: str,
47+
type: IntegrationType,
48+
links: Union[IntegrationLinks, UnsetType] = unset,
49+
**kwargs,
50+
):
51+
"""
52+
Integration resource object.
53+
54+
:param attributes: Attributes for an integration.
55+
:type attributes: IntegrationAttributes
56+
57+
:param id: The unique identifier of the integration.
58+
:type id: str
59+
60+
:param links: Links for the integration resource.
61+
:type links: IntegrationLinks, optional
62+
63+
:param type: Integration resource type.
64+
:type type: IntegrationType
65+
"""
66+
if links is not unset:
67+
kwargs["links"] = links
68+
super().__init__(kwargs)
69+
70+
self_.attributes = attributes
71+
self_.id = id
72+
self_.type = type

0 commit comments

Comments
 (0)