CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/golang-github-com-data-dog--datadog-api-client-go-v2

Comprehensive Go API client for the Datadog monitoring and analytics platform with strongly-typed interfaces for all Datadog API v1 and v2 endpoints

Overview
Eval results
Files

additional-apis.mddocs/v2/

V2 Additional APIs

Additional v2 APIs including security, CI/CD, teams, cloud integrations, and specialized features.

Package Import

import (
    "context"
    "github.com/DataDog/datadog-api-client-go/v2/api/datadog"
    "github.com/DataDog/datadog-api-client-go/v2/api/datadogV2"
)

Security Monitoring API

Comprehensive security monitoring, rules, and threat detection.

API Client

type SecurityMonitoringApi struct {
    // contains filtered or unexported fields
}

func NewSecurityMonitoringApi(client *datadog.APIClient) *SecurityMonitoringApi

Key Methods

Security rules: CreateSecurityMonitoringRule, DeleteSecurityMonitoringRule, GetSecurityMonitoringRule, ListSecurityMonitoringRules, UpdateSecurityMonitoringRule, TestSecurityMonitoringRule, ValidateSecurityMonitoringRule

Security signals: EditSecurityMonitoringSignalAssignee, EditSecurityMonitoringSignalState, GetSecurityMonitoringSignal, ListSecurityMonitoringSignals, SearchSecurityMonitoringSignals

Suppressions: CreateSecurityMonitoringSuppression, DeleteSecurityMonitoringSuppression, GetSecurityMonitoringSuppression, ListSecurityMonitoringSuppressions, UpdateSecurityMonitoringSuppression

Findings: GetFinding, ListFindings, ListSecurityFindings, SearchSecurityFindings, MuteFindings

Critical assets: CreateSecurityMonitoringCriticalAsset, DeleteSecurityMonitoringCriticalAsset, GetSecurityMonitoringCriticalAsset, ListSecurityMonitoringCriticalAssets

Vulnerabilities: ListVulnerabilities, ListVulnerableAssets, GetSBOM, ListAssetsSBOMs

Application Security API

Web Application Firewall rules and exclusion filters.

API Client

type ApplicationSecurityApi struct {
    // contains filtered or unexported fields
}

func NewApplicationSecurityApi(client *datadog.APIClient) *ApplicationSecurityApi

Methods

func (a *ApplicationSecurityApi) CreateApplicationSecurityWafCustomRule(
    ctx context.Context,
    body datadogV2.WafRuleCreatePayload,
) (datadogV2.WafRuleResponse, *http.Response, error)
func (a *ApplicationSecurityApi) CreateApplicationSecurityWafExclusionFilter(
    ctx context.Context,
    body datadogV2.WafExclusionCreatePayload,
) (datadogV2.WafExclusionResponse, *http.Response, error)
func (a *ApplicationSecurityApi) DeleteApplicationSecurityWafCustomRule(
    ctx context.Context,
    ruleId string,
) (*http.Response, error)
func (a *ApplicationSecurityApi) GetApplicationSecurityWafCustomRule(
    ctx context.Context,
    ruleId string,
) (datadogV2.WafRuleResponse, *http.Response, error)
func (a *ApplicationSecurityApi) ListApplicationSecurityWAFCustomRules(
    ctx context.Context,
) (datadogV2.WafRulesResponse, *http.Response, error)
func (a *ApplicationSecurityApi) UpdateApplicationSecurityWafCustomRule(
    ctx context.Context,
    ruleId string,
    body datadogV2.WafRuleUpdatePayload,
) (datadogV2.WafRuleResponse, *http.Response, error)

Teams API

Team collaboration and management.

API Client

type TeamsApi struct {
    // contains filtered or unexported fields
}

func NewTeamsApi(client *datadog.APIClient) *TeamsApi

Key Methods

Teams: CreateTeam, DeleteTeam, GetTeam, ListTeams, UpdateTeam

Memberships: AddMemberTeam, CreateTeamMembership, DeleteTeamMembership, GetTeamMemberships, GetUserMemberships, ListMemberTeams, RemoveMemberTeam, UpdateTeamMembership

Links: CreateTeamLink, DeleteTeamLink, GetTeamLink, GetTeamLinks, UpdateTeamLink

Hierarchy: AddTeamHierarchyLink, GetTeamHierarchyLink, ListTeamHierarchyLinks, RemoveTeamHierarchyLink

Connections: CreateTeamConnections, DeleteTeamConnections, ListTeamConnections

Permissions: GetTeamPermissionSettings, UpdateTeamPermissionSetting

Notification rules: CreateTeamNotificationRule, DeleteTeamNotificationRule, GetTeamNotificationRule, GetTeamNotificationRules, UpdateTeamNotificationRule

Example Usage

// Create a team
attrs := datadogV2.NewTeamCreateAttributes(
    "team-handle",
    "Engineering Team",
)
attrs.SetDescription("Backend engineering team")

data := datadogV2.NewTeamCreateData(*attrs, datadogV2.TEAMTYPE_TEAM)
body := datadogV2.NewTeamCreateRequest(*data)

resp, r, err := teamsApi.CreateTeam(ctx, *body)
if err != nil {
    fmt.Fprintf(os.Stderr, "Error: %v\n", err)
    return
}

fmt.Printf("Team created: %s\n", resp.Data.Attributes.GetName())

Users API

Enhanced user management.

API Client

type UsersApi struct {
    // contains filtered or unexported fields
}

func NewUsersApi(client *datadog.APIClient) *UsersApi

Methods

func (a *UsersApi) CreateUser(
    ctx context.Context,
    body datadogV2.UserCreateRequest,
) (datadogV2.UserResponse, *http.Response, error)
func (a *UsersApi) DisableUser(
    ctx context.Context,
    userId string,
) (*http.Response, error)
func (a *UsersApi) GetInvitation(
    ctx context.Context,
    userInvitationUuid string,
) (datadogV2.UserInvitationResponse, *http.Response, error)
func (a *UsersApi) GetUser(
    ctx context.Context,
    userId string,
) (datadogV2.UserResponse, *http.Response, error)
func (a *UsersApi) ListUserOrganizations(
    ctx context.Context,
    userId string,
) (datadogV2.UserResponse, *http.Response, error)
func (a *UsersApi) ListUserPermissions(
    ctx context.Context,
    userId string,
) (datadogV2.PermissionsResponse, *http.Response, error)
func (a *UsersApi) ListUsers(
    ctx context.Context,
    o ...ListUsersOptionalParameters,
) (datadogV2.UsersResponse, *http.Response, error)
func (a *UsersApi) SendInvitations(
    ctx context.Context,
    body datadogV2.UserInvitationsRequest,
) (datadogV2.UserInvitationsResponse, *http.Response, error)
func (a *UsersApi) UpdateUser(
    ctx context.Context,
    userId string,
    body datadogV2.UserUpdateRequest,
) (datadogV2.UserResponse, *http.Response, error)

Roles API

Role-based access control management.

API Client

type RolesApi struct {
    // contains filtered or unexported fields
}

func NewRolesApi(client *datadog.APIClient) *RolesApi

Methods

func (a *RolesApi) AddPermissionToRole(
    ctx context.Context,
    roleId string,
    body datadogV2.RelationshipToPermission,
) (datadogV2.PermissionsResponse, *http.Response, error)
func (a *RolesApi) AddUserToRole(
    ctx context.Context,
    roleId string,
    body datadogV2.RelationshipToUser,
) (datadogV2.UsersResponse, *http.Response, error)
func (a *RolesApi) CloneRole(
    ctx context.Context,
    roleId string,
    body datadogV2.RoleCloneRequest,
) (datadogV2.RoleResponse, *http.Response, error)
func (a *RolesApi) CreateRole(
    ctx context.Context,
    body datadogV2.RoleCreateRequest,
) (datadogV2.RoleCreateResponse, *http.Response, error)
func (a *RolesApi) DeleteRole(
    ctx context.Context,
    roleId string,
) (*http.Response, error)
func (a *RolesApi) GetRole(
    ctx context.Context,
    roleId string,
) (datadogV2.RoleResponse, *http.Response, error)
func (a *RolesApi) ListPermissions(
    ctx context.Context,
) (datadogV2.PermissionsResponse, *http.Response, error)
func (a *RolesApi) ListRolePermissions(
    ctx context.Context,
    roleId string,
) (datadogV2.PermissionsResponse, *http.Response, error)
func (a *RolesApi) ListRoleUsers(
    ctx context.Context,
    roleId string,
    o ...ListRoleUsersOptionalParameters,
) (datadogV2.UsersResponse, *http.Response, error)
func (a *RolesApi) ListRoles(
    ctx context.Context,
    o ...ListRolesOptionalParameters,
) (datadogV2.RolesResponse, *http.Response, error)

CI Visibility APIs

CI Visibility Pipelines API

type CIVisibilityPipelinesApi struct {
    // contains filtered or unexported fields
}

func NewCIVisibilityPipelinesApi(client *datadog.APIClient) *CIVisibilityPipelinesApi

Methods: AggregateCIAppPipelineEvents, CreateCIAppPipelineEvent, ListCIAppPipelineEvents, SearchCIAppPipelineEvents

CI Visibility Tests API

type CIVisibilityTestsApi struct {
    // contains filtered or unexported fields
}

func NewCIVisibilityTestsApi(client *datadog.APIClient) *CIVisibilityTestsApi

Methods: AggregateCIAppTestEvents, ListCIAppTestEvents, SearchCIAppTestEvents

Test Optimization API

type TestOptimizationApi struct {
    // contains filtered or unexported fields
}

func NewTestOptimizationApi(client *datadog.APIClient) *TestOptimizationApi

Methods: SearchFlakyTests, SearchFlakyTestsWithPagination

Cloud Integration APIs

AWS Integration API

type AWSIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewAWSIntegrationApi(client *datadog.APIClient) *AWSIntegrationApi

Methods: CreateAWSAccount, CreateAWSEventBridgeSource, CreateNewAWSExternalID, DeleteAWSAccount, DeleteAWSEventBridgeSource, GetAWSAccount, GetAWSIntegrationIAMPermissions, ListAWSAccounts, ListAWSEventBridgeSources, ListAWSNamespaces, UpdateAWSAccount

GCP Integration API

type GCPIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewGCPIntegrationApi(client *datadog.APIClient) *GCPIntegrationApi

Methods: CreateGCPSTSAccount, DeleteGCPSTSAccount, GetGCPSTSDelegate, ListGCPSTSAccounts, MakeGCPSTSDelegate, UpdateGCPSTSAccount

Cloudflare Integration API

type CloudflareIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewCloudflareIntegrationApi(client *datadog.APIClient) *CloudflareIntegrationApi

Methods: CreateCloudflareAccount, DeleteCloudflareAccount, GetCloudflareAccount, ListCloudflareAccounts, UpdateCloudflareAccount

Confluent Cloud API

type ConfluentCloudApi struct {
    // contains filtered or unexported fields
}

func NewConfluentCloudApi(client *datadog.APIClient) *ConfluentCloudApi

Methods: CreateConfluentAccount, CreateConfluentResource, DeleteConfluentAccount, DeleteConfluentResource, GetConfluentAccount, GetConfluentResource, ListConfluentAccount, ListConfluentResource, UpdateConfluentAccount, UpdateConfluentResource

Fastly Integration API

type FastlyIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewFastlyIntegrationApi(client *datadog.APIClient) *FastlyIntegrationApi

Methods: CreateFastlyAccount, CreateFastlyService, DeleteFastlyAccount, DeleteFastlyService, GetFastlyAccount, GetFastlyService, ListFastlyAccounts, ListFastlyServices, UpdateFastlyAccount, UpdateFastlyService

Okta Integration API

type OktaIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewOktaIntegrationApi(client *datadog.APIClient) *OktaIntegrationApi

Methods: CreateOktaAccount, DeleteOktaAccount, GetOktaAccount, ListOktaAccounts, UpdateOktaAccount

Opsgenie Integration API

type OpsgenieIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewOpsgenieIntegrationApi(client *datadog.APIClient) *OpsgenieIntegrationApi

Methods: CreateOpsgenieService, DeleteOpsgenieService, GetOpsgenieService, ListOpsgenieServices, UpdateOpsgenieService

Microsoft Teams Integration API

type MicrosoftTeamsIntegrationApi struct {
    // contains filtered or unexported fields
}

func NewMicrosoftTeamsIntegrationApi(client *datadog.APIClient) *MicrosoftTeamsIntegrationApi

Methods: CreateTenantBasedHandle, CreateWorkflowsWebhookHandle, DeleteTenantBasedHandle, DeleteWorkflowsWebhookHandle, GetChannelByName, GetTenantBasedHandle, GetWorkflowsWebhookHandle, ListTenantBasedHandles, ListWorkflowsWebhookHandles, UpdateTenantBasedHandle, UpdateWorkflowsWebhookHandle

Workflow and Automation APIs

Workflow Automation API

type WorkflowAutomationApi struct {
    // contains filtered or unexported fields
}

func NewWorkflowAutomationApi(client *datadog.APIClient) *WorkflowAutomationApi

Methods: CancelWorkflowInstance, CreateWorkflow, CreateWorkflowInstance, DeleteWorkflow, GetWorkflow, GetWorkflowInstance, ListWorkflowInstances, UpdateWorkflow

Fleet Automation API

type FleetAutomationApi struct {
    // contains filtered or unexported fields
}

func NewFleetAutomationApi(client *datadog.APIClient) *FleetAutomationApi

Methods: CancelFleetDeployment, CreateFleetDeploymentConfigure, CreateFleetDeploymentUpgrade, CreateFleetSchedule, DeleteFleetSchedule, GetFleetAgentInfo, GetFleetDeployment, GetFleetSchedule, ListFleetAgentVersions, ListFleetAgents, ListFleetDeployments, ListFleetSchedules, TriggerFleetSchedule, UpdateFleetSchedule

Action Connection API

type ActionConnectionApi struct {
    // contains filtered or unexported fields
}

func NewActionConnectionApi(client *datadog.APIClient) *ActionConnectionApi

Methods: CreateActionConnection, DeleteActionConnection, GetActionConnection, GetAppKeyRegistration, ListAppKeyRegistrations, RegisterAppKey, UnregisterAppKey, UpdateActionConnection

Actions Datastores API

type ActionsDatastoresApi struct {
    // contains filtered or unexported fields
}

func NewActionsDatastoresApi(client *datadog.APIClient) *ActionsDatastoresApi

Methods: BulkDeleteDatastoreItems, BulkWriteDatastoreItems, CreateDatastore, DeleteDatastore, DeleteDatastoreItem, GetDatastore, ListDatastoreItems, ListDatastores, UpdateDatastore, UpdateDatastoreItem

Infrastructure APIs

Containers API

type ContainersApi struct {
    // contains filtered or unexported fields
}

func NewContainersApi(client *datadog.APIClient) *ContainersApi

Methods: ListContainers, ListContainersWithPagination

Container Images API

type ContainerImagesApi struct {
    // contains filtered or unexported fields
}

func NewContainerImagesApi(client *datadog.APIClient) *ContainerImagesApi

Methods: ListContainerImages, ListContainerImagesWithPagination

Processes API

type ProcessesApi struct {
    // contains filtered or unexported fields
}

func NewProcessesApi(client *datadog.APIClient) *ProcessesApi

Methods: ListProcesses, ListProcessesWithPagination

Network Device Monitoring API

type NetworkDeviceMonitoringApi struct {
    // contains filtered or unexported fields
}

func NewNetworkDeviceMonitoringApi(client *datadog.APIClient) *NetworkDeviceMonitoringApi

Methods: GetDevice, GetInterfaces, ListDeviceUserTags, ListDevices, UpdateDeviceUserTags

Cost Management APIs

Cloud Cost Management API

type CloudCostManagementApi struct {
    // contains filtered or unexported fields
}

func NewCloudCostManagementApi(client *datadog.APIClient) *CloudCostManagementApi

Key methods: CreateCostAWSCURConfig, CreateCostAzureUCConfigs, CreateCostGCPUsageCostConfig, CreateCustomAllocationRule, DeleteBudget, GetBudget, ListBudgets, UploadCustomCostsFile, UpsertBudget, ValidateQuery

Usage Metering API

type UsageMeteringApi struct {
    // contains filtered or unexported fields
}

func NewUsageMeteringApi(client *datadog.APIClient) *UsageMeteringApi

Methods: GetActiveBillingDimensions, GetBillingDimensionMapping, GetCostByOrg, GetEstimatedCostByOrg, GetHistoricalCostByOrg, GetHourlyUsage, GetMonthlyCostAttribution, GetProjectedCost, GetUsageApplicationSecurityMonitoring, GetUsageLambdaTracedInvocations, GetUsageObservabilityPipelines

Service Management APIs

Service Definition API

type ServiceDefinitionApi struct {
    // contains filtered or unexported fields
}

func NewServiceDefinitionApi(client *datadog.APIClient) *ServiceDefinitionApi

Methods: CreateOrUpdateServiceDefinitions, DeleteServiceDefinition, GetServiceDefinition, ListServiceDefinitions

Service Scorecards API

type ServiceScorecardsApi struct {
    // contains filtered or unexported fields
}

func NewServiceScorecardsApi(client *datadog.APIClient) *ServiceScorecardsApi

Methods: CreateScorecardOutcomesBatch, CreateScorecardRule, DeleteScorecardRule, ListScorecardOutcomes, ListScorecardRules, UpdateScorecardOutcomesAsync, UpdateScorecardRule

Software Catalog API

type SoftwareCatalogApi struct {
    // contains filtered or unexported fields
}

func NewSoftwareCatalogApi(client *datadog.APIClient) *SoftwareCatalogApi

Methods: DeleteCatalogEntity, DeleteCatalogKind, ListCatalogEntity, ListCatalogKind, ListCatalogRelation, PreviewCatalogEntities, UpsertCatalogEntity, UpsertCatalogKind

Additional Specialized APIs

DORA Metrics API

type DORAMetricsApi struct {
    // contains filtered or unexported fields
}

func NewDORAMetricsApi(client *datadog.APIClient) *DORAMetricsApi

Methods: CreateDORADeployment, CreateDORAFailure, CreateDORAIncident, DeleteDORADeployment, DeleteDORAFailure, GetDORADeployment, GetDORAFailure, ListDORADeployments, ListDORAFailures

On-Call Management API

type OnCallApi struct {
    // contains filtered or unexported fields
}

func NewOnCallApi(client *datadog.APIClient) *OnCallApi

Methods: CreateOnCallEscalationPolicy, CreateOnCallSchedule, CreateUserNotificationChannel, CreateUserNotificationRule, GetOnCallEscalationPolicy, GetOnCallSchedule, GetOnCallTeamRoutingRules, GetScheduleOnCallUser, GetTeamOnCallUsers, SetOnCallTeamRoutingRules

On-Call Paging API

type OnCallPagingApi struct {
    // contains filtered or unexported fields
}

func NewOnCallPagingApi(client *datadog.APIClient) *OnCallPagingApi

Methods: AcknowledgeOnCallPage, CreateOnCallPage, EscalateOnCallPage, ResolveOnCallPage

Observability Pipelines API

type ObservabilityPipelinesApi struct {
    // contains filtered or unexported fields
}

func NewObservabilityPipelinesApi(client *datadog.APIClient) *ObservabilityPipelinesApi

Methods: CreatePipeline, DeletePipeline, GetPipeline, ListPipelines, UpdatePipeline, ValidatePipeline

Reference Tables API

type ReferenceTablesApi struct {
    // contains filtered or unexported fields
}

func NewReferenceTablesApi(client *datadog.APIClient) *ReferenceTablesApi

Methods: CreateReferenceTable, CreateReferenceTableUpload, DeleteRows, DeleteTable, GetRowsByID, GetTable, ListTables, UpdateReferenceTable, UpsertRows

Events API

type EventsApi struct {
    // contains filtered or unexported fields
}

func NewEventsApi(client *datadog.APIClient) *EventsApi

Methods: CreateEvent, GetEvent, ListEvents, SearchEvents

Audit API

type AuditApi struct {
    // contains filtered or unexported fields
}

func NewAuditApi(client *datadog.APIClient) *AuditApi

Methods: ListAuditLogs, SearchAuditLogs

Error Tracking API

type ErrorTrackingApi struct {
    // contains filtered or unexported fields
}

func NewErrorTrackingApi(client *datadog.APIClient) *ErrorTrackingApi

Methods: DeleteIssueAssignee, GetIssue, SearchIssues, UpdateIssueAssignee, UpdateIssueState

Datasets API

type DatasetsApi struct {
    // contains filtered or unexported fields
}

func NewDatasetsApi(client *datadog.APIClient) *DatasetsApi

Methods: CreateDataset, DeleteDataset, GetAllDatasets, GetDataset, UpdateDataset

Deployment Gates API

type DeploymentGatesApi struct {
    // contains filtered or unexported fields
}

func NewDeploymentGatesApi(client *datadog.APIClient) *DeploymentGatesApi

Methods: CreateDeploymentGate, CreateDeploymentRule, DeleteDeploymentGate, DeleteDeploymentRule, GetDeploymentGate, GetDeploymentGateRules, GetDeploymentRule, UpdateDeploymentGate, UpdateDeploymentRule

API Management API

type APIManagementApi struct {
    // contains filtered or unexported fields
}

func NewAPIManagementApi(client *datadog.APIClient) *APIManagementApi

Methods: CreateOpenAPI, DeleteOpenAPI, GetOpenAPI, ListAPIs, UpdateOpenAPI

App Builder API

type AppBuilderApi struct {
    // contains filtered or unexported fields
}

func NewAppBuilderApi(client *datadog.APIClient) *AppBuilderApi

Methods: CreateApp, DeleteApp, DeleteApps, GetApp, ListApps, PublishApp, UnpublishApp, UpdateApp

Static Analysis API

type StaticAnalysisApi struct {
    // contains filtered or unexported fields
}

func NewStaticAnalysisApi(client *datadog.APIClient) *StaticAnalysisApi

Methods: CreateSCAResolveVulnerableSymbols, CreateSCAResult

Product Analytics API

type ProductAnalyticsApi struct {
    // contains filtered or unexported fields
}

func NewProductAnalyticsApi(client *datadog.APIClient) *ProductAnalyticsApi

Methods: SubmitProductAnalyticsEvent

Data Deletion API

type DataDeletionApi struct {
    // contains filtered or unexported fields
}

func NewDataDeletionApi(client *datadog.APIClient) *DataDeletionApi

Methods: CancelDataDeletionRequest, CreateDataDeletionRequest, GetDataDeletionRequests

IP Allowlist API

type IPAllowlistApi struct {
    // contains filtered or unexported fields
}

func NewIPAllowlistApi(client *datadog.APIClient) *IPAllowlistApi

Methods: GetIPAllowlist, UpdateIPAllowlist

Domain Allowlist API

type DomainAllowlistApi struct {
    // contains filtered or unexported fields
}

func NewDomainAllowlistApi(client *datadog.APIClient) *DomainAllowlistApi

Methods: GetDomainAllowlist, PatchDomainAllowlist

Organizations API

type OrganizationsApi struct {
    // contains filtered or unexported fields
}

func NewOrganizationsApi(client *datadog.APIClient) *OrganizationsApi

Methods: GetOrgConfig, ListOrgConfigs, UpdateOrgConfig, UploadIdPMetadata

Service Accounts API

type ServiceAccountsApi struct {
    // contains filtered or unexported fields
}

func NewServiceAccountsApi(client *datadog.APIClient) *ServiceAccountsApi

Methods: CreateServiceAccount, CreateServiceAccountApplicationKey, DeleteServiceAccountApplicationKey, GetServiceAccountApplicationKey, ListServiceAccountApplicationKeys, UpdateServiceAccountApplicationKey

Key Management API

type KeyManagementApi struct {
    // contains filtered or unexported fields
}

func NewKeyManagementApi(client *datadog.APIClient) *KeyManagementApi

Methods: CreateAPIKey, CreateCurrentUserApplicationKey, DeleteAPIKey, DeleteApplicationKey, DeleteCurrentUserApplicationKey, GetAPIKey, GetApplicationKey, GetCurrentUserApplicationKey, ListAPIKeys, ListApplicationKeys, ListCurrentUserApplicationKeys, UpdateAPIKey, UpdateApplicationKey, UpdateCurrentUserApplicationKey

Install with Tessl CLI

npx tessl i tessl/golang-github-com-data-dog--datadog-api-client-go-v2

docs

common-package.md

index.md

tile.json