Skip to content

Add total_value to collection responses - #25

Merged
amrtgaber merged 1 commit into
mainfrom
feat/collection-total-value
Feb 7, 2026
Merged

Add total_value to collection responses#25
amrtgaber merged 1 commit into
mainfrom
feat/collection-total-value

Conversation

@amrtgaber

Copy link
Copy Markdown
Contributor

Summary

  • Add total_value (sum of item estimated_value) to CollectionReadWithCount schema
  • Compute it in both list_collections and get_collection endpoints
  • Return null when no items have values (distinguishes "no valued items" from "$0")

Test plan

  • New tests: total_value sums correctly, returns null for no-value items, returns null for empty collections
  • All 122 existing tests still pass

Sum estimated_value across items in each collection and return it in
list/detail endpoints. Returns null when no items have a value set.
@amrtgaber
amrtgaber merged commit 3353f0a into main Feb 7, 2026
2 checks passed
@amrtgaber
amrtgaber deleted the feat/collection-total-value branch February 7, 2026 00:46
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