[PR #4010] Add --filter-by-connection-type flag to status command #22246

Open
opened 2026-08-05 06:05:43 -04:00 by saavagebueno · 0 comments
Owner

Original Pull Request: https://github.com/netbirdio/netbird/pull/4010

State: closed
Merged: Yes


Describe your changes

This PR introduces a new flag --filter-by-connection-type to the status command.
It allows users to filter peers by connection type (P2P or Relayed) in both JSON and detailed views.

Input validation is added in parseFilters() to ensure proper usage, and --detail is auto-enabled if no output format is specified (consistent with other filters).

Resolves #3883

Stack

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)
  • Extended the README / documentation, if necessary

By submitting this pull request, you confirm that you have read and agree to the terms of the Contributor License Agreement.

**Original Pull Request:** https://github.com/netbirdio/netbird/pull/4010 **State:** closed **Merged:** Yes --- ## Describe your changes This PR introduces a new flag `--filter-by-connection-type` to the status command. It allows users to filter peers by connection type (`P2P` or `Relayed`) in both JSON and detailed views. Input validation is added in `parseFilters()` to ensure proper usage, and `--detail` is auto-enabled if no output format is specified (consistent with other filters). ## Issue ticket number and link Resolves #3883 ## Stack <!-- branch-stack --> ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [x] Is a feature enhancement - [ ] It is a refactor - [ ] Created tests that fail without the change (if possible) - [ ] Extended the README / documentation, if necessary > By submitting this pull request, you confirm that you have read and agree to the terms of the [Contributor License Agreement](https://github.com/netbirdio/netbird/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT.md).
saavagebueno added the pull-request label 2026-08-05 06:05:43 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#22246