Datadog

Datadog Expertise

RapDev is a Datadog Premier Partner focused on accelerating our customers’ time to value.
600
Implementations
110
US-Based Engineers
68
Datadog Certifications

Security & Managed SOC

Quickly and seamlessly implement Cloud SIEM, ASM, SCA, and Cloud Security Posture Management to power a modern DevSecOps strategy

Incident Management

Transform data into high-confidence, actionable incidents using AI-driven detection, clear ownership models, and automated remediation

Marketplace Integrations

RapDev is proud to offer more Datadog Marketplace integrations than any other partner

ServiceNow

ServiceNow Expertise

RapDev is a ServiceNow Elite partner focused on helping you drive business outcomes with the ITx suite.
4.7
CSAT Score
136
Product Line Certs.
67k
AI Agents Discovered

Agentic AI & AI Governance

Deploy and scale production-ready agentic AI to automate workflows and accelerate ServiceNow outcomes

Enterprise Architecture

Connect your technology landscape to business strategy to optimize investments, reduce risk, and accelerate modernization

ServiceNow Store

Leverage RapDev’s certified apps and AI Agents to expedite operations on the Now Platform
Blog
Company

About RapDev

RapDev is powered by a team of experienced, U.S. based engineers focused on redefining service operations through AI, automation, and modern observability.

Join the RapDev team

Our no-frills approach to collaborating is what allows us to deliver the best. Our team is growing and we’re looking for the best in the game.

Press

Latest news and announcements from RapDev

Events & Webinars

From hands-on workshops to industry-leading conferences

Resources

Back to blog

RapDev's Open Source Host List Generator

Get visibility into your Datadog hosts with this open-source tool.

X

min read

June 30, 2022

Paul Kim

One of the core philosophies at RapDev is "fuck it, ship it". 

It's a concept that encompasses years of experience and culture and software development observations. It's a (casual) creed that inevitably leads to improvement and actionable iteration. As engineers rapidly build products and tools for daily deliverables, some utilities find more common uses and practicalities between projects. One of those tools that were developed was the RapDev Datadog Host List Generator

Datadog is commonly used to find and gain visibility into hundreds or thousands of machines to monitor their performance and obtain useful metrics from them. Although the platform makes most information available from the browser, some items are just easier to read straight from their extensive API. This is why RapDev engineers designed an extensive open-source utilities library to help Datadog users adapt the platform to their organization's needs. 

Datadog's API allows any user to find and get information from their Datadog instance by simply authenticating and then hitting one of their many endpoints. From managing the entire account to taking a snapshot of a time series graph, Datadog allows their users to programmatically use their platform. A common use of the Hosts API is to get an inventory of all hosts live on your Datadog instance. The team at RapDev have, at many different points, built a utility to get all hosts and generate a report by querying the API and filtering by different specifications. After writing this script enough times, it made sense to open source this utility and allow others to use and modify this utility and iterate upon it for their own use cases. You can find it here, at RapDev's Datadog Open Source Repository

To use this Python script, you can simply run the script with a search term(or terms) to pull every active host. 

For example to get all hosts:  

`python3 list_datadog_hosts.py`

Or for something more interesting, to get all hosts without agents:  

`python3 list_datadog_hosts.py field:metadata_agent_version:noagent`

Or, for something even more interesting, to get all hosts without agents on AWS:  

`python3 list_datadog_hosts.py field:metadata_agent_version:noagent,field:apps:aws`

The command will generate a file called `host_list<CURRENTTIME>.csv` the host name, all the tags, and other useful host metadata.

As you can see, this utility can be very powerful and can be used as an extension to the already powerful Datadog platform. For assistance, questions, feature requests, or anywhere in between, please reach out to integrations@rapdev.io and look forward to more being added to our open source repository!