惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

G
GRAHAM CLULEY
T
Tenable Blog
Know Your Adversary
Know Your Adversary
C
CXSECURITY Database RSS Feed - CXSecurity.com
P
Privacy International News Feed
S
Security Affairs
NISL@THU
NISL@THU
O
OpenAI News
Attack and Defense Labs
Attack and Defense Labs
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Hacker News: Ask HN
Hacker News: Ask HN
Webroot Blog
Webroot Blog
Schneier on Security
Schneier on Security
S
SegmentFault 最新的问题
S
Schneier on Security
G
Google Developers Blog
V
V2EX
C
Check Point Blog
U
Unit 42
Google DeepMind News
Google DeepMind News
T
Threatpost
阮一峰的网络日志
阮一峰的网络日志
T
The Exploit Database - CXSecurity.com
Recent Announcements
Recent Announcements
M
MIT News - Artificial intelligence
S
Secure Thoughts
博客园 - 司徒正美
Recorded Future
Recorded Future
P
Proofpoint News Feed
Spread Privacy
Spread Privacy
K
Kaspersky official blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
AI
AI
博客园 - 聂微东
N
News and Events Feed by Topic
SecWiki News
SecWiki News
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
V
Vulnerabilities – Threatpost
P
Palo Alto Networks Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Engineering at Meta
Engineering at Meta
Recent Commits to openclaw:main
Recent Commits to openclaw:main
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
酷 壳 – CoolShell
酷 壳 – CoolShell
WordPress大学
WordPress大学
The Hacker News
The Hacker News
The Last Watchdog
The Last Watchdog
Project Zero
Project Zero
W
WeLiveSecurity
博客园 - Franky

Datadog | The Monitor blog

Introducing our open source AI-native SAST Instrument and monitor Boomi integration flows with OpenTelemetry and Datadog Not all index scans are equal: How we cut query latency by over 99% Platform engineering metrics: What to measure and what to ignore Integrate Recorded Future threat intelligence with Datadog Cloud SIEM CI/CD security: threat modeling using a MITRE-style threat matrix CI/CD security: How to secure your GitHub ecosystem Ingress NGINX is EOL: A practical guide for migrating to Kubernetes Gateway API Operating agentic AI with Amazon Bedrock AgentCore and Datadog LLM Observability: Lessons from NTT DATA Introducing the Datadog Code Security MCP Capture and analyze custom heatmaps in Session Replay Understand session replays faster with AI summaries and smart chapters Monitor ClickHouse query performance with Datadog Database Monitoring How we designed empathetic alert sounds for on-call engineers Search and act across Datadog to resolve issues faster with Bits Assistant Measure the business impact of every product change with Datadog Experiments Analyzing round trip query latency Configuring JavaScript caches for better performance Introducing Bits AI Dev Agent for Code Security Datadog achieves ISO 42001 certification for responsible AI Monitor Nutanix clusters, hosts, and VMs with Datadog Monitor Juniper Mist in Datadog A new Host Map for modern infrastructure Annotate traces to improve LLM quality with Datadog LLM Observability What’s new in Cloud SIEM: AI-powered investigations, enhanced threat intelligence, and scalable security operations Explore Kubernetes with native OpenTelemetry data Monitor Oracle Fusion Cloud Applications with Datadog Announcing the Datadog Terraform provider v4.0.0 Scaling Kubernetes workloads on custom metrics How to design cloud environments for AI-powered threat analysis Monitor Aruba Central in Datadog How we centralize and remediate risks with Datadog Case Management Accelerate incident response with Datadog and ServiceNow Monitor your application and network load balancer logs Understanding Karpenter architecture for Kubernetes autoscaling Tools for collecting metrics and logs from Karpenter Monitor Karpenter with Datadog What your product data is actually saying Key metrics for monitoring Karpenter Securing Datadog’s platform in the AI age: The role of observability data Four ways engineering teams use the Datadog MCP Server to power AI agents Approaching your observability migration with the right mindset Meet the new Bits AI SRE: Deeper reasoning, twice as fast Key learnings from the 2026 State of DevSecOps study Use plain English to query your multi-cloud infrastructure in Resource Catalog Simplifying troubleshooting across the user journey with Datadog Synthetic Monitoring Protect your OCI resources with Datadog Cloud Security This Month in Datadog - February 2026 Amazon EC2 security: How misconfigured and public AMIs expand your cloud attack surface Enable end-to-end visibility into your Java apps with a single command Measure and improve mobile app startup performance with Datadog RUM Evaluating our AI Guard application to improve quality and control cost Identify untested code across every level of your codebase Make use of guardrail metrics and stop babysitting your releases Monitor Versa Networks SD-WAN performance in Datadog Improve performance and reliability with APM Recommendations Remediate transitive vulnerabilities faster with Datadog Software Composition Analysis Generate audit-ready vulnerability and compliance reports with Datadog Sheets Monitor Fortinet FortiManager performance in Datadog Improve test coverage across codebases with Datadog Code Coverage Move fast, don’t break things: Consistent testing standards at scale Enrich logs with ServiceNow CMDB context before routing to any SIEM or logging tool Monitor Lustre with Datadog Make faster, better product decisions with Datadog Product Analytics Surface and remediate runtime posture issues with Workload Protection Findings Protect agentic AI applications with Datadog AI Guard How to optimize JavaScript code with CSS Trace Google Pub/Sub workloads in Cloud Run with Datadog Detect human names in logs with ML in Sensitive Data Scanner How we cut our NLQ agent debugging time from hours to minutes with LLM Observability Debug PostgreSQL query latency faster with EXPLAIN ANALYZE in Datadog Database Monitoring Datadog acquires Propolis Unify and correlate frontend and backend data with retention filters Scale compliance across global frameworks with Datadog Cloud Security Monitor Arista VeloCloud SD-WAN performance with Datadog Building reliable dashboard agents with Datadog LLM Observability Simplify log collection and aggregation for MSSPs with Datadog Observability Pipelines Mitigation for Node.js denial-of-service vulnerability affecting Datadog APM Automate flaky test fixes with the Bits AI Dev Agent and Test Optimization How we built an AI SRE agent that investigates like a team of engineers Datadog integrations 2025 recap: Observability for AI, security, and hybrid cloud Design effective executive dashboards with Datadog Implement dbt data quality checks with dbt-expectations Bring faster visibility into AWS Lambda functions with remote instrumentation Troubleshoot faster with the GitLab Source Code integration in Datadog How Cambia Health Solutions saved $30,000 monthly with Cloud Cost Management and the Datadog Resource Catalog Normalize any logs for Cloud SIEM with Datadog's OCSF processor Optimizing Datadog at scale: Cost-efficient observability at Zendesk Detect, diagnose, and resolve network issues easily with CNM Network Health Connect engineering errors to user impact in early-stage products Cilium configuration for Kubernetes operations at scale Designing feedback loops for progressive delivery Ship features faster and safer with Datadog Feature Flags Choosing the right OpenTelemetry Collector distribution Route your monitor alerts with Datadog monitor notification rules Automate Cloud SIEM investigations with Bits AI Security Analyst Cloud threat detection: How to identify risky activity across control and data planes Collecting Kafka performance metrics Monitoring Kafka with Datadog Monitoring Kafka performance metrics
New in Datadog: Managing integrations via API calls
2018-03-29 · via Datadog | The Monitor blog
David Lentz

David Lentz

We’re pleased to introduce a brand-new way to set up your Datadog integrations. You can now configure integrations programmatically using our API, making your monitoring practices as scalable and repeatable as possible. APIs are now available for our AWS, Slack, PagerDuty, and webhooks integrations, with more coming soon.

This API-driven approach to configuring integrations can provide efficiency and consistency to organizations with complex, multifaceted environments. In this post, we’ll walk through how the Datadog integration API works by presenting an example API call for each of the supported integrations, and finally tying them all together in a Datadog alert.

Integrating AWS with Datadog automatically

It’s common for an organization to provision multiple AWS accounts, for example spinning up a new account at the start of a new project or for a new team to use. To do this efficiently and to ensure consistency, you can use a script to first create a new AWS account, and then to automatically integrate it with Datadog. The following code calls the AWS Organizations API to create an AWS account for a new team, and saves its ID in AWS_ACCOUNT_ID:

# Create an AWS account.

# The account must use an email address not associated with any other AWS account.

ACCOUNT_EMAIL='new-team@company.com'

ACCOUNT_NAME='new-team'

AWS_RESULT=$(aws organizations create-account --email ${ACCOUNT_EMAIL} --account-name "${ACCOUNT_NAME}")

# Get the request ID from the create-account operation.

AWS_REQUEST_ID=`echo $AWS_RESULT | python -mjson.tool | grep '^\(.*\)Id\(.*\)$' | sed 's/^\(.*\)": "\(.*\)",$/\2/'`

# Check the status of the AWS account creation call.

# If it's not 'SUCCEEDED' or 'FAILED', wait 3 seconds and check again.

STATE='undefined'

while [[ "$STATE" != "SUCCEEDED" && "$STATE" != "FAILED" ]];

do

AWS_STATUS_RESULT=$(aws organizations describe-create-account-status --create-account-request-id $AWS_REQUEST_ID)

STATE=`echo $AWS_STATUS_RESULT | python -mjson.tool | grep '^\(.*\)State\(.*\)$' | sed 's/^\(.*\)": "\(.*\)"\(.*\)$/\2/'`

echo "AWS account creation status = ${STATE}"

sleep 3

done;

if [[ "$STATE" == "FAILED" ]]; then

REASON=`echo $AWS_STATUS_RESULT | python -mjson.tool | grep '^\(.*\)FailureReason\(.*\)$' | sed 's/^\(.*\)": "\(.*\)"\(.*\)$/\2/'`

echo "Account creation failed. Reason: ${REASON}"

else

# Get the ID of the new account.

AWS_ACCOUNT_ID=`echo $AWS_STATUS_RESULT | python -mjson.tool | grep '^\(.*\)AccountId\(.*\)$' | sed 's/^\(.*\)": "\(.*\)"\(.*\)$/\2/'`

echo "AWS_ACCOUNT_ID = ${AWS_ACCOUNT_ID}"

fi

Next, you can call Datadog’s integration API to install the AWS integration. You can pass parameters that filter which AWS metrics the integration will collect. The filter_tags parameter limits which EC2 resources you collect metrics from. In this case, the integration will only collect metrics for EC2 instances tagged with env:staging. Additionally, you can use the account_specific_namespace_rules payload object to restrict metric collection for certain AWS services. Here the integration will not collect metrics for Auto Scaling or Lambda. See Amazon CloudWatch documentation for more information about AWS Namespaces.

The API call below installs the Datadog AWS integration:

# Replace the keys below with your own.

api_key=YOUR_DATADOG_API_KEY

app_key=YOUR_DATADOG_APP_KEY

# Create the Datadog/AWS integration and store the result.

RESULT=$(curl -X POST -H "Content-type: application/json" \

-d '{

"account_id": "${AWS_ACCOUNT_ID}",

"filter_tags": ["env:staging"],

"host_tags": ["account:new-team"],

"role_name": "DatadogAWSIntegrationRole",

"account_specific_namespace_rules": {

"auto_scaling": false,

"lambda": false

}

}' \

"https://app.datadoghq.com/api/v1/integration/aws?api_key=${api_key}&application_key=${app_key}")

The AWS integration is now installed, but the role named in the call above, DatadogAWSIntegrationRole, doesn’t yet exist in AWS. The following code creates the role and names the External ID in its trust policy. (For more information about the External ID, refer to this document in the IAM User Guide.)

# Parse RESULT (from the previous call) for EXTERNAL_ID.

EXTERNAL_ID=`echo $RESULT | python -mjson.tool | grep '^\(.*\)external_id\(.*\)$' | sed 's/^\(.*\): "\(.*\)"$/\2/'`

# Write the role's trust policy to a file.

cat > trust-policy.json <<- EOM

{

"Version": "2012-10-17",

"Statement": {

"Effect": "Allow",

"Action": "sts:AssumeRole",

"Principal": {"AWS": "arn:aws:iam::464622532012:root"},

"Condition": {"StringEquals": {"sts:ExternalId": "${EXTERNAL_ID}"}}

}

}

EOM

aws iam create-role --role-name DatadogAWSIntegrationRole --assume-role-policy-document file://trust-policy.json

Finally, you need to create a permissions policy and attach it to the role. You can do this by copying the list found here to a file, and saving it as permissions-policy.json. The sample code below uses that file in a call to the AWS API to associate the policy with the new role:

aws iam put-role-policy --role-name DatadogAWSIntegrationRole --policy-name DatadogAWSIntegrationPolicy --policy-document file://permissions-policy.json

The new role is now connected to Datadog, and the integration is now collecting metrics from all AWS resources supported by CloudWatch.

Integrating with Slack

You can now create a setup script that will call the Slack API to create a team-specific channel. It can then send a corresponding call, like the one below, to the Datadog integration API. This call includes the Slack channel name and Webhook URL, connecting Slack to Datadog. You can then trigger this integration by mentioning @slack-new-team in the event stream, in graph annotations, or in the body of a Datadog alert.

curl -v -X POST -H "Content-type: application/json" \

-d '{

"service_hooks": [

{

"account": "Company_Account",

"url": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX"

}

],

"channels": [

{

"channel_name": "#new-team",

"transfer_all_user_comments": "false",

"account": "Company_Account"

}

]

}' \

"https://app.datadoghq.com/api/v1/integration/slack?api_key=${api_key}&application_key=${app_key}&run_check=true"

For more information about Datadog’s Slack integration, see the Datadog API documentation.

To integrate with PagerDuty, script a call to the PagerDuty API to create and configure a new service there. (See the [PagerDuty API reference documentation] (https://v2.developer.pagerduty.com/page/api-reference#!/API_Reference/get_api_reference).) You can then integrate PagerDuty into Datadog via an API call like the one shown below. Once integrated, PagerDuty creates an incident for any Datadog alert that mentions @pagerduty in the message body. If you have more than one PagerDuty service integrated with Datadog, you can use service-specific mentions to route your notifications appropriately.

curl -v -X PUT -H "Content-type: application/json" \

-d '{

"services": [

{

"service_name": "datadog_pagerduty_service",

"service_key": "KEY"

}

],

"subdomain": "my-pd",

"schedules": ["https://my-pd.pagerduty.com/schedules#ABCDE6F", "https://my-pd.pagerduty.com/schedules#FEDCB6A"],

"api_token": "TOKEN"

}' \

"https://app.datadoghq.com/api/v1/integration/pagerduty?api_key=${api_key}&application_key=${app_key}&run_check=true"

For more information about Datadog’s PagerDuty integration, see the Datadog API documentation.

Integrating with custom webhooks

You can use the webhooks integration to trigger any custom webhooks you’ve created. The example code here installs an integration for a webhook that controls a flashing light on an IOT device. You can mention @webhook-iot-flasher in a Datadog alert to trigger the flashing light.

curl -v -X POST -H "Content-type: application/json" \

-d '{

"hooks": [

{

"name": "iot-flasher",

"url": "http://example.com/v1srg7v1",

"use_custom_payload": "false",

"custom_payload": "",

"encode_as_form": "false",

"headers": ""

}

]

}' \

"https://app.datadoghq.com/api/v1/integration/webhooks?api_key=${api_key}&application_key=${app_key}&run_check=true"

See the Datadog API documentation for more information about Datadog’s webhooks integration.

Configuring Datadog alerts

At this point, we have used Datadog’s integration API to configure integrations with AWS, Slack, PagerDuty, and a custom webhook. Metrics are flowing into prebuilt Datadog dashboards for all AWS resources supported by CloudWatch. Slack, PagerDuty, and the custom webhook are all listening for mentions within Datadog alerts to trigger activity on their respective channels. You can also programmatically create alerts that feed messages to the newly configured integrations, as shown below. In this example, we are creating an alert that notifies the appropriate teams when no EC2 hosts with the role of worker are reporting as OK. Note the @ notifications in the message body, which trigger the Slack, PagerDuty, and webhook integrations created in the steps above:

curl -X POST -H "Content-type: application/json" \

-d '{

"type": "metric alert",

"query": "avg(last_15m):avg:aws.ec2.host_ok{role:worker} < 1",

"name": "No active workers",

"message": "@slack-new-team @pagerduty @webhook-iot-flasher: There are no EC2 workers in an 'OK' state.",

"tags": ["app:webserver", "frontend"],

"options": {

"notify_no_data": true,

"no_data_timeframe": 20

}

}' \

"https://app.datadoghq.com/api/v1/monitor?api_key=${api_key}&application_key=${app_key}"

See our API documentation for more information on the alerts API.

Get started today

With programmatic access to these integrations, you can automate the configuration of your monitoring and alerting coverage as your infrastructure scales or evolves. We will continue to add API access for integrations, so stay tuned for more information. If you’re already using Datadog, you can start managing your integrations via API today. If not, sign up for a free trial here.