Skip to content

Add hosts endpoint.#884

Merged
amaskara-dd merged 21 commits intomasterfrom
dongothing-dd/add-hosts
Jan 24, 2025
Merged

Add hosts endpoint.#884
amaskara-dd merged 21 commits intomasterfrom
dongothing-dd/add-hosts

Conversation

@dongothing-dd
Copy link
Copy Markdown
Contributor

Requirements for Contributing to this repository
Fill out the template below. Any pull request that does not include enough information to be reviewed in a timely manner may be closed at the maintainers' discretion.
The pull request must only fix one issue, or add one feature, at the time.
The pull request must update the test suite to demonstrate the changed functionality.
After you create the pull request, all status checks must be pass before a maintainer reviews your contribution. For more details, please see CONTRIBUTING.
What does this PR do?
Add hosts endpoint. See ##876.

Description of the Change
Added the hosts endpoint so I can get a host list without having to remember anything. The last commit was to fix cassettes that were generated with an incorrect app key.

Alternate Designs
I considered adding to the "host" mode instead of creating a new "hosts" mode. Our endpoint is "hosts" so I used that naming convention.

Possible Drawbacks
N/A?

Verification Process
I tested in an Ubuntu VM with keys to the expert-services sandbox.

I ran flake8 tests via python -m tox -c tox.ini -e flake8
I ran and passed integration tests via python -m tox -c tox.ini -- -k hosts

Builds failed, but I assume that has to do with my environment rather than the change.

Additional Notes
I created a PR yesterday without the cassettes because it tested fine in my VM. The automated test failed here, so I added the cassettes today.

Release Notes
Added the hosts endpoints for the Datadog API. dog hosts list returns a list of all hosts. dog hosts totals returns counts of active hosts. Datadog documentation.

Review checklist (to be filled by reviewers)

  • Feature or bug fix MUST have appropriate tests (unit, integration, etc...)
  • PR title must be written as a CHANGELOG entry (see why)
  • Files changes must correspond to the primary purpose of the PR as described in the title (small unrelated changes should have their own PR)
  • PR must have one changelog/ label attached. If applicable it should have the backward-incompatible label attached.
  • PR should not have do-not-merge/ label attached.
  • If Applicable, issue must have kind/ and severity/ labels attached at least.

@dongothing-dd dongothing-dd requested a review from a team as a code owner January 14, 2025 21:01
@dongothing-dd dongothing-dd added changelog/Added Added features results into a minor version bump kind/feature-request Feature request related issue labels Jan 14, 2025
@amaskara-dd amaskara-dd merged commit 4ab584c into master Jan 24, 2025
@amaskara-dd amaskara-dd deleted the dongothing-dd/add-hosts branch January 24, 2025 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/Added Added features results into a minor version bump kind/feature-request Feature request related issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants