Sha256: bff6299968ce44e141eda5fded909e51e23f60008918364b29a8994c8b45bb01

Contents?: true

Size: 688 Bytes

Versions: 3

Compression:

Stored size: 688 Bytes

Contents

# Create a new entry for your service account with cspm enabled returns "OK" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::GCPIntegrationAPI.new

body = DatadogAPIClient::V2::GCPSTSServiceAccountCreateRequest.new({
  data: DatadogAPIClient::V2::GCPSTSServiceAccountData.new({
    attributes: DatadogAPIClient::V2::GCPSTSServiceAccountAttributes.new({
      is_cspm_enabled: true,
      resource_collection_enabled: true,
      client_email: "252bf553ef04b351@test-project.iam.gserviceaccount.com",
      host_filters: [],
    }),
    type: DatadogAPIClient::V2::GCPServiceAccountType::GCP_SERVICE_ACCOUNT,
  }),
})
p api_instance.create_gcpsts_account(body)

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
datadog_api_client-2.21.0 examples/v2/gcp-integration/CreateGCPSTSAccount_4235664992.rb
datadog_api_client-2.20.0 examples/v2/gcp-integration/CreateGCPSTSAccount_4235664992.rb
datadog_api_client-2.19.0 examples/v2/gcp-integration/CreateGCPSTSAccount_4235664992.rb