diff --git a/.apigentools-info b/.apigentools-info index c9a48b44905..66db1fd5dbb 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.6.4", - "regenerated": "2022-10-07 18:45:13.140365", - "spec_repo_commit": "e5a0f5b3" + "regenerated": "2022-10-11 16:21:59.043800", + "spec_repo_commit": "c90265b2" }, "v2": { "apigentools_version": "1.6.4", - "regenerated": "2022-10-07 18:45:13.155433", - "spec_repo_commit": "e5a0f5b3" + "regenerated": "2022-10-11 16:21:59.066264", + "spec_repo_commit": "c90265b2" } } } \ No newline at end of file diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 6a804e1693f..2f96dba665f 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -310,6 +310,14 @@ components: schema: example: 00000000-0000-1234-0000-000000000000 type: string + ServiceName: + description: The name of the service. + in: path + name: service_name + required: true + schema: + example: my-service + type: string SignalID: description: The ID of the signal. in: path @@ -8371,6 +8379,468 @@ components: required: - data type: object + ServiceDefinitionData: + description: Service definition data. + properties: + attributes: + $ref: '#/components/schemas/ServiceDefinitionDataAttributes' + type: + description: Service definition type. + type: string + type: object + ServiceDefinitionDataAttributes: + description: Service definition attributes. + properties: + meta: + $ref: '#/components/schemas/ServiceDefinitionMeta' + schema: + $ref: '#/components/schemas/ServiceDefinitionSchema' + type: object + ServiceDefinitionGetResponse: + description: Get service definition response. + properties: + data: + $ref: '#/components/schemas/ServiceDefinitionData' + type: object + ServiceDefinitionListResponse: + description: Get service definitions response. + properties: + data: + description: Get service definitions response payload. + items: + $ref: '#/components/schemas/ServiceDefinitionData' + type: array + type: object + ServiceDefinitionMeta: + description: Metadata about a service definition. + properties: + github-html-url: + description: GitHub HTML URL. + type: string + ingested-schema-version: + description: Ingestion schema version. + type: string + ingestion-source: + description: Ingestion source of the service definition. + type: string + last-modified-time: + description: Last modified time of the service definition. + type: string + type: object + ServiceDefinitionRaw: + description: Service Definition in raw JSON/YAML representation. + example: '--- + + schema-version: v2 + + dd-service: my-service + + ' + type: string + ServiceDefinitionSchema: + description: Service definition schema. + oneOf: + - $ref: '#/components/schemas/ServiceDefinitionV1' + - $ref: '#/components/schemas/ServiceDefinitionV2' + type: object + ServiceDefinitionV1: + deprecated: true + description: Deprecated - Service definition V1 for providing additional service + metadata and integrations. + properties: + contact: + $ref: '#/components/schemas/ServiceDefinitionV1Contact' + extensions: + additionalProperties: {} + description: Extensions to V1 schema. + example: + myorg/extension: extensionValue + type: object + external-resources: + description: A list of external links related to the services. + items: + $ref: '#/components/schemas/ServiceDefinitionV1Resource' + type: array + info: + $ref: '#/components/schemas/ServiceDefinitionV1Info' + integrations: + $ref: '#/components/schemas/ServiceDefinitionV1Integrations' + org: + $ref: '#/components/schemas/ServiceDefinitionV1Org' + schema-version: + $ref: '#/components/schemas/ServiceDefinitionV1Version' + tags: + description: A set of custom tags. + example: + - my:tag + - service:tag + items: + type: string + type: array + required: + - schema-version + - info + type: object + ServiceDefinitionV1Contact: + description: Contact information about the service. + properties: + email: + description: "Service owner\u2019s email." + example: contact@datadoghq.com + format: email + type: string + slack: + description: "Service owner\u2019s slack channel." + example: https://yourcompany.slack.com/archives/channel123 + type: string + ServiceDefinitionV1Info: + description: Basic information about a service. + properties: + dd-service: + description: Unique identifier of the service. Must be unique across all + services and is used to match with a service in Datadog. + example: myservice + type: string + description: + description: A short description of the service. + example: A shopping cart service + type: string + display-name: + description: A friendly name of the service. + example: My Service + type: string + service-tier: + description: Service tier. + example: Tier 1 + type: string + required: + - dd-service + type: object + ServiceDefinitionV1Integrations: + description: Third party integrations that Datadog supports. + properties: + pagerduty: + $ref: '#/components/schemas/ServiceDefinitionV1Pagerduty' + type: object + ServiceDefinitionV1Org: + description: Org related information about the service. + properties: + application: + description: App feature for which this service supports. + example: E-Commerce + type: string + team: + description: Team that owns the service. + example: my-team + type: string + type: object + ServiceDefinitionV1Pagerduty: + description: PagerDuty service url for the service. + example: https://my-org.pagerduty.com/service-directory/PMyService + type: string + ServiceDefinitionV1Resource: + description: Service's external links. + properties: + name: + description: Link name. + example: Runbook + type: string + type: + $ref: '#/components/schemas/ServiceDefinitionV1ResourceType' + url: + description: Link URL. + example: https://my-runbook + type: string + required: + - name + - type + - url + type: object + ServiceDefinitionV1ResourceType: + description: Link type. + enum: + - doc + - wiki + - runbook + - url + - repo + - dashboard + - oncall + - code + - link + example: runbook + type: string + x-enum-varnames: + - DOC + - WIKI + - RUNBOOK + - URL + - REPO + - DASHBOARD + - ONCALL + - CODE + - LINK + ServiceDefinitionV1Version: + default: v1 + description: Schema version being used. + enum: + - v1 + example: v1 + type: string + x-enum-varnames: + - v1 + ServiceDefinitionV2: + description: Service definition V2 for providing service metadata and integrations. + properties: + contacts: + description: A list of contacts related to the services. + items: + $ref: '#/components/schemas/ServiceDefinitionV2Contact' + type: array + dd-service: + description: Unique identifier of the service. Must be unique across all + services and is used to match with a service in Datadog. + example: my-service + type: string + dd-team: + description: Experimental feature. A Team handle that matches a Team in + the Datadog Teams product. + example: my-team + type: string + docs: + description: A list of documentation related to the services. + items: + $ref: '#/components/schemas/ServiceDefinitionV2Doc' + type: array + extensions: + additionalProperties: {} + description: Extensions to V2 schema. + example: + myorg/extension: extensionValue + type: object + integrations: + $ref: '#/components/schemas/ServiceDefinitionV2Integrations' + links: + description: A list of links related to the services. + items: + $ref: '#/components/schemas/ServiceDefinitionV2Link' + type: array + repos: + description: A list of code repositories related to the services. + items: + $ref: '#/components/schemas/ServiceDefinitionV2Repo' + type: array + schema-version: + $ref: '#/components/schemas/ServiceDefinitionV2Version' + tags: + description: A set of custom tags. + example: + - my:tag + - service:tag + items: + type: string + type: array + team: + description: Team that owns the service. + example: my-team + type: string + required: + - schema-version + - dd-service + type: object + ServiceDefinitionV2Contact: + description: Service owner's contacts information. + oneOf: + - $ref: '#/components/schemas/ServiceDefinitionV2Email' + - $ref: '#/components/schemas/ServiceDefinitionV2Slack' + ServiceDefinitionV2Doc: + description: Service documents. + properties: + name: + description: Document name. + example: Architecture + type: string + provider: + description: Document provider. + example: google drive + type: string + url: + description: Document URL. + example: https://gdrive/mydoc + type: string + required: + - name + - url + type: object + ServiceDefinitionV2Email: + description: Service owner's email. + properties: + contact: + description: Contact value. + example: contact@datadoghq.com + format: email + type: string + name: + description: Contact email. + example: Team Email + type: string + type: + $ref: '#/components/schemas/ServiceDefinitionV2EmailType' + required: + - type + - contact + type: object + ServiceDefinitionV2EmailType: + description: Contact type. + enum: + - email + example: email + type: string + x-enum-varnames: + - EMAIL + ServiceDefinitionV2Integrations: + description: Third party integrations that Datadog supports. + properties: + opsgenie: + $ref: '#/components/schemas/ServiceDefinitionV2Opsgenie' + pagerduty: + $ref: '#/components/schemas/ServiceDefinitionV2Pagerduty' + type: object + ServiceDefinitionV2Link: + description: Service's external links. + properties: + name: + description: Link name. + example: Runbook + type: string + type: + $ref: '#/components/schemas/ServiceDefinitionV2LinkType' + url: + description: Link URL. + example: https://my-runbook + type: string + required: + - name + - type + - url + type: object + ServiceDefinitionV2LinkType: + description: Link type. + enum: + - doc + - wiki + - runbook + - url + - repo + - dashboard + - oncall + - code + - link + example: runbook + type: string + x-enum-varnames: + - DOC + - WIKI + - RUNBOOK + - URL + - REPO + - DASHBOARD + - ONCALL + - CODE + - LINK + ServiceDefinitionV2Opsgenie: + description: Opsgenie integration for the service. + properties: + region: + $ref: '#/components/schemas/ServiceDefinitionV2OpsgenieRegion' + service-id: + description: Opsgenie service id. + example: 123e4567-e89b-12d3-a456-426614174000 + type: string + required: + - service-id + type: object + ServiceDefinitionV2OpsgenieRegion: + description: Opsgenie instance region. + enum: + - US + - EU + example: US + type: string + x-enum-varnames: + - US + - EU + ServiceDefinitionV2Pagerduty: + description: PagerDuty service URL for the service. + example: https://my-org.pagerduty.com/service-directory/PMyService + type: string + ServiceDefinitionV2Repo: + description: Service code repositories. + properties: + name: + description: Repository name. + example: Source Code + type: string + provider: + description: Repository provider. + example: GitHub + type: string + url: + description: Repository URL. + example: https://github.com/DataDog/schema + type: string + required: + - name + - url + type: object + ServiceDefinitionV2Slack: + description: Service owner's slack channel. + properties: + contact: + description: Slack Channel. + example: https://yourcompany.slack.com/archives/channel123 + type: string + name: + description: Contact Slack. + example: Team Slack + type: string + type: + $ref: '#/components/schemas/ServiceDefinitionV2SlackType' + required: + - type + - contact + type: object + ServiceDefinitionV2SlackType: + description: Contact type. + enum: + - slack + example: slack + type: string + x-enum-varnames: + - SLACK + ServiceDefinitionV2Version: + default: v2 + description: Schema version being used. + enum: + - v2 + example: v2 + type: string + x-enum-varnames: + - V2 + ServiceDefinitionsCreateRequest: + description: Create service definitions request. + oneOf: + - $ref: '#/components/schemas/ServiceDefinitionV2' + - $ref: '#/components/schemas/ServiceDefinitionRaw' + ServiceDefinitionsCreateResponse: + description: Create service definitions response. + properties: + data: + description: Data representing service definitions. + items: + $ref: '#/components/schemas/ServiceDefinitionData' + type: array + type: object UsageApplicationSecurityMonitoringResponse: description: Application Security Monitoring usage response. properties: @@ -13920,6 +14390,99 @@ paths: x-unstable: '**Note**: This endpoint is in public beta. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).' + /api/v2/services/definitions: + get: + description: Get a list of all service definitions from the Datadog Service + Catalog. + operationId: ListServiceDefinitions + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ServiceDefinitionsCreateResponse' + description: OK + '403': + $ref: '#/components/responses/ForbiddenResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + summary: Get all service definitions + tags: + - Service Definition + post: + description: Create or update service definition in the Datadog Service Catalog. + operationId: CreateOrUpdateServiceDefinitions + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ServiceDefinitionsCreateRequest' + description: Service Definition YAML/JSON. + required: true + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ServiceDefinitionListResponse' + description: CREATED + '400': + $ref: '#/components/responses/BadRequestResponse' + '403': + $ref: '#/components/responses/ForbiddenResponse' + '409': + $ref: '#/components/responses/ConflictResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + summary: Create or update service definition + tags: + - Service Definition + x-codegen-request-body-name: body + /api/v2/services/definitions/{service_name}: + delete: + description: Delete a single service definition in the Datadog Service Catalog. + operationId: DeleteServiceDefinition + parameters: + - $ref: '#/components/parameters/ServiceName' + responses: + '204': + description: OK + '400': + $ref: '#/components/responses/BadRequestResponse' + '403': + $ref: '#/components/responses/ForbiddenResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + summary: Delete a single service definition + tags: + - Service Definition + get: + description: Get a single service definition from the Datadog Service Catalog. + operationId: GetServiceDefinition + parameters: + - $ref: '#/components/parameters/ServiceName' + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ServiceDefinitionGetResponse' + description: OK + '400': + $ref: '#/components/responses/BadRequestResponse' + '403': + $ref: '#/components/responses/ForbiddenResponse' + '404': + $ref: '#/components/responses/NotFoundResponse' + '409': + $ref: '#/components/responses/ConflictResponse' + '429': + $ref: '#/components/responses/TooManyRequestsResponse' + summary: Get a single service definition + tags: + - Service Definition /api/v2/services/{service_id}: delete: description: Deletes an existing incident service. @@ -15258,6 +15821,10 @@ tags: name: Security Monitoring - description: Create, edit, and disable service accounts. name: Service Accounts +- description: API to create, update, retrieve and delete service definitions. + externalDocs: + url: https://docs.datadoghq.com/tracing/service_catalog/ + name: Service Definition - description: 'The usage metering API allows you to get hourly, daily, and monthly usage across multiple facets of Datadog. diff --git a/cassettes/v2/Service-Definition_2211895093/Create-or-update-service-definition-returns-CREATED-response_4118101501/frozen.json b/cassettes/v2/Service-Definition_2211895093/Create-or-update-service-definition-returns-CREATED-response_4118101501/frozen.json new file mode 100644 index 00000000000..f7b8511b7d7 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Create-or-update-service-definition-returns-CREATED-response_4118101501/frozen.json @@ -0,0 +1 @@ +"2022-10-11T16:11:15.904Z" diff --git a/cassettes/v2/Service-Definition_2211895093/Create-or-update-service-definition-returns-CREATED-response_4118101501/recording.har b/cassettes/v2/Service-Definition_2211895093/Create-or-update-service-definition-returns-CREATED-response_4118101501/recording.har new file mode 100644 index 00000000000..961ac123263 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Create-or-update-service-definition-returns-CREATED-response_4118101501/recording.har @@ -0,0 +1,110 @@ +{ + "log": { + "_recordingName": "Service Definition/Create or update service definition returns \"CREATED\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "2eab0410570d0cc16e146291eec63e54", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 749, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 585, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"contacts\":[{\"contact\":\"contact@datadoghq.com\",\"name\":\"Team Email\",\"type\":\"email\"}],\"dd-service\":\"service-Test-Create_or_update_service_definition_returns_CREATED_response-1665504675\",\"dd-team\":\"my-team\",\"docs\":[{\"name\":\"Architecture\",\"provider\":\"google drive\",\"url\":\"https://gdrive/mydoc\"}],\"extensions\":{\"myorgextension\":\"extensionvalue\"},\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"links\":[{\"name\":\"Runbook\",\"type\":\"runbook\",\"url\":\"https://my-runbook\"}],\"repos\":[{\"name\":\"Source Code\",\"provider\":\"GitHub\",\"url\":\"https://github.com/DataDog/schema\"}],\"schema-version\":\"v2\",\"tags\":[\"my:tag\",\"service:tag\"],\"team\":\"my-team\"}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions" + }, + "response": { + "bodySize": 936, + "content": { + "mimeType": "application/json", + "size": 936, + "text": "{\"data\":[{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-11T16:11:16.302119241Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[{\"contact\":\"contact@datadoghq.com\",\"type\":\"email\",\"name\":\"Team Email\"}],\"docs\":[{\"url\":\"https://gdrive/mydoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/schema\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"my:tag\",\"service:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"my-team\",\"extensions\":{},\"dd-service\":\"service-test-create_or_update_service_definition_returns_created_response-1665504675\"}},\"type\":\"service-definition\"}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 628, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2022-10-11T16:11:15.914Z", + "time": 453 + }, + { + "_id": "023b1b51b1876a2649f7bf02f35c06b3", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + } + ], + "headersSize": 597, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/service-test-create_or_update_service_definition_returns_created_response-1665504675" + }, + "response": { + "bodySize": 46, + "content": { + "mimeType": "application/json", + "size": 46, + "text": "{\"errors\":[\"Not Found\"],\"error_details\":[{}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 670, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2022-10-11T16:11:16.374Z", + "time": 785 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-Not-Found-response_3594494704/frozen.json b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-Not-Found-response_3594494704/frozen.json new file mode 100644 index 00000000000..5b64eee3e12 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-Not-Found-response_3594494704/frozen.json @@ -0,0 +1 @@ +"2022-10-10T10:17:50.609Z" diff --git a/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-Not-Found-response_3594494704/recording.har b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-Not-Found-response_3594494704/recording.har new file mode 100644 index 00000000000..cd279843909 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-Not-Found-response_3594494704/recording.har @@ -0,0 +1,57 @@ +{ + "log": { + "_recordingName": "Service Definition/Delete a single service definition returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "1fd08f74275af50b74e2ac875a785d04", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + } + ], + "headersSize": 528, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/not-a-service" + }, + "response": { + "bodySize": 46, + "content": { + "mimeType": "application/json", + "size": 46, + "text": "{\"errors\":[\"Not Found\"],\"error_details\":[{}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 669, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2022-10-10T10:17:50.619Z", + "time": 817 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-OK-response_484092435/frozen.json b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-OK-response_484092435/frozen.json new file mode 100644 index 00000000000..0fd08b091bd --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-OK-response_484092435/frozen.json @@ -0,0 +1 @@ +"2022-10-10T12:48:37.381Z" diff --git a/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-OK-response_484092435/recording.har b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-OK-response_484092435/recording.har new file mode 100644 index 00000000000..bf595598d88 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Delete-a-single-service-definition-returns-OK-response_484092435/recording.har @@ -0,0 +1,147 @@ +{ + "log": { + "_recordingName": "Service Definition/Delete a single service definition returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "d68d4a1c9ec2a0b3f8b5a3f29bc801e0", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 671, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 587, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"dd-service\":\"service-Test-Delete_a_single_service_definition_returns_OK_response-1665406117\",\"dd-team\":\"my-team\",\"docs\":[{\"name\":\"Architecture\",\"provider\":\"google drive\",\"url\":\"https://gdrive/mygivedoc\"}],\"extensions\":{\"frogextension\":\"extensionfrogvalue\"},\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"links\":[{\"name\":\"Runbook\",\"type\":\"runbook\",\"url\":\"https://my-runbook\"}],\"repos\":[{\"name\":\"Source Code\",\"provider\":\"GitHub\",\"url\":\"https://github.com/DataDog/given\"}],\"schema-version\":\"v2\",\"tags\":[\"this:tag\",\"service:tag\"],\"team\":\"super-team\"}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions" + }, + "response": { + "bodySize": 868, + "content": { + "mimeType": "application/json", + "size": 868, + "text": "{\"data\":[{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:48:37.797458518Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"service:tag\",\"this:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-delete_a_single_service_definition_returns_ok_response-1665406117\"}},\"type\":\"service-definition\"}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 628, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2022-10-10T12:48:37.393Z", + "time": 469 + }, + { + "_id": "acb004fa754eaa7ae7fac60d61b3c321", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + } + ], + "headersSize": 593, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/service-Test-Delete_a_single_service_definition_returns_OK_response-1665406117" + }, + "response": { + "bodySize": 0, + "content": { + "mimeType": "text/plain", + "size": 0 + }, + "cookies": [], + "headers": [], + "headersSize": 624, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 204, + "statusText": "No Content" + }, + "startedDateTime": "2022-10-10T12:48:51.870Z", + "time": 704 + }, + { + "_id": "3ba19283a0d8e37d4fee07800746d58f", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + } + ], + "headersSize": 593, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/service-test-delete_a_single_service_definition_returns_ok_response-1665406117" + }, + "response": { + "bodySize": 46, + "content": { + "mimeType": "application/json", + "size": 46, + "text": "{\"errors\":[\"Not Found\"],\"error_details\":[{}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 669, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2022-10-10T12:48:52.582Z", + "time": 639 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-Not-Found-response_460802243/frozen.json b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-Not-Found-response_460802243/frozen.json new file mode 100644 index 00000000000..06f023f5039 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-Not-Found-response_460802243/frozen.json @@ -0,0 +1 @@ +"2022-10-10T10:18:53.337Z" diff --git a/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-Not-Found-response_460802243/recording.har b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-Not-Found-response_460802243/recording.har new file mode 100644 index 00000000000..766ef6ae4d5 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-Not-Found-response_460802243/recording.har @@ -0,0 +1,57 @@ +{ + "log": { + "_recordingName": "Service Definition/Get a single service definition returns \"Not Found\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "6871a664ce7c1a2e26ac5d32da04bee4", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + } + ], + "headersSize": 535, + "httpVersion": "HTTP/1.1", + "method": "GET", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/not-a-service" + }, + "response": { + "bodySize": 46, + "content": { + "mimeType": "application/json", + "size": 46, + "text": "{\"errors\":[\"Not Found\"],\"error_details\":[{}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 669, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2022-10-10T10:18:53.346Z", + "time": 678 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-OK-response_1436718714/frozen.json b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-OK-response_1436718714/frozen.json new file mode 100644 index 00000000000..2d4e13aa2ff --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-OK-response_1436718714/frozen.json @@ -0,0 +1 @@ +"2022-10-10T12:33:59.012Z" diff --git a/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-OK-response_1436718714/recording.har b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-OK-response_1436718714/recording.har new file mode 100644 index 00000000000..4ad2eb129ca --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Get-a-single-service-definition-returns-OK-response_1436718714/recording.har @@ -0,0 +1,153 @@ +{ + "log": { + "_recordingName": "Service Definition/Get a single service definition returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "9cb52e5b6f30175549268772ff38412d", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 668, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + }, + { + "_fromType": "array", + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 587, + "httpVersion": "HTTP/1.1", + "method": "POST", + "postData": { + "mimeType": "application/json", + "params": [], + "text": "{\"dd-service\":\"service-Test-Get_a_single_service_definition_returns_OK_response-1665405239\",\"dd-team\":\"my-team\",\"docs\":[{\"name\":\"Architecture\",\"provider\":\"google drive\",\"url\":\"https://gdrive/mygivedoc\"}],\"extensions\":{\"frogextension\":\"extensionfrogvalue\"},\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"links\":[{\"name\":\"Runbook\",\"type\":\"runbook\",\"url\":\"https://my-runbook\"}],\"repos\":[{\"name\":\"Source Code\",\"provider\":\"GitHub\",\"url\":\"https://github.com/DataDog/given\"}],\"schema-version\":\"v2\",\"tags\":[\"this:tag\",\"service:tag\"],\"team\":\"super-team\"}" + }, + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions" + }, + "response": { + "bodySize": 865, + "content": { + "mimeType": "application/json", + "size": 865, + "text": "{\"data\":[{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:33:59.412229035Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"service:tag\",\"this:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-get_a_single_service_definition_returns_ok_response-1665405239\"}},\"type\":\"service-definition\"}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 627, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2022-10-10T12:33:59.023Z", + "time": 454 + }, + { + "_id": "dd0037a549a5f7e0fba31bcc22f61d64", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + } + ], + "headersSize": 597, + "httpVersion": "HTTP/1.1", + "method": "GET", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/service-Test-Get_a_single_service_definition_returns_OK_response-1665405239" + }, + "response": { + "bodySize": 46, + "content": { + "mimeType": "application/json", + "size": 892, + "text": "{\"data\":{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:24:16Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"service:tag\",\"this:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-get_a_single_service_definition_returns_ok_response-1665405239\"}},\"type\":\"service-definition\",\"id\":\"d6822c235d26b96b47ded1a3eecba6c1\"}}" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 670, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "Not Found" + }, + "startedDateTime": "2022-10-10T12:34:09.491Z", + "time": 627 + }, + { + "_id": "1705ab2ee3a71915944d55521a0976f4", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "*/*" + } + ], + "headersSize": 590, + "httpVersion": "HTTP/1.1", + "method": "DELETE", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions/service-test-get_a_single_service_definition_returns_ok_response-1665405239" + }, + "response": { + "bodySize": 46, + "content": { + "mimeType": "application/json", + "size": 46, + "text": "{\"errors\":[\"Not Found\"],\"error_details\":[{}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 670, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 404, + "statusText": "Not Found" + }, + "startedDateTime": "2022-10-10T12:34:14.128Z", + "time": 425 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/cassettes/v2/Service-Definition_2211895093/Get-all-service-definitions-returns-OK-response_3667194207/frozen.json b/cassettes/v2/Service-Definition_2211895093/Get-all-service-definitions-returns-OK-response_3667194207/frozen.json new file mode 100644 index 00000000000..38f53169037 --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Get-all-service-definitions-returns-OK-response_3667194207/frozen.json @@ -0,0 +1 @@ +"2022-10-10T12:54:43.916Z" diff --git a/cassettes/v2/Service-Definition_2211895093/Get-all-service-definitions-returns-OK-response_3667194207/recording.har b/cassettes/v2/Service-Definition_2211895093/Get-all-service-definitions-returns-OK-response_3667194207/recording.har new file mode 100644 index 00000000000..62197b97c7d --- /dev/null +++ b/cassettes/v2/Service-Definition_2211895093/Get-all-service-definitions-returns-OK-response_3667194207/recording.har @@ -0,0 +1,57 @@ +{ + "log": { + "_recordingName": "Service Definition/Get all service definitions returns \"OK\" response", + "creator": { + "comment": "persister:fs", + "name": "Polly.JS", + "version": "6.0.5" + }, + "entries": [ + { + "_id": "3fa62fb73225e49826d216957aa4d1f3", + "_order": 0, + "cache": {}, + "request": { + "bodySize": 0, + "cookies": [], + "headers": [ + { + "_fromType": "array", + "name": "accept", + "value": "application/json" + } + ], + "headersSize": 523, + "httpVersion": "HTTP/1.1", + "method": "GET", + "queryString": [], + "url": "https://api.datadoghq.com/api/v2/services/definitions" + }, + "response": { + "bodySize": 73829, + "content": { + "mimeType": "application/json", + "size": 73829, + "text": "{\"data\":[{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-13T15:05:42Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"test-service\"}},\"type\":\"service-definition\",\"id\":\"00c8f48f9bd65a7326d109c110903a48\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-24T12:26:31Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664022388\"}},\"type\":\"service-definition\",\"id\":\"0b92287408533dc9010ece79b9b7f5da\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-23T12:27:52Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663936069\"}},\"type\":\"service-definition\",\"id\":\"1121978c2d509695d6b308699ad4ff3c\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-08T00:35:29Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665189327\"}},\"type\":\"service-definition\",\"id\":\"11c76361fe9a02282257f8281c3a7e84\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:48:37Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"this:tag\",\"service:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-delete_a_single_service_definition_returns_ok_response-1665406117\"}},\"type\":\"service-definition\",\"id\":\"142c3ef445627d2db24dc2efe071feaf\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-17T00:37:54Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663375071\"}},\"type\":\"service-definition\",\"id\":\"15dac466909d300907b2cb5c23d43034\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-19T20:35:44Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663619739-updated\"}},\"type\":\"service-definition\",\"id\":\"193e0a13e3f5e898ce9a83bd06b390a5\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T00:34:27Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665362065\"}},\"type\":\"service-definition\",\"id\":\"1eb456f17841bcead8624eb76c3dce31\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-26T00:35:13Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664152511\"}},\"type\":\"service-definition\",\"id\":\"2cc3a1ebf7c90790ae7f58d4fe90152f\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-28T16:03:10Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664380988\"}},\"type\":\"service-definition\",\"id\":\"2dc81e8abea92a4cd9a604ece099a953\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:14:45Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665404081\"}},\"type\":\"service-definition\",\"id\":\"31f1337cc68728878aab22845fbc9e8b\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-20T12:19:04Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663676342\"}},\"type\":\"service-definition\",\"id\":\"3227cd18de3a45aa88f01143cc20d58e\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-08-04T20:17:04Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[],\"contacts\":[],\"docs\":[],\"repos\":[],\"tags\":[\"host:isolated-diego-cell-0-270372e1-a8ae-4d3c-9678-41a072dd365c\"],\"dd-team\":\"intg-tools-libs\",\"integrations\":{},\"schema-version\":\"v2\",\"team\":\"intg-tools-libs\",\"extensions\":{},\"dd-service\":\"python-sample-app-unbleachedsilk\"}},\"type\":\"service-definition\",\"id\":\"3452c51e0db6322b8cd3290d06540978\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-18T12:17:13Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663503431\"}},\"type\":\"service-definition\",\"id\":\"37636efa41bc8106beb35ccb2048e67d\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:33:59Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"service:tag\",\"this:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-get_a_single_service_definition_returns_ok_response-1665405239\"}},\"type\":\"service-definition\",\"id\":\"3f712fd0846e734cf273d8bf10aba358\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-04T12:23:57Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664886235\"}},\"type\":\"service-definition\",\"id\":\"44b348df99fb628eba7da07aa9c1f08a\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-15T00:32:57Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663201975\"}},\"type\":\"service-definition\",\"id\":\"47c27bd6f1fc510941849e27cc87a50a\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-17T12:37:04Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663418218-updated\"}},\"type\":\"service-definition\",\"id\":\"49485bc9760c67bd934a76b3769c6bf3\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-28T15:14:44Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664378080-updated\"}},\"type\":\"service-definition\",\"id\":\"4983a2094fbed9a7426fa952b238e56a\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T00:24:50Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665361489\"}},\"type\":\"service-definition\",\"id\":\"4c895f6110be70e6957f12e3f8e5a62d\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-17T00:29:11Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663374546-updated\"}},\"type\":\"service-definition\",\"id\":\"4dc2beec923d8095338f6534979d652d\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-23T12:27:04Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663936022\"}},\"type\":\"service-definition\",\"id\":\"5a1ce48c269f2c227f48ec0a5eeffae2\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-24T00:39:13Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663979951\"}},\"type\":\"service-definition\",\"id\":\"5ddd66188cbbd5f857a86e3cd3c567d7\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-08T00:35:01Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665189299\"}},\"type\":\"service-definition\",\"id\":\"5e90ebc923829a1f089305fa612dc842\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-29T00:31:52Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664411510\"}},\"type\":\"service-definition\",\"id\":\"5e981473bd66799cdbfdab5667699d21\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-24T00:39:55Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663979992\"}},\"type\":\"service-definition\",\"id\":\"6191014cb0d8f2a8a72a2f0acca8c35f\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-28T14:31:34Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664375492\"}},\"type\":\"service-definition\",\"id\":\"654f80015adf24d97e59ffcb2a46e678\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-23T12:23:23Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663935801\"}},\"type\":\"service-definition\",\"id\":\"690d77bf33bb43c1b40157eb1455fe97\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-15T00:32:32Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663201951\"}},\"type\":\"service-definition\",\"id\":\"6a7a9a2a95b392e21466173f83868da1\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-17T12:36:53Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663418211\"}},\"type\":\"service-definition\",\"id\":\"6ae98d51f75fab86e96d6cc9efd02123\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-09T12:13:57Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665317635\"}},\"type\":\"service-definition\",\"id\":\"78031c2a631318e7f2cb7bfbf68a18be\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-25T00:36:39Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664066196\"}},\"type\":\"service-definition\",\"id\":\"82da2d6ea18971b06c81c55b36edd03d\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-16T00:34:30Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663288468\"}},\"type\":\"service-definition\",\"id\":\"85b18f281ff2c3d794195d4e5e3703de\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-17T12:21:03Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663417258\"}},\"type\":\"service-definition\",\"id\":\"866a88946ed335a8f3de72a9617fa39d\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T10:29:06Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"this:tag\",\"service:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-get_a_single_service_definition_returns_ok_response-1665397746\"}},\"type\":\"service-definition\",\"id\":\"8b2110b5ac6ad3b8ced03af62700f96a\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-20T12:31:41Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663677098\"}},\"type\":\"service-definition\",\"id\":\"8ba17884f966f9cc42355051bc45fe15\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-18T00:36:38Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663461397\"}},\"type\":\"service-definition\",\"id\":\"96399afc130bc415a0f555d5a81c7591\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-22T12:27:47Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663849665\"}},\"type\":\"service-definition\",\"id\":\"9b02212ffcf45156efa8254441343b65\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-08T00:25:24Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665188722\"}},\"type\":\"service-definition\",\"id\":\"9cd2939b2ccad303a5faf906329bdddd\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-24T12:26:46Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664022404\"}},\"type\":\"service-definition\",\"id\":\"a2af7651d982e91ab5305665b967e7ff\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-05T12:15:01Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664972099\"}},\"type\":\"service-definition\",\"id\":\"a91a2011287371e9bc78e8440dfd6d30\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-24T00:40:33Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663980031\"}},\"type\":\"service-definition\",\"id\":\"b283555a3adcbc6e7ee662fca6c9c815\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-18T00:25:46Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663460745\"}},\"type\":\"service-definition\",\"id\":\"b7c93e14a001dec8f48c54ac46ee52ff\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-19T12:18:01Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663589879\"}},\"type\":\"service-definition\",\"id\":\"bb70888ec662b81ec18623b586b34c72\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-24T12:23:19Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664022198\"}},\"type\":\"service-definition\",\"id\":\"bea5986b81a67b3a06f74db75753cbf6\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-20T12:31:30Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663677087\"}},\"type\":\"service-definition\",\"id\":\"c5187921f635b5679171150e3c497518\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-22T12:27:21Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663849639\"}},\"type\":\"service-definition\",\"id\":\"c5a73fff1eeb3082dedf1015bf5eb8c7\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-01T12:15:40Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664626538\"}},\"type\":\"service-definition\",\"id\":\"c887ca10d1ffc5d9a939c68f38d84e25\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-07T12:15:14Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665144911\"}},\"type\":\"service-definition\",\"id\":\"cc016d2b21fad7b7af073a6fcf8f70b6\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-15T00:33:02Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663201980\"}},\"type\":\"service-definition\",\"id\":\"cc2af89492dc572929a72b2705142aa2\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-09T12:24:43Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665318281\"}},\"type\":\"service-definition\",\"id\":\"d4d04320f1daf9db2e3ff75de377edaa\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T12:24:16Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://my-runbook\",\"type\":\"runbook\",\"name\":\"Runbook\"}],\"contacts\":[],\"docs\":[{\"url\":\"https://gdrive/mygivedoc\",\"name\":\"Architecture\",\"provider\":\"google drive\"}],\"repos\":[{\"url\":\"https://github.com/DataDog/given\",\"name\":\"Source Code\",\"provider\":\"GitHub\"}],\"tags\":[\"this:tag\",\"service:tag\"],\"dd-team\":\"my-team\",\"integrations\":{\"opsgenie\":{\"region\":\"US\",\"service-id\":\"123e4567-e89b-12d3-a456-426614174000\"},\"pagerduty\":\"https://my-org.pagerduty.com/service-directory/PMyService\"},\"schema-version\":\"v2\",\"team\":\"super-team\",\"extensions\":{},\"dd-service\":\"service-test-get_a_single_service_definition_returns_ok_response-1665404656\"}},\"type\":\"service-definition\",\"id\":\"d6822c235d26b96b47ded1a3eecba6c1\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-06T12:23:44Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665059022\"}},\"type\":\"service-definition\",\"id\":\"dbe6ec9de10888c6d333539aecdf962a\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-08T12:15:17Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665231315\"}},\"type\":\"service-definition\",\"id\":\"e148aa733e21ac31994b1e26a789c418\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-25T00:41:11Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664066464-updated\"}},\"type\":\"service-definition\",\"id\":\"e20df46b4b1b3c34eee0db47f7cdaa1f\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-09T12:25:03Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665318301\"}},\"type\":\"service-definition\",\"id\":\"e49200dcf5868c0e0f06249986f37446\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-18T00:36:33Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663461391\"}},\"type\":\"service-definition\",\"id\":\"e5745cc928c0887bdb6b63d9649636c9\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-26T00:38:33Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664152711\"}},\"type\":\"service-definition\",\"id\":\"ea7e4590c85ff751a03d3e957396c3ba\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-08-04T20:37:09Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[],\"contacts\":[{\"contact\":\"noueman.khalikine@datadoghq.com\",\"type\":\"email\"}],\"docs\":[],\"repos\":[],\"tags\":[],\"dd-team\":\"intg-tools-libs\",\"integrations\":{},\"schema-version\":\"v2\",\"team\":\"intg-tools-libs\",\"extensions\":{},\"dd-service\":\"python-app-checks-enabled\"}},\"type\":\"service-definition\",\"id\":\"edbfdd906e141e7512918fa561c7e90d\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-05T12:25:35Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664972730-updated\"}},\"type\":\"service-definition\",\"id\":\"f031b34f679003f9eaff0cd02324a42e\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-28T16:02:54Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664380972\"}},\"type\":\"service-definition\",\"id\":\"f4a723cbeccb6827f12849a358fbfc3a\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-22T12:23:52Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1663849431\"}},\"type\":\"service-definition\",\"id\":\"f5d046880a32d46aa4f0a05e8a6dd5f8\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-09-26T00:38:27Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"business-unit:retail\",\"cost-center:engineering\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1664152705\"}},\"type\":\"service-definition\",\"id\":\"fa1f962ad5fbc7655d080ac2a7010065\"},{\"attributes\":{\"meta\":{\"ingested-schema-version\":\"v2\",\"ingestion-source\":\"api\",\"last-modified-time\":\"2022-10-10T00:34:05Z\",\"github-html-url\":\"\",\"warnings\":[]},\"schema\":{\"links\":[{\"url\":\"https://runbook/shopping-cart\",\"type\":\"runbook\",\"name\":\"shopping-cart runbook\"}],\"contacts\":[{\"contact\":\"https://www.slack.com/archives/shopping-cart\",\"type\":\"slack\",\"name\":\"Support Slack\"},{\"contact\":\"team@shopping.com\",\"type\":\"email\",\"name\":\"Support Email\"}],\"docs\":[{\"url\":\"https://google.drive/shopping-cart-architecture\",\"name\":\"shopping-cart architecture\",\"provider\":\"gdoc\"},{\"url\":\"https://wiki/shopping-cart\",\"name\":\"shopping-cart service Wiki\",\"provider\":\"wiki\"}],\"repos\":[{\"url\":\"http://github/shopping-cart\",\"name\":\"shopping-cart source code\",\"provider\":\"github\"}],\"tags\":[\"cost-center:engineering\",\"business-unit:retail\"],\"dd-team\":\"e-commerce\",\"integrations\":{\"pagerduty\":\"https://www.pagerduty.com/service-directory/Pshopping-cart\"},\"schema-version\":\"v2\",\"team\":\"E Commerce\",\"extensions\":{\"datadoghq.com/shopping-cart\":{\"customField\":\"customValue\"}},\"dd-service\":\"tf-testaccdatadogservicedefinition_basic-local-1665362043\"}},\"type\":\"service-definition\",\"id\":\"fd7673ad83bc150e2d690fc8c9196f41\"}]}\n" + }, + "cookies": [], + "headers": [ + { + "name": "content-type", + "value": "application/json" + } + ], + "headersSize": 630, + "httpVersion": "HTTP/1.1", + "redirectURL": "", + "status": 200, + "statusText": "OK" + }, + "startedDateTime": "2022-10-10T12:54:43.925Z", + "time": 933 + } + ], + "pages": [], + "version": "1.2" + } +} diff --git a/examples/v2/service-definition/CreateOrUpdateServiceDefinitions.ts b/examples/v2/service-definition/CreateOrUpdateServiceDefinitions.ts new file mode 100644 index 00000000000..882780270d7 --- /dev/null +++ b/examples/v2/service-definition/CreateOrUpdateServiceDefinitions.ts @@ -0,0 +1,64 @@ +/** + * Create or update service definition returns "CREATED" response + */ + +import { client, v2 } from "@datadog/datadog-api-client"; + +const configuration = client.createConfiguration(); +const apiInstance = new v2.ServiceDefinitionApi(configuration); + +const params: v2.ServiceDefinitionApiCreateOrUpdateServiceDefinitionsRequest = { + body: { + contacts: [ + { + contact: "contact@datadoghq.com", + name: "Team Email", + type: "email", + }, + ], + ddService: + "service-Example-Create_or_update_service_definition_returns_CREATED_response", + ddTeam: "my-team", + docs: [ + { + name: "Architecture", + provider: "google drive", + url: "https://gdrive/mydoc", + }, + ], + extensions: {}, + integrations: { + opsgenie: { + region: "US", + serviceId: "123e4567-e89b-12d3-a456-426614174000", + }, + pagerduty: "https://my-org.pagerduty.com/service-directory/PMyService", + }, + links: [ + { + name: "Runbook", + type: "runbook", + url: "https://my-runbook", + }, + ], + repos: [ + { + name: "Source Code", + provider: "GitHub", + url: "https://github.com/DataDog/schema", + }, + ], + schemaVersion: "v2", + tags: ["my:tag", "service:tag"], + team: "my-team", + }, +}; + +apiInstance + .createOrUpdateServiceDefinitions(params) + .then((data: v2.ServiceDefinitionListResponse) => { + console.log( + "API called successfully. Returned data: " + JSON.stringify(data) + ); + }) + .catch((error: any) => console.error(error)); diff --git a/examples/v2/service-definition/DeleteServiceDefinition.ts b/examples/v2/service-definition/DeleteServiceDefinition.ts new file mode 100644 index 00000000000..58fd56e22c0 --- /dev/null +++ b/examples/v2/service-definition/DeleteServiceDefinition.ts @@ -0,0 +1,22 @@ +/** + * Delete a single service definition returns "OK" response + */ + +import { client, v2 } from "@datadog/datadog-api-client"; + +const configuration = client.createConfiguration(); +const apiInstance = new v2.ServiceDefinitionApi(configuration); + +const params: v2.ServiceDefinitionApiDeleteServiceDefinitionRequest = { + serviceName: + "service-Example-Delete_a_single_service_definition_returns_OK_response", +}; + +apiInstance + .deleteServiceDefinition(params) + .then((data: any) => { + console.log( + "API called successfully. Returned data: " + JSON.stringify(data) + ); + }) + .catch((error: any) => console.error(error)); diff --git a/examples/v2/service-definition/GetServiceDefinition.ts b/examples/v2/service-definition/GetServiceDefinition.ts new file mode 100644 index 00000000000..f1d7ad891de --- /dev/null +++ b/examples/v2/service-definition/GetServiceDefinition.ts @@ -0,0 +1,22 @@ +/** + * Get a single service definition returns "OK" response + */ + +import { client, v2 } from "@datadog/datadog-api-client"; + +const configuration = client.createConfiguration(); +const apiInstance = new v2.ServiceDefinitionApi(configuration); + +const params: v2.ServiceDefinitionApiGetServiceDefinitionRequest = { + serviceName: + "service-Example-Get_a_single_service_definition_returns_OK_response", +}; + +apiInstance + .getServiceDefinition(params) + .then((data: v2.ServiceDefinitionGetResponse) => { + console.log( + "API called successfully. Returned data: " + JSON.stringify(data) + ); + }) + .catch((error: any) => console.error(error)); diff --git a/examples/v2/service-definition/ListServiceDefinitions.ts b/examples/v2/service-definition/ListServiceDefinitions.ts new file mode 100644 index 00000000000..a14436b9e1e --- /dev/null +++ b/examples/v2/service-definition/ListServiceDefinitions.ts @@ -0,0 +1,17 @@ +/** + * Get all service definitions returns "OK" response + */ + +import { client, v2 } from "@datadog/datadog-api-client"; + +const configuration = client.createConfiguration(); +const apiInstance = new v2.ServiceDefinitionApi(configuration); + +apiInstance + .listServiceDefinitions() + .then((data: v2.ServiceDefinitionsCreateResponse) => { + console.log( + "API called successfully. Returned data: " + JSON.stringify(data) + ); + }) + .catch((error: any) => console.error(error)); diff --git a/features/v2/given.json b/features/v2/given.json index ae5daeae699..4b4f179d184 100644 --- a/features/v2/given.json +++ b/features/v2/given.json @@ -286,6 +286,18 @@ "tag": "Incident Services", "operationId": "CreateIncidentService" }, + { + "parameters": [ + { + "name": "body", + "value": "{\n \"dd-service\": \"service-{{ unique}}\",\n \"dd-team\": \"my-team\",\n \"docs\": [{\"name\": \"Architecture\",\n \"provider\": \"google drive\",\n \"url\": \"https://gdrive/mygivedoc\"}],\n \"extensions\": {\"frogextension\": \"extensionfrogvalue\"},\n \"integrations\": {\"opsgenie\": {\"region\": \"US\",\n \"service-id\": \"123e4567-e89b-12d3-a456-426614174000\"},\n \"pagerduty\": \"https://my-org.pagerduty.com/service-directory/PMyService\"},\n \"links\": [{\"name\": \"Runbook\", \"type\": \"runbook\", \"url\": \"https://my-runbook\"}],\n \"repos\": [{\"name\": \"Source Code\",\n \"provider\": \"GitHub\",\n \"url\": \"https://github.com/DataDog/given\"}],\n \"schema-version\": \"v2\",\n \"tags\": [\"this:tag\", \"service:tag\"],\n \"team\": \"super-team\"\n}" + } + ], + "step": "there is a valid \"service_definition\" in the system", + "key": "service_definition", + "tag": "Service Definition", + "operationId": "CreateOrUpdateServiceDefinitions" + }, { "parameters": [ { diff --git a/features/v2/service_definition.feature b/features/v2/service_definition.feature new file mode 100644 index 00000000000..ce38544c400 --- /dev/null +++ b/features/v2/service_definition.feature @@ -0,0 +1,91 @@ +@endpoint(service-definition) @endpoint(service-definition-v2) +Feature: Service Definition + API to create, update, retrieve and delete service definitions. + + Background: + Given a valid "apiKeyAuth" key in the system + And a valid "appKeyAuth" key in the system + And an instance of "ServiceDefinition" API + + @generated @skip @team:DataDog/apm-insights + Scenario: Create or update service definition returns "Bad Request" response + Given new "CreateOrUpdateServiceDefinitions" request + And body with value {"contacts": [{"contact": "contact@datadoghq.com", "name": "Team Email", "type": "email"}], "dd-service": "my-service", "dd-team": "my-team", "docs": [{"name": "Architecture", "provider": "google drive", "url": "https://gdrive/mydoc"}], "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-id": "123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": "https://my-org.pagerduty.com/service-directory/PMyService"}, "links": [{"name": "Runbook", "type": "runbook", "url": "https://my-runbook"}], "repos": [{"name": "Source Code", "provider": "GitHub", "url": "https://github.com/DataDog/schema"}], "schema-version": "v2", "tags": ["my:tag", "service:tag"], "team": "my-team"} + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/apm-insights + Scenario: Create or update service definition returns "CREATED" response + Given new "CreateOrUpdateServiceDefinitions" request + And body with value {"contacts": [{"contact": "contact@datadoghq.com", "name": "Team Email", "type": "email"}], "dd-service": "service-{{ unique }}", "dd-team": "my-team", "docs": [{"name": "Architecture", "provider": "google drive", "url": "https://gdrive/mydoc"}], "extensions": {"myorgextension": "extensionvalue"}, "integrations": {"opsgenie": {"region": "US", "service-id": "123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": "https://my-org.pagerduty.com/service-directory/PMyService"}, "links": [{"name": "Runbook", "type": "runbook", "url": "https://my-runbook"}], "repos": [{"name": "Source Code", "provider": "GitHub", "url": "https://github.com/DataDog/schema"}], "schema-version": "v2", "tags": ["my:tag", "service:tag"], "team": "my-team"} + When the request is sent + Then the response status is 200 CREATED + And the response "data[0].attributes.meta.ingested-schema-version" is equal to "v2" + + @generated @skip @team:DataDog/apm-insights + Scenario: Create or update service definition returns "Conflict" response + Given new "CreateOrUpdateServiceDefinitions" request + And body with value {"contacts": [{"contact": "contact@datadoghq.com", "name": "Team Email", "type": "email"}], "dd-service": "my-service", "dd-team": "my-team", "docs": [{"name": "Architecture", "provider": "google drive", "url": "https://gdrive/mydoc"}], "extensions": {"myorg/extension": "extensionValue"}, "integrations": {"opsgenie": {"region": "US", "service-id": "123e4567-e89b-12d3-a456-426614174000"}, "pagerduty": "https://my-org.pagerduty.com/service-directory/PMyService"}, "links": [{"name": "Runbook", "type": "runbook", "url": "https://my-runbook"}], "repos": [{"name": "Source Code", "provider": "GitHub", "url": "https://github.com/DataDog/schema"}], "schema-version": "v2", "tags": ["my:tag", "service:tag"], "team": "my-team"} + When the request is sent + Then the response status is 409 Conflict + + @generated @skip @team:DataDog/apm-insights + Scenario: Delete a single service definition returns "Bad Request" response + Given new "DeleteServiceDefinition" request + And request contains "service_name" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @team:DataDog/apm-insights + Scenario: Delete a single service definition returns "Not Found" response + Given new "DeleteServiceDefinition" request + And request contains "service_name" parameter with value "not-a-service" + When the request is sent + Then the response status is 404 Not Found + And the response "errors[0]" is equal to "Not Found" + + @replay-only @team:DataDog/apm-insights + Scenario: Delete a single service definition returns "OK" response + Given there is a valid "service_definition" in the system + And new "DeleteServiceDefinition" request + And request contains "service_name" parameter with value "service-{{ unique }}" + When the request is sent + Then the response status is 204 OK + + @generated @skip @team:DataDog/apm-insights + Scenario: Get a single service definition returns "Bad Request" response + Given new "GetServiceDefinition" request + And request contains "service_name" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/apm-insights + Scenario: Get a single service definition returns "Conflict" response + Given new "GetServiceDefinition" request + And request contains "service_name" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 409 Conflict + + @team:DataDog/apm-insights + Scenario: Get a single service definition returns "Not Found" response + Given new "GetServiceDefinition" request + And request contains "service_name" parameter with value "not-a-service" + When the request is sent + Then the response status is 404 Not Found + And the response "errors[0]" is equal to "Not Found" + + @replay-only @team:DataDog/apm-insights + Scenario: Get a single service definition returns "OK" response + Given there is a valid "service_definition" in the system + And new "GetServiceDefinition" request + And request contains "service_name" parameter with value "service-{{ unique }}" + When the request is sent + Then the response status is 200 OK + And the response "data.attributes.meta.ingested-schema-version" is equal to "v2" + + @team:DataDog/apm-insights + Scenario: Get all service definitions returns "OK" response + Given new "ListServiceDefinitions" request + When the request is sent + Then the response status is 200 OK + And the response "data[0].attributes.meta.ingested-schema-version" is equal to "v2" diff --git a/features/v2/undo.json b/features/v2/undo.json index 80a6729cdff..fef02ce33c9 100644 --- a/features/v2/undo.json +++ b/features/v2/undo.json @@ -867,6 +867,37 @@ "type": "unsafe" } }, + "ListServiceDefinitions": { + "tag": "Service Definition", + "undo": { + "type": "safe" + } + }, + "CreateOrUpdateServiceDefinitions": { + "tag": "Service Definition", + "undo": { + "operationId": "DeleteServiceDefinition", + "parameters": [ + { + "name": "service_name", + "source": "data[0].attributes.schema.dd-service" + } + ], + "type": "unsafe" + } + }, + "DeleteServiceDefinition": { + "tag": "Service Definition", + "undo": { + "type": "idempotent" + } + }, + "GetServiceDefinition": { + "tag": "Service Definition", + "undo": { + "type": "safe" + } + }, "DeleteIncidentService": { "tag": "Incident Services", "undo": { diff --git a/packages/datadog-api-client-v2/apis/ServiceDefinitionApi.ts b/packages/datadog-api-client-v2/apis/ServiceDefinitionApi.ts new file mode 100644 index 00000000000..d8ad80ef3e3 --- /dev/null +++ b/packages/datadog-api-client-v2/apis/ServiceDefinitionApi.ts @@ -0,0 +1,540 @@ +import { + BaseAPIRequestFactory, + RequiredError, +} from "../../datadog-api-client-common/baseapi"; +import { + Configuration, + getServer, + applySecurityAuthentication, +} from "../../datadog-api-client-common/configuration"; +import { + RequestContext, + HttpMethod, + ResponseContext, +} from "../../datadog-api-client-common/http/http"; + +import { logger } from "../../../logger"; +import { ObjectSerializer } from "../models/ObjectSerializer"; +import { ApiException } from "../../datadog-api-client-common/exception"; + +import { APIErrorResponse } from "../models/APIErrorResponse"; +import { ServiceDefinitionGetResponse } from "../models/ServiceDefinitionGetResponse"; +import { ServiceDefinitionListResponse } from "../models/ServiceDefinitionListResponse"; +import { ServiceDefinitionsCreateRequest } from "../models/ServiceDefinitionsCreateRequest"; +import { ServiceDefinitionsCreateResponse } from "../models/ServiceDefinitionsCreateResponse"; + +export class ServiceDefinitionApiRequestFactory extends BaseAPIRequestFactory { + public async createOrUpdateServiceDefinitions( + body: ServiceDefinitionsCreateRequest, + _options?: Configuration + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'body' is not null or undefined + if (body === null || body === undefined) { + throw new RequiredError( + "Required parameter body was null or undefined when calling createOrUpdateServiceDefinitions." + ); + } + + // Path Params + const localVarPath = "/api/v2/services/definitions"; + + // Make Request Context + const requestContext = getServer( + _config, + "v2.ServiceDefinitionApi.createOrUpdateServiceDefinitions" + ).makeRequestContext(localVarPath, HttpMethod.POST); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Body Params + const contentType = ObjectSerializer.getPreferredMediaType([ + "application/json", + ]); + requestContext.setHeaderParam("Content-Type", contentType); + const serializedBody = ObjectSerializer.stringify( + ObjectSerializer.serialize(body, "ServiceDefinitionsCreateRequest", ""), + contentType + ); + requestContext.setBody(serializedBody); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + ]); + + return requestContext; + } + + public async deleteServiceDefinition( + serviceName: string, + _options?: Configuration + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'serviceName' is not null or undefined + if (serviceName === null || serviceName === undefined) { + throw new RequiredError( + "Required parameter serviceName was null or undefined when calling deleteServiceDefinition." + ); + } + + // Path Params + const localVarPath = "/api/v2/services/definitions/{service_name}".replace( + "{" + "service_name" + "}", + encodeURIComponent(String(serviceName)) + ); + + // Make Request Context + const requestContext = getServer( + _config, + "v2.ServiceDefinitionApi.deleteServiceDefinition" + ).makeRequestContext(localVarPath, HttpMethod.DELETE); + requestContext.setHeaderParam("Accept", "*/*"); + requestContext.setHttpConfig(_config.httpConfig); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + ]); + + return requestContext; + } + + public async getServiceDefinition( + serviceName: string, + _options?: Configuration + ): Promise { + const _config = _options || this.configuration; + + // verify required parameter 'serviceName' is not null or undefined + if (serviceName === null || serviceName === undefined) { + throw new RequiredError( + "Required parameter serviceName was null or undefined when calling getServiceDefinition." + ); + } + + // Path Params + const localVarPath = "/api/v2/services/definitions/{service_name}".replace( + "{" + "service_name" + "}", + encodeURIComponent(String(serviceName)) + ); + + // Make Request Context + const requestContext = getServer( + _config, + "v2.ServiceDefinitionApi.getServiceDefinition" + ).makeRequestContext(localVarPath, HttpMethod.GET); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + ]); + + return requestContext; + } + + public async listServiceDefinitions( + _options?: Configuration + ): Promise { + const _config = _options || this.configuration; + + // Path Params + const localVarPath = "/api/v2/services/definitions"; + + // Make Request Context + const requestContext = getServer( + _config, + "v2.ServiceDefinitionApi.listServiceDefinitions" + ).makeRequestContext(localVarPath, HttpMethod.GET); + requestContext.setHeaderParam("Accept", "application/json"); + requestContext.setHttpConfig(_config.httpConfig); + + // Apply auth methods + applySecurityAuthentication(_config, requestContext, [ + "apiKeyAuth", + "appKeyAuth", + ]); + + return requestContext; + } +} + +export class ServiceDefinitionApiResponseProcessor { + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to createOrUpdateServiceDefinitions + * @throws ApiException if the response code was not in [200, 299] + */ + public async createOrUpdateServiceDefinitions( + response: ResponseContext + ): Promise { + const contentType = ObjectSerializer.normalizeMediaType( + response.headers["content-type"] + ); + if (response.httpStatusCode == 200) { + const body: ServiceDefinitionListResponse = ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "ServiceDefinitionListResponse" + ) as ServiceDefinitionListResponse; + return body; + } + if ( + response.httpStatusCode == 400 || + response.httpStatusCode == 403 || + response.httpStatusCode == 409 || + response.httpStatusCode == 429 + ) { + const bodyText = ObjectSerializer.parse( + await response.body.text(), + contentType + ); + let body: APIErrorResponse; + try { + body = ObjectSerializer.deserialize( + bodyText, + "APIErrorResponse" + ) as APIErrorResponse; + } catch (error) { + logger.info(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: ServiceDefinitionListResponse = ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "ServiceDefinitionListResponse", + "" + ) as ServiceDefinitionListResponse; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"' + ); + } + + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to deleteServiceDefinition + * @throws ApiException if the response code was not in [200, 299] + */ + public async deleteServiceDefinition( + response: ResponseContext + ): Promise { + const contentType = ObjectSerializer.normalizeMediaType( + response.headers["content-type"] + ); + if (response.httpStatusCode == 204) { + return; + } + if ( + response.httpStatusCode == 400 || + response.httpStatusCode == 403 || + response.httpStatusCode == 404 || + response.httpStatusCode == 429 + ) { + const bodyText = ObjectSerializer.parse( + await response.body.text(), + contentType + ); + let body: APIErrorResponse; + try { + body = ObjectSerializer.deserialize( + bodyText, + "APIErrorResponse" + ) as APIErrorResponse; + } catch (error) { + logger.info(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: void = ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "void", + "" + ) as void; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"' + ); + } + + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to getServiceDefinition + * @throws ApiException if the response code was not in [200, 299] + */ + public async getServiceDefinition( + response: ResponseContext + ): Promise { + const contentType = ObjectSerializer.normalizeMediaType( + response.headers["content-type"] + ); + if (response.httpStatusCode == 200) { + const body: ServiceDefinitionGetResponse = ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "ServiceDefinitionGetResponse" + ) as ServiceDefinitionGetResponse; + return body; + } + if ( + response.httpStatusCode == 400 || + response.httpStatusCode == 403 || + response.httpStatusCode == 404 || + response.httpStatusCode == 409 || + response.httpStatusCode == 429 + ) { + const bodyText = ObjectSerializer.parse( + await response.body.text(), + contentType + ); + let body: APIErrorResponse; + try { + body = ObjectSerializer.deserialize( + bodyText, + "APIErrorResponse" + ) as APIErrorResponse; + } catch (error) { + logger.info(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: ServiceDefinitionGetResponse = ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "ServiceDefinitionGetResponse", + "" + ) as ServiceDefinitionGetResponse; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"' + ); + } + + /** + * Unwraps the actual response sent by the server from the response context and deserializes the response content + * to the expected objects + * + * @params response Response returned by the server for a request to listServiceDefinitions + * @throws ApiException if the response code was not in [200, 299] + */ + public async listServiceDefinitions( + response: ResponseContext + ): Promise { + const contentType = ObjectSerializer.normalizeMediaType( + response.headers["content-type"] + ); + if (response.httpStatusCode == 200) { + const body: ServiceDefinitionsCreateResponse = + ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "ServiceDefinitionsCreateResponse" + ) as ServiceDefinitionsCreateResponse; + return body; + } + if (response.httpStatusCode == 403 || response.httpStatusCode == 429) { + const bodyText = ObjectSerializer.parse( + await response.body.text(), + contentType + ); + let body: APIErrorResponse; + try { + body = ObjectSerializer.deserialize( + bodyText, + "APIErrorResponse" + ) as APIErrorResponse; + } catch (error) { + logger.info(`Got error deserializing error: ${error}`); + throw new ApiException( + response.httpStatusCode, + bodyText + ); + } + throw new ApiException(response.httpStatusCode, body); + } + + // Work around for missing responses in specification, e.g. for petstore.yaml + if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { + const body: ServiceDefinitionsCreateResponse = + ObjectSerializer.deserialize( + ObjectSerializer.parse(await response.body.text(), contentType), + "ServiceDefinitionsCreateResponse", + "" + ) as ServiceDefinitionsCreateResponse; + return body; + } + + const body = (await response.body.text()) || ""; + throw new ApiException( + response.httpStatusCode, + 'Unknown API Status Code!\nBody: "' + body + '"' + ); + } +} + +export interface ServiceDefinitionApiCreateOrUpdateServiceDefinitionsRequest { + /** + * Service Definition YAML/JSON. + * @type ServiceDefinitionsCreateRequest + */ + body: ServiceDefinitionsCreateRequest; +} + +export interface ServiceDefinitionApiDeleteServiceDefinitionRequest { + /** + * The name of the service. + * @type string + */ + serviceName: string; +} + +export interface ServiceDefinitionApiGetServiceDefinitionRequest { + /** + * The name of the service. + * @type string + */ + serviceName: string; +} + +export class ServiceDefinitionApi { + private requestFactory: ServiceDefinitionApiRequestFactory; + private responseProcessor: ServiceDefinitionApiResponseProcessor; + private configuration: Configuration; + + public constructor( + configuration: Configuration, + requestFactory?: ServiceDefinitionApiRequestFactory, + responseProcessor?: ServiceDefinitionApiResponseProcessor + ) { + this.configuration = configuration; + this.requestFactory = + requestFactory || new ServiceDefinitionApiRequestFactory(configuration); + this.responseProcessor = + responseProcessor || new ServiceDefinitionApiResponseProcessor(); + } + + /** + * Create or update service definition in the Datadog Service Catalog. + * @param param The request object + */ + public createOrUpdateServiceDefinitions( + param: ServiceDefinitionApiCreateOrUpdateServiceDefinitionsRequest, + options?: Configuration + ): Promise { + const requestContextPromise = + this.requestFactory.createOrUpdateServiceDefinitions(param.body, options); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.createOrUpdateServiceDefinitions( + responseContext + ); + }); + }); + } + + /** + * Delete a single service definition in the Datadog Service Catalog. + * @param param The request object + */ + public deleteServiceDefinition( + param: ServiceDefinitionApiDeleteServiceDefinitionRequest, + options?: Configuration + ): Promise { + const requestContextPromise = this.requestFactory.deleteServiceDefinition( + param.serviceName, + options + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.deleteServiceDefinition( + responseContext + ); + }); + }); + } + + /** + * Get a single service definition from the Datadog Service Catalog. + * @param param The request object + */ + public getServiceDefinition( + param: ServiceDefinitionApiGetServiceDefinitionRequest, + options?: Configuration + ): Promise { + const requestContextPromise = this.requestFactory.getServiceDefinition( + param.serviceName, + options + ); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.getServiceDefinition(responseContext); + }); + }); + } + + /** + * Get a list of all service definitions from the Datadog Service Catalog. + * @param param The request object + */ + public listServiceDefinitions( + options?: Configuration + ): Promise { + const requestContextPromise = + this.requestFactory.listServiceDefinitions(options); + return requestContextPromise.then((requestContext) => { + return this.configuration.httpApi + .send(requestContext) + .then((responseContext) => { + return this.responseProcessor.listServiceDefinitions(responseContext); + }); + }); + } +} diff --git a/packages/datadog-api-client-v2/index.ts b/packages/datadog-api-client-v2/index.ts index 29ba8e45cc1..7a77d3722c5 100644 --- a/packages/datadog-api-client-v2/index.ts +++ b/packages/datadog-api-client-v2/index.ts @@ -199,6 +199,13 @@ export { ServiceAccountsApi, } from "./apis/ServiceAccountsApi"; +export { + ServiceDefinitionApiCreateOrUpdateServiceDefinitionsRequest, + ServiceDefinitionApiDeleteServiceDefinitionRequest, + ServiceDefinitionApiGetServiceDefinitionRequest, + ServiceDefinitionApi, +} from "./apis/ServiceDefinitionApi"; + export { UsageMeteringApiGetCostByOrgRequest, UsageMeteringApiGetEstimatedCostByOrgRequest, @@ -746,6 +753,36 @@ export { SecurityMonitoringTriageUser } from "./models/SecurityMonitoringTriageU export { ServiceAccountCreateAttributes } from "./models/ServiceAccountCreateAttributes"; export { ServiceAccountCreateData } from "./models/ServiceAccountCreateData"; export { ServiceAccountCreateRequest } from "./models/ServiceAccountCreateRequest"; +export { ServiceDefinitionData } from "./models/ServiceDefinitionData"; +export { ServiceDefinitionDataAttributes } from "./models/ServiceDefinitionDataAttributes"; +export { ServiceDefinitionGetResponse } from "./models/ServiceDefinitionGetResponse"; +export { ServiceDefinitionListResponse } from "./models/ServiceDefinitionListResponse"; +export { ServiceDefinitionMeta } from "./models/ServiceDefinitionMeta"; +export { ServiceDefinitionSchema } from "./models/ServiceDefinitionSchema"; +export { ServiceDefinitionsCreateRequest } from "./models/ServiceDefinitionsCreateRequest"; +export { ServiceDefinitionsCreateResponse } from "./models/ServiceDefinitionsCreateResponse"; +export { ServiceDefinitionV1 } from "./models/ServiceDefinitionV1"; +export { ServiceDefinitionV1Contact } from "./models/ServiceDefinitionV1Contact"; +export { ServiceDefinitionV1Info } from "./models/ServiceDefinitionV1Info"; +export { ServiceDefinitionV1Integrations } from "./models/ServiceDefinitionV1Integrations"; +export { ServiceDefinitionV1Org } from "./models/ServiceDefinitionV1Org"; +export { ServiceDefinitionV1Resource } from "./models/ServiceDefinitionV1Resource"; +export { ServiceDefinitionV1ResourceType } from "./models/ServiceDefinitionV1ResourceType"; +export { ServiceDefinitionV1Version } from "./models/ServiceDefinitionV1Version"; +export { ServiceDefinitionV2 } from "./models/ServiceDefinitionV2"; +export { ServiceDefinitionV2Contact } from "./models/ServiceDefinitionV2Contact"; +export { ServiceDefinitionV2Doc } from "./models/ServiceDefinitionV2Doc"; +export { ServiceDefinitionV2Email } from "./models/ServiceDefinitionV2Email"; +export { ServiceDefinitionV2EmailType } from "./models/ServiceDefinitionV2EmailType"; +export { ServiceDefinitionV2Integrations } from "./models/ServiceDefinitionV2Integrations"; +export { ServiceDefinitionV2Link } from "./models/ServiceDefinitionV2Link"; +export { ServiceDefinitionV2LinkType } from "./models/ServiceDefinitionV2LinkType"; +export { ServiceDefinitionV2Opsgenie } from "./models/ServiceDefinitionV2Opsgenie"; +export { ServiceDefinitionV2OpsgenieRegion } from "./models/ServiceDefinitionV2OpsgenieRegion"; +export { ServiceDefinitionV2Repo } from "./models/ServiceDefinitionV2Repo"; +export { ServiceDefinitionV2Slack } from "./models/ServiceDefinitionV2Slack"; +export { ServiceDefinitionV2SlackType } from "./models/ServiceDefinitionV2SlackType"; +export { ServiceDefinitionV2Version } from "./models/ServiceDefinitionV2Version"; export { UsageApplicationSecurityMonitoringResponse } from "./models/UsageApplicationSecurityMonitoringResponse"; export { UsageAttributesObject } from "./models/UsageAttributesObject"; export { UsageDataObject } from "./models/UsageDataObject"; diff --git a/packages/datadog-api-client-v2/models/ObjectSerializer.ts b/packages/datadog-api-client-v2/models/ObjectSerializer.ts index 1ab1bb23575..7970be5cb9d 100644 --- a/packages/datadog-api-client-v2/models/ObjectSerializer.ts +++ b/packages/datadog-api-client-v2/models/ObjectSerializer.ts @@ -396,6 +396,26 @@ import { SecurityMonitoringTriageUser } from "./SecurityMonitoringTriageUser"; import { ServiceAccountCreateAttributes } from "./ServiceAccountCreateAttributes"; import { ServiceAccountCreateData } from "./ServiceAccountCreateData"; import { ServiceAccountCreateRequest } from "./ServiceAccountCreateRequest"; +import { ServiceDefinitionData } from "./ServiceDefinitionData"; +import { ServiceDefinitionDataAttributes } from "./ServiceDefinitionDataAttributes"; +import { ServiceDefinitionGetResponse } from "./ServiceDefinitionGetResponse"; +import { ServiceDefinitionListResponse } from "./ServiceDefinitionListResponse"; +import { ServiceDefinitionMeta } from "./ServiceDefinitionMeta"; +import { ServiceDefinitionV1 } from "./ServiceDefinitionV1"; +import { ServiceDefinitionV1Contact } from "./ServiceDefinitionV1Contact"; +import { ServiceDefinitionV1Info } from "./ServiceDefinitionV1Info"; +import { ServiceDefinitionV1Integrations } from "./ServiceDefinitionV1Integrations"; +import { ServiceDefinitionV1Org } from "./ServiceDefinitionV1Org"; +import { ServiceDefinitionV1Resource } from "./ServiceDefinitionV1Resource"; +import { ServiceDefinitionV2 } from "./ServiceDefinitionV2"; +import { ServiceDefinitionV2Doc } from "./ServiceDefinitionV2Doc"; +import { ServiceDefinitionV2Email } from "./ServiceDefinitionV2Email"; +import { ServiceDefinitionV2Integrations } from "./ServiceDefinitionV2Integrations"; +import { ServiceDefinitionV2Link } from "./ServiceDefinitionV2Link"; +import { ServiceDefinitionV2Opsgenie } from "./ServiceDefinitionV2Opsgenie"; +import { ServiceDefinitionV2Repo } from "./ServiceDefinitionV2Repo"; +import { ServiceDefinitionV2Slack } from "./ServiceDefinitionV2Slack"; +import { ServiceDefinitionsCreateResponse } from "./ServiceDefinitionsCreateResponse"; import { UsageApplicationSecurityMonitoringResponse } from "./UsageApplicationSecurityMonitoringResponse"; import { UsageAttributesObject } from "./UsageAttributesObject"; import { UsageDataObject } from "./UsageDataObject"; @@ -664,6 +684,33 @@ const enumsMap: { [key: string]: any[] } = { SecurityMonitoringSignalState: ["open", "archived", "under_review"], SecurityMonitoringSignalType: ["signal"], SecurityMonitoringSignalsSort: ["timestamp", "-timestamp"], + ServiceDefinitionV1ResourceType: [ + "doc", + "wiki", + "runbook", + "url", + "repo", + "dashboard", + "oncall", + "code", + "link", + ], + ServiceDefinitionV1Version: ["v1"], + ServiceDefinitionV2EmailType: ["email"], + ServiceDefinitionV2LinkType: [ + "doc", + "wiki", + "runbook", + "url", + "repo", + "dashboard", + "oncall", + "code", + "link", + ], + ServiceDefinitionV2OpsgenieRegion: ["US", "EU"], + ServiceDefinitionV2SlackType: ["slack"], + ServiceDefinitionV2Version: ["v2"], UsageTimeSeriesType: ["usage_timeseries"], UserInvitationsType: ["user_invitations"], UsersType: ["users"], @@ -1115,6 +1162,26 @@ const typeMap: { [index: string]: any } = { ServiceAccountCreateAttributes: ServiceAccountCreateAttributes, ServiceAccountCreateData: ServiceAccountCreateData, ServiceAccountCreateRequest: ServiceAccountCreateRequest, + ServiceDefinitionData: ServiceDefinitionData, + ServiceDefinitionDataAttributes: ServiceDefinitionDataAttributes, + ServiceDefinitionGetResponse: ServiceDefinitionGetResponse, + ServiceDefinitionListResponse: ServiceDefinitionListResponse, + ServiceDefinitionMeta: ServiceDefinitionMeta, + ServiceDefinitionV1: ServiceDefinitionV1, + ServiceDefinitionV1Contact: ServiceDefinitionV1Contact, + ServiceDefinitionV1Info: ServiceDefinitionV1Info, + ServiceDefinitionV1Integrations: ServiceDefinitionV1Integrations, + ServiceDefinitionV1Org: ServiceDefinitionV1Org, + ServiceDefinitionV1Resource: ServiceDefinitionV1Resource, + ServiceDefinitionV2: ServiceDefinitionV2, + ServiceDefinitionV2Doc: ServiceDefinitionV2Doc, + ServiceDefinitionV2Email: ServiceDefinitionV2Email, + ServiceDefinitionV2Integrations: ServiceDefinitionV2Integrations, + ServiceDefinitionV2Link: ServiceDefinitionV2Link, + ServiceDefinitionV2Opsgenie: ServiceDefinitionV2Opsgenie, + ServiceDefinitionV2Repo: ServiceDefinitionV2Repo, + ServiceDefinitionV2Slack: ServiceDefinitionV2Slack, + ServiceDefinitionsCreateResponse: ServiceDefinitionsCreateResponse, UsageApplicationSecurityMonitoringResponse: UsageApplicationSecurityMonitoringResponse, UsageAttributesObject: UsageAttributesObject, @@ -1204,6 +1271,12 @@ const oneOfMap: { [index: string]: string[] } = { "SecurityMonitoringStandardRuleResponse", "SecurityMonitoringSignalRuleResponse", ], + ServiceDefinitionSchema: ["ServiceDefinitionV1", "ServiceDefinitionV2"], + ServiceDefinitionV2Contact: [ + "ServiceDefinitionV2Email", + "ServiceDefinitionV2Slack", + ], + ServiceDefinitionsCreateRequest: ["ServiceDefinitionV2", "string"], UserResponseIncludedItem: ["Organization", "Permission", "Role"], }; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionData.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionData.ts new file mode 100644 index 00000000000..840a2ffd21d --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionData.ts @@ -0,0 +1,50 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionDataAttributes } from "./ServiceDefinitionDataAttributes"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service definition data. + */ +export class ServiceDefinitionData { + /** + * Service definition attributes. + */ + "attributes"?: ServiceDefinitionDataAttributes; + /** + * Service definition type. + */ + "type"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + attributes: { + baseName: "attributes", + type: "ServiceDefinitionDataAttributes", + }, + type: { + baseName: "type", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionData.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionDataAttributes.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionDataAttributes.ts new file mode 100644 index 00000000000..4b70959cb66 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionDataAttributes.ts @@ -0,0 +1,51 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionMeta } from "./ServiceDefinitionMeta"; +import { ServiceDefinitionSchema } from "./ServiceDefinitionSchema"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service definition attributes. + */ +export class ServiceDefinitionDataAttributes { + /** + * Metadata about a service definition. + */ + "meta"?: ServiceDefinitionMeta; + /** + * Service definition schema. + */ + "schema"?: ServiceDefinitionSchema; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + meta: { + baseName: "meta", + type: "ServiceDefinitionMeta", + }, + schema: { + baseName: "schema", + type: "ServiceDefinitionSchema", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionDataAttributes.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionGetResponse.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionGetResponse.ts new file mode 100644 index 00000000000..c5cd85f5ad0 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionGetResponse.ts @@ -0,0 +1,42 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionData } from "./ServiceDefinitionData"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Get service definition response. + */ +export class ServiceDefinitionGetResponse { + /** + * Service definition data. + */ + "data"?: ServiceDefinitionData; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "ServiceDefinitionData", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionGetResponse.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionListResponse.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionListResponse.ts new file mode 100644 index 00000000000..6d6b2f5270c --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionListResponse.ts @@ -0,0 +1,42 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionData } from "./ServiceDefinitionData"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Get service definitions response. + */ +export class ServiceDefinitionListResponse { + /** + * Get service definitions response payload. + */ + "data"?: Array; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "Array", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionListResponse.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionMeta.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionMeta.ts new file mode 100644 index 00000000000..3db026c648c --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionMeta.ts @@ -0,0 +1,65 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Metadata about a service definition. + */ +export class ServiceDefinitionMeta { + /** + * GitHub HTML URL. + */ + "githubHtmlUrl"?: string; + /** + * Ingestion schema version. + */ + "ingestedSchemaVersion"?: string; + /** + * Ingestion source of the service definition. + */ + "ingestionSource"?: string; + /** + * Last modified time of the service definition. + */ + "lastModifiedTime"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + githubHtmlUrl: { + baseName: "github-html-url", + type: "string", + }, + ingestedSchemaVersion: { + baseName: "ingested-schema-version", + type: "string", + }, + ingestionSource: { + baseName: "ingestion-source", + type: "string", + }, + lastModifiedTime: { + baseName: "last-modified-time", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionMeta.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionSchema.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionSchema.ts new file mode 100644 index 00000000000..7e253dba99c --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionSchema.ts @@ -0,0 +1,18 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV1 } from "./ServiceDefinitionV1"; +import { ServiceDefinitionV2 } from "./ServiceDefinitionV2"; + +import { UnparsedObject } from "../../datadog-api-client-common/util"; + +/** + * Service definition schema. + */ + +export type ServiceDefinitionSchema = + | ServiceDefinitionV1 + | ServiceDefinitionV2 + | UnparsedObject; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1.ts new file mode 100644 index 00000000000..2d6a14d9653 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1.ts @@ -0,0 +1,105 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV1Contact } from "./ServiceDefinitionV1Contact"; +import { ServiceDefinitionV1Info } from "./ServiceDefinitionV1Info"; +import { ServiceDefinitionV1Integrations } from "./ServiceDefinitionV1Integrations"; +import { ServiceDefinitionV1Org } from "./ServiceDefinitionV1Org"; +import { ServiceDefinitionV1Resource } from "./ServiceDefinitionV1Resource"; +import { ServiceDefinitionV1Version } from "./ServiceDefinitionV1Version"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Deprecated - Service definition V1 for providing additional service metadata and integrations. + */ +export class ServiceDefinitionV1 { + /** + * Contact information about the service. + */ + "contact"?: ServiceDefinitionV1Contact; + /** + * Extensions to V1 schema. + */ + "extensions"?: { [key: string]: any }; + /** + * A list of external links related to the services. + */ + "externalResources"?: Array; + /** + * Basic information about a service. + */ + "info": ServiceDefinitionV1Info; + /** + * Third party integrations that Datadog supports. + */ + "integrations"?: ServiceDefinitionV1Integrations; + /** + * Org related information about the service. + */ + "org"?: ServiceDefinitionV1Org; + /** + * Schema version being used. + */ + "schemaVersion": ServiceDefinitionV1Version; + /** + * A set of custom tags. + */ + "tags"?: Array; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + contact: { + baseName: "contact", + type: "ServiceDefinitionV1Contact", + }, + extensions: { + baseName: "extensions", + type: "{ [key: string]: any; }", + }, + externalResources: { + baseName: "external-resources", + type: "Array", + }, + info: { + baseName: "info", + type: "ServiceDefinitionV1Info", + required: true, + }, + integrations: { + baseName: "integrations", + type: "ServiceDefinitionV1Integrations", + }, + org: { + baseName: "org", + type: "ServiceDefinitionV1Org", + }, + schemaVersion: { + baseName: "schema-version", + type: "ServiceDefinitionV1Version", + required: true, + }, + tags: { + baseName: "tags", + type: "Array", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV1.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1Contact.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Contact.ts new file mode 100644 index 00000000000..e389b6b016f --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Contact.ts @@ -0,0 +1,50 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Contact information about the service. + */ +export class ServiceDefinitionV1Contact { + /** + * Service owner’s email. + */ + "email"?: string; + /** + * Service owner’s slack channel. + */ + "slack"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + email: { + baseName: "email", + type: "string", + format: "email", + }, + slack: { + baseName: "slack", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV1Contact.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1Info.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Info.ts new file mode 100644 index 00000000000..412c26e8f78 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Info.ts @@ -0,0 +1,66 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Basic information about a service. + */ +export class ServiceDefinitionV1Info { + /** + * Unique identifier of the service. Must be unique across all services and is used to match with a service in Datadog. + */ + "ddService": string; + /** + * A short description of the service. + */ + "description"?: string; + /** + * A friendly name of the service. + */ + "displayName"?: string; + /** + * Service tier. + */ + "serviceTier"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + ddService: { + baseName: "dd-service", + type: "string", + required: true, + }, + description: { + baseName: "description", + type: "string", + }, + displayName: { + baseName: "display-name", + type: "string", + }, + serviceTier: { + baseName: "service-tier", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV1Info.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1Integrations.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Integrations.ts new file mode 100644 index 00000000000..162145475d9 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Integrations.ts @@ -0,0 +1,41 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Third party integrations that Datadog supports. + */ +export class ServiceDefinitionV1Integrations { + /** + * PagerDuty service url for the service. + */ + "pagerduty"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + pagerduty: { + baseName: "pagerduty", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV1Integrations.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1Org.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Org.ts new file mode 100644 index 00000000000..0ffa917f8b2 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Org.ts @@ -0,0 +1,49 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Org related information about the service. + */ +export class ServiceDefinitionV1Org { + /** + * App feature for which this service supports. + */ + "application"?: string; + /** + * Team that owns the service. + */ + "team"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + application: { + baseName: "application", + type: "string", + }, + team: { + baseName: "team", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV1Org.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1Resource.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Resource.ts new file mode 100644 index 00000000000..2d4ffd638fd --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Resource.ts @@ -0,0 +1,61 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV1ResourceType } from "./ServiceDefinitionV1ResourceType"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service's external links. + */ +export class ServiceDefinitionV1Resource { + /** + * Link name. + */ + "name": string; + /** + * Link type. + */ + "type": ServiceDefinitionV1ResourceType; + /** + * Link URL. + */ + "url": string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + name: { + baseName: "name", + type: "string", + required: true, + }, + type: { + baseName: "type", + type: "ServiceDefinitionV1ResourceType", + required: true, + }, + url: { + baseName: "url", + type: "string", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV1Resource.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1ResourceType.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1ResourceType.ts new file mode 100644 index 00000000000..c6730258804 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1ResourceType.ts @@ -0,0 +1,25 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV1ResourceType = + | typeof DOC + | typeof WIKI + | typeof RUNBOOK + | typeof URL + | typeof REPO + | typeof DASHBOARD + | typeof ONCALL + | typeof CODE + | typeof LINK; +export const DOC = "doc"; +export const WIKI = "wiki"; +export const RUNBOOK = "runbook"; +export const URL = "url"; +export const REPO = "repo"; +export const DASHBOARD = "dashboard"; +export const ONCALL = "oncall"; +export const CODE = "code"; +export const LINK = "link"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV1Version.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Version.ts new file mode 100644 index 00000000000..f376e1dcbdb --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV1Version.ts @@ -0,0 +1,8 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV1Version = typeof v1; +export const v1 = "v1"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2.ts new file mode 100644 index 00000000000..ca1044e71da --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2.ts @@ -0,0 +1,129 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2Contact } from "./ServiceDefinitionV2Contact"; +import { ServiceDefinitionV2Doc } from "./ServiceDefinitionV2Doc"; +import { ServiceDefinitionV2Integrations } from "./ServiceDefinitionV2Integrations"; +import { ServiceDefinitionV2Link } from "./ServiceDefinitionV2Link"; +import { ServiceDefinitionV2Repo } from "./ServiceDefinitionV2Repo"; +import { ServiceDefinitionV2Version } from "./ServiceDefinitionV2Version"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service definition V2 for providing service metadata and integrations. + */ +export class ServiceDefinitionV2 { + /** + * A list of contacts related to the services. + */ + "contacts"?: Array; + /** + * Unique identifier of the service. Must be unique across all services and is used to match with a service in Datadog. + */ + "ddService": string; + /** + * Experimental feature. A Team handle that matches a Team in the Datadog Teams product. + */ + "ddTeam"?: string; + /** + * A list of documentation related to the services. + */ + "docs"?: Array; + /** + * Extensions to V2 schema. + */ + "extensions"?: { [key: string]: any }; + /** + * Third party integrations that Datadog supports. + */ + "integrations"?: ServiceDefinitionV2Integrations; + /** + * A list of links related to the services. + */ + "links"?: Array; + /** + * A list of code repositories related to the services. + */ + "repos"?: Array; + /** + * Schema version being used. + */ + "schemaVersion": ServiceDefinitionV2Version; + /** + * A set of custom tags. + */ + "tags"?: Array; + /** + * Team that owns the service. + */ + "team"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + contacts: { + baseName: "contacts", + type: "Array", + }, + ddService: { + baseName: "dd-service", + type: "string", + required: true, + }, + ddTeam: { + baseName: "dd-team", + type: "string", + }, + docs: { + baseName: "docs", + type: "Array", + }, + extensions: { + baseName: "extensions", + type: "{ [key: string]: any; }", + }, + integrations: { + baseName: "integrations", + type: "ServiceDefinitionV2Integrations", + }, + links: { + baseName: "links", + type: "Array", + }, + repos: { + baseName: "repos", + type: "Array", + }, + schemaVersion: { + baseName: "schema-version", + type: "ServiceDefinitionV2Version", + required: true, + }, + tags: { + baseName: "tags", + type: "Array", + }, + team: { + baseName: "team", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Contact.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Contact.ts new file mode 100644 index 00000000000..62de7f0c5f1 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Contact.ts @@ -0,0 +1,18 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2Email } from "./ServiceDefinitionV2Email"; +import { ServiceDefinitionV2Slack } from "./ServiceDefinitionV2Slack"; + +import { UnparsedObject } from "../../datadog-api-client-common/util"; + +/** + * Service owner's contacts information. + */ + +export type ServiceDefinitionV2Contact = + | ServiceDefinitionV2Email + | ServiceDefinitionV2Slack + | UnparsedObject; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Doc.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Doc.ts new file mode 100644 index 00000000000..e507da92751 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Doc.ts @@ -0,0 +1,59 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service documents. + */ +export class ServiceDefinitionV2Doc { + /** + * Document name. + */ + "name": string; + /** + * Document provider. + */ + "provider"?: string; + /** + * Document URL. + */ + "url": string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + name: { + baseName: "name", + type: "string", + required: true, + }, + provider: { + baseName: "provider", + type: "string", + }, + url: { + baseName: "url", + type: "string", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Doc.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Email.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Email.ts new file mode 100644 index 00000000000..9e0303cc025 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Email.ts @@ -0,0 +1,61 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2EmailType } from "./ServiceDefinitionV2EmailType"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service owner's email. + */ +export class ServiceDefinitionV2Email { + /** + * Contact value. + */ + "contact": string; + /** + * Contact email. + */ + "name"?: string; + /** + * Contact type. + */ + "type": ServiceDefinitionV2EmailType; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + contact: { + baseName: "contact", + type: "string", + required: true, + format: "email", + }, + name: { + baseName: "name", + type: "string", + }, + type: { + baseName: "type", + type: "ServiceDefinitionV2EmailType", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Email.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2EmailType.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2EmailType.ts new file mode 100644 index 00000000000..ad228e75977 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2EmailType.ts @@ -0,0 +1,8 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV2EmailType = typeof EMAIL; +export const EMAIL = "email"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Integrations.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Integrations.ts new file mode 100644 index 00000000000..f0fc5e110fe --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Integrations.ts @@ -0,0 +1,50 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2Opsgenie } from "./ServiceDefinitionV2Opsgenie"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Third party integrations that Datadog supports. + */ +export class ServiceDefinitionV2Integrations { + /** + * Opsgenie integration for the service. + */ + "opsgenie"?: ServiceDefinitionV2Opsgenie; + /** + * PagerDuty service URL for the service. + */ + "pagerduty"?: string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + opsgenie: { + baseName: "opsgenie", + type: "ServiceDefinitionV2Opsgenie", + }, + pagerduty: { + baseName: "pagerduty", + type: "string", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Integrations.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Link.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Link.ts new file mode 100644 index 00000000000..01c57cd08a2 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Link.ts @@ -0,0 +1,61 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2LinkType } from "./ServiceDefinitionV2LinkType"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service's external links. + */ +export class ServiceDefinitionV2Link { + /** + * Link name. + */ + "name": string; + /** + * Link type. + */ + "type": ServiceDefinitionV2LinkType; + /** + * Link URL. + */ + "url": string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + name: { + baseName: "name", + type: "string", + required: true, + }, + type: { + baseName: "type", + type: "ServiceDefinitionV2LinkType", + required: true, + }, + url: { + baseName: "url", + type: "string", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Link.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2LinkType.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2LinkType.ts new file mode 100644 index 00000000000..ace4c775081 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2LinkType.ts @@ -0,0 +1,25 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV2LinkType = + | typeof DOC + | typeof WIKI + | typeof RUNBOOK + | typeof URL + | typeof REPO + | typeof DASHBOARD + | typeof ONCALL + | typeof CODE + | typeof LINK; +export const DOC = "doc"; +export const WIKI = "wiki"; +export const RUNBOOK = "runbook"; +export const URL = "url"; +export const REPO = "repo"; +export const DASHBOARD = "dashboard"; +export const ONCALL = "oncall"; +export const CODE = "code"; +export const LINK = "link"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Opsgenie.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Opsgenie.ts new file mode 100644 index 00000000000..efc7e9b5a02 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Opsgenie.ts @@ -0,0 +1,51 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2OpsgenieRegion } from "./ServiceDefinitionV2OpsgenieRegion"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Opsgenie integration for the service. + */ +export class ServiceDefinitionV2Opsgenie { + /** + * Opsgenie instance region. + */ + "region"?: ServiceDefinitionV2OpsgenieRegion; + /** + * Opsgenie service id. + */ + "serviceId": string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + region: { + baseName: "region", + type: "ServiceDefinitionV2OpsgenieRegion", + }, + serviceId: { + baseName: "service-id", + type: "string", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Opsgenie.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2OpsgenieRegion.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2OpsgenieRegion.ts new file mode 100644 index 00000000000..55fc3b9e31d --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2OpsgenieRegion.ts @@ -0,0 +1,9 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV2OpsgenieRegion = typeof US | typeof EU; +export const US = "US"; +export const EU = "EU"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Repo.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Repo.ts new file mode 100644 index 00000000000..79d78f1e5dd --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Repo.ts @@ -0,0 +1,59 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service code repositories. + */ +export class ServiceDefinitionV2Repo { + /** + * Repository name. + */ + "name": string; + /** + * Repository provider. + */ + "provider"?: string; + /** + * Repository URL. + */ + "url": string; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + name: { + baseName: "name", + type: "string", + required: true, + }, + provider: { + baseName: "provider", + type: "string", + }, + url: { + baseName: "url", + type: "string", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Repo.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Slack.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Slack.ts new file mode 100644 index 00000000000..dee22c1a1cf --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Slack.ts @@ -0,0 +1,60 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2SlackType } from "./ServiceDefinitionV2SlackType"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Service owner's slack channel. + */ +export class ServiceDefinitionV2Slack { + /** + * Slack Channel. + */ + "contact": string; + /** + * Contact Slack. + */ + "name"?: string; + /** + * Contact type. + */ + "type": ServiceDefinitionV2SlackType; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + contact: { + baseName: "contact", + type: "string", + required: true, + }, + name: { + baseName: "name", + type: "string", + }, + type: { + baseName: "type", + type: "ServiceDefinitionV2SlackType", + required: true, + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionV2Slack.attributeTypeMap; + } + + public constructor() {} +} diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2SlackType.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2SlackType.ts new file mode 100644 index 00000000000..2af79139400 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2SlackType.ts @@ -0,0 +1,8 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV2SlackType = typeof SLACK; +export const SLACK = "slack"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionV2Version.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Version.ts new file mode 100644 index 00000000000..3bbada44c39 --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionV2Version.ts @@ -0,0 +1,8 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ + +export type ServiceDefinitionV2Version = typeof V2; +export const V2 = "v2"; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionsCreateRequest.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionsCreateRequest.ts new file mode 100644 index 00000000000..6fa88f97bce --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionsCreateRequest.ts @@ -0,0 +1,17 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionV2 } from "./ServiceDefinitionV2"; + +import { UnparsedObject } from "../../datadog-api-client-common/util"; + +/** + * Create service definitions request. + */ + +export type ServiceDefinitionsCreateRequest = + | ServiceDefinitionV2 + | string + | UnparsedObject; diff --git a/packages/datadog-api-client-v2/models/ServiceDefinitionsCreateResponse.ts b/packages/datadog-api-client-v2/models/ServiceDefinitionsCreateResponse.ts new file mode 100644 index 00000000000..92b4cc3eb6e --- /dev/null +++ b/packages/datadog-api-client-v2/models/ServiceDefinitionsCreateResponse.ts @@ -0,0 +1,42 @@ +/** + * Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + * This product includes software developed at Datadog (https://www.datadoghq.com/). + * Copyright 2020-Present Datadog, Inc. + */ +import { ServiceDefinitionData } from "./ServiceDefinitionData"; + +import { AttributeTypeMap } from "../../datadog-api-client-common/util"; + +/** + * Create service definitions response. + */ +export class ServiceDefinitionsCreateResponse { + /** + * Data representing service definitions. + */ + "data"?: Array; + + /** + * @ignore + */ + "unparsedObject"?: any; + + /** + * @ignore + */ + static readonly attributeTypeMap: AttributeTypeMap = { + data: { + baseName: "data", + type: "Array", + }, + }; + + /** + * @ignore + */ + static getAttributeTypeMap(): AttributeTypeMap { + return ServiceDefinitionsCreateResponse.attributeTypeMap; + } + + public constructor() {} +}