Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typo in service definition field #1754

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2023-11-06 16:31:16.204614",
"spec_repo_commit": "62fc6756"
"regenerated": "2023-11-07 09:02:06.404689",
"spec_repo_commit": "c7428dad"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2023-11-06 16:31:16.221809",
"spec_repo_commit": "62fc6756"
"regenerated": "2023-11-07 09:02:06.418647",
"spec_repo_commit": "c7428dad"
}
}
}
2 changes: 1 addition & 1 deletion .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16378,7 +16378,7 @@ components:
type: object
integrations:
$ref: '#/components/schemas/ServiceDefinitionV2Dot2Integrations'
langauges:
languages:
description: 'The service''s programming language. Datadog recognizes the
following languages: `dotnet`, `go`, `java`, `js`, `php`, `python`, `ruby`,
and `c++`.'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
service_url="https://my-org.pagerduty.com/service-directory/PMyService",
),
),
langauges=[
languages=[
"dotnet",
"go",
"java",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ def __init__(self, **kwargs):
:param tier: Importance of the service.
:type tier: str, optional

:param langauges: The service's programming language. Datadog recognizes the following languages: `dotnet`, `go`, `java`, `js`, `php`, `python`, `ruby`, and `c++`.
:type langauges: [str], optional
:param languages: The service's programming language. Datadog recognizes the following languages: `dotnet`, `go`, `java`, `js`, `php`, `python`, `ruby`, and `c++`.
:type languages: [str], optional

:param type: The type of service.
:type type: ServiceDefinitionV2Dot2Type, optional
Expand Down
14 changes: 7 additions & 7 deletions src/datadog_api_client/v2/model/service_definition_v2_dot2.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def openapi_types(_):
},
),
"integrations": (ServiceDefinitionV2Dot2Integrations,),
"langauges": ([str],),
"languages": ([str],),
"lifecycle": (str,),
"links": ([ServiceDefinitionV2Dot2Link],),
"schema_version": (ServiceDefinitionV2Dot2Version,),
Expand All @@ -75,7 +75,7 @@ def openapi_types(_):
"description": "description",
"extensions": "extensions",
"integrations": "integrations",
"langauges": "langauges",
"languages": "languages",
"lifecycle": "lifecycle",
"links": "links",
"schema_version": "schema-version",
Expand All @@ -94,7 +94,7 @@ def __init__(
description: Union[str, UnsetType] = unset,
extensions: Union[Dict[str, Any], UnsetType] = unset,
integrations: Union[ServiceDefinitionV2Dot2Integrations, UnsetType] = unset,
langauges: Union[List[str], UnsetType] = unset,
languages: Union[List[str], UnsetType] = unset,
lifecycle: Union[str, UnsetType] = unset,
links: Union[List[ServiceDefinitionV2Dot2Link], UnsetType] = unset,
tags: Union[List[str], UnsetType] = unset,
Expand Down Expand Up @@ -124,8 +124,8 @@ def __init__(
:param integrations: Third party integrations that Datadog supports.
:type integrations: ServiceDefinitionV2Dot2Integrations, optional

:param langauges: The service's programming language. Datadog recognizes the following languages: ``dotnet`` , ``go`` , ``java`` , ``js`` , ``php`` , ``python`` , ``ruby`` , and ``c++``.
:type langauges: [str], optional
:param languages: The service's programming language. Datadog recognizes the following languages: ``dotnet`` , ``go`` , ``java`` , ``js`` , ``php`` , ``python`` , ``ruby`` , and ``c++``.
:type languages: [str], optional

:param lifecycle: The current life cycle phase of the service.
:type lifecycle: str, optional
Expand Down Expand Up @@ -158,8 +158,8 @@ def __init__(
kwargs["extensions"] = extensions
if integrations is not unset:
kwargs["integrations"] = integrations
if langauges is not unset:
kwargs["langauges"] = langauges
if languages is not unset:
kwargs["languages"] = languages
if lifecycle is not unset:
kwargs["lifecycle"] = lifecycle
if links is not unset:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ def __init__(self, **kwargs):
:param integrations: Third party integrations that Datadog supports.
:type integrations: ServiceDefinitionV2Dot2Integrations, optional

:param langauges: The service's programming language. Datadog recognizes the following languages: `dotnet`, `go`, `java`, `js`, `php`, `python`, `ruby`, and `c++`.
:type langauges: [str], optional
:param languages: The service's programming language. Datadog recognizes the following languages: `dotnet`, `go`, `java`, `js`, `php`, `python`, `ruby`, and `c++`.
:type languages: [str], optional

:param lifecycle: The current life cycle phase of the service.
:type lifecycle: str, optional
Expand Down
6 changes: 3 additions & 3 deletions tests/v2/features/service_definition.feature
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@ Feature: Service Definition
@generated @skip @team:DataDog/service-catalog
Scenario: Create or update service definition returns "Bad Request" response
Given new "CreateOrUpdateServiceDefinitions" request
And body with value {"application": "my-app", "contacts": [{"contact": "https://teams.microsoft.com/myteam", "name": "My team channel", "type": "slack"}], "dd-service": "my-service", "description": "My service description", "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-url": "https://my-org.opsgenie.com/service/123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": {"service-url": "https://my-org.pagerduty.com/service-directory/PMyService"}}, "langauges": ["dotnet", "go", "java", "js", "php", "python", "ruby", "c++"], "lifecycle": "sandbox", "links": [{"name": "Runbook", "provider": "Github", "type": "runbook", "url": "https://my-runbook"}], "schema-version": "v2.2", "tags": ["my:tag", "service:tag"], "team": "my-team", "tier": "High", "type": "web"}
And body with value {"application": "my-app", "contacts": [{"contact": "https://teams.microsoft.com/myteam", "name": "My team channel", "type": "slack"}], "dd-service": "my-service", "description": "My service description", "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-url": "https://my-org.opsgenie.com/service/123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": {"service-url": "https://my-org.pagerduty.com/service-directory/PMyService"}}, "languages": ["dotnet", "go", "java", "js", "php", "python", "ruby", "c++"], "lifecycle": "sandbox", "links": [{"name": "Runbook", "provider": "Github", "type": "runbook", "url": "https://my-runbook"}], "schema-version": "v2.2", "tags": ["my:tag", "service:tag"], "team": "my-team", "tier": "High", "type": "web"}
When the request is sent
Then the response status is 400 Bad Request

@generated @skip @team:DataDog/service-catalog
Scenario: Create or update service definition returns "CREATED" response
Given new "CreateOrUpdateServiceDefinitions" request
And body with value {"application": "my-app", "contacts": [{"contact": "https://teams.microsoft.com/myteam", "name": "My team channel", "type": "slack"}], "dd-service": "my-service", "description": "My service description", "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-url": "https://my-org.opsgenie.com/service/123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": {"service-url": "https://my-org.pagerduty.com/service-directory/PMyService"}}, "langauges": ["dotnet", "go", "java", "js", "php", "python", "ruby", "c++"], "lifecycle": "sandbox", "links": [{"name": "Runbook", "provider": "Github", "type": "runbook", "url": "https://my-runbook"}], "schema-version": "v2.2", "tags": ["my:tag", "service:tag"], "team": "my-team", "tier": "High", "type": "web"}
And body with value {"application": "my-app", "contacts": [{"contact": "https://teams.microsoft.com/myteam", "name": "My team channel", "type": "slack"}], "dd-service": "my-service", "description": "My service description", "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-url": "https://my-org.opsgenie.com/service/123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": {"service-url": "https://my-org.pagerduty.com/service-directory/PMyService"}}, "languages": ["dotnet", "go", "java", "js", "php", "python", "ruby", "c++"], "lifecycle": "sandbox", "links": [{"name": "Runbook", "provider": "Github", "type": "runbook", "url": "https://my-runbook"}], "schema-version": "v2.2", "tags": ["my:tag", "service:tag"], "team": "my-team", "tier": "High", "type": "web"}
When the request is sent
Then the response status is 200 CREATED

@generated @skip @team:DataDog/service-catalog
Scenario: Create or update service definition returns "Conflict" response
Given new "CreateOrUpdateServiceDefinitions" request
And body with value {"application": "my-app", "contacts": [{"contact": "https://teams.microsoft.com/myteam", "name": "My team channel", "type": "slack"}], "dd-service": "my-service", "description": "My service description", "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-url": "https://my-org.opsgenie.com/service/123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": {"service-url": "https://my-org.pagerduty.com/service-directory/PMyService"}}, "langauges": ["dotnet", "go", "java", "js", "php", "python", "ruby", "c++"], "lifecycle": "sandbox", "links": [{"name": "Runbook", "provider": "Github", "type": "runbook", "url": "https://my-runbook"}], "schema-version": "v2.2", "tags": ["my:tag", "service:tag"], "team": "my-team", "tier": "High", "type": "web"}
And body with value {"application": "my-app", "contacts": [{"contact": "https://teams.microsoft.com/myteam", "name": "My team channel", "type": "slack"}], "dd-service": "my-service", "description": "My service description", "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-url": "https://my-org.opsgenie.com/service/123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": {"service-url": "https://my-org.pagerduty.com/service-directory/PMyService"}}, "languages": ["dotnet", "go", "java", "js", "php", "python", "ruby", "c++"], "lifecycle": "sandbox", "links": [{"name": "Runbook", "provider": "Github", "type": "runbook", "url": "https://my-runbook"}], "schema-version": "v2.2", "tags": ["my:tag", "service:tag"], "team": "my-team", "tier": "High", "type": "web"}
When the request is sent
Then the response status is 409 Conflict

Expand Down