GET /streams only filters by address right now. The analytics endpoint has the same problem, it always aggregates across every status and every token, and totalRatePerSecond actually sums rates across all active streams regardless of token, which mixes units together if a wallet has both XLM and USDC streams going at once. There's no way to just ask for someone's active streams, or just their USDC ones, without pulling everything back and filtering it yourself on the client.
Add status and token as query params on both the list endpoint and the analytics endpoint, and let them combine with the existing address filter. On analytics specifically, when a token is passed in, the rate total should only cover that token instead of mixing them.
Relevant file is streams.controller.ts.
Before submitting your PR, make sure all checks pass locally and the build succeeds. Each issue will be thoroughly reviewed and only merged if it fully meets the requirements. In your PR, specify the issue number and title, and include tests for each filter on its own and combined. On the issue, comment tagging the author to let them know you're working on it. On the PR, tag the maintainer to notify that review is ready.
GET /streams only filters by address right now. The analytics endpoint has the same problem, it always aggregates across every status and every token, and totalRatePerSecond actually sums rates across all active streams regardless of token, which mixes units together if a wallet has both XLM and USDC streams going at once. There's no way to just ask for someone's active streams, or just their USDC ones, without pulling everything back and filtering it yourself on the client.
Add status and token as query params on both the list endpoint and the analytics endpoint, and let them combine with the existing address filter. On analytics specifically, when a token is passed in, the rate total should only cover that token instead of mixing them.
Relevant file is streams.controller.ts.
Before submitting your PR, make sure all checks pass locally and the build succeeds. Each issue will be thoroughly reviewed and only merged if it fully meets the requirements. In your PR, specify the issue number and title, and include tests for each filter on its own and combined. On the issue, comment tagging the author to let them know you're working on it. On the PR, tag the maintainer to notify that review is ready.