Skip to content

Feat: add GET /auth/pools endpoint#7

Open
mukama wants to merge 3 commits intotetherto:developfrom
mukama:feat/pools
Open

Feat: add GET /auth/pools endpoint#7
mukama wants to merge 3 commits intotetherto:developfrom
mukama:feat/pools

Conversation

@mukama
Copy link
Contributor

@mukama mukama commented Feb 12, 2026

Summary

  • Add GET /auth/pools endpoint returning merged pool data (device list + stats)
  • Support filter, sort, fields params (JSON-encoded, using mingo query engine)
  • Returns pools array with summary (poolCount, totalHashrate, totalWorkers, totalBalance)

Example Queries

All pools (no filters):

/auth/pools

Filter by status:

/auth/pools?filter=%7B%22status%22%3A%22active%22%7D

(decoded: {"status":"active"})

Sort by hashrate descending:

/auth/pools?sort=%7B%22hashrate%22%3A-1%7D

(decoded: {"hashrate":-1})

Select specific fields only:

/auth/pools?fields=%7B%22name%22%3A1%2C%22hashrate%22%3A1%2C%22balance%22%3A1%7D

(decoded: {"name":1,"hashrate":1,"balance":1})

Combined — active pools sorted by hashrate, selected fields:

/auth/pools?filter=%7B%22status%22%3A%22active%22%7D&sort=%7B%22hashrate%22%3A-1%7D&fields=%7B%22name%22%3A1%2C%22hashrate%22%3A1%7D

Add pools API endpoint that aggregates pool device lists and stats
from ORK clusters, supports mingo-based filtering, sorting, and
field selection, and returns pool summary with totals.
list-things for t-minerpool returns empty; pool data lives in ext-data
stats responses. Replaced flattenResults/flattenStatsResults/mergePoolData
with flattenPoolStats that parses the actual stats array format.
@mukama mukama changed the base branch from main to develop February 13, 2026 10:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant