frontend-monorepo icon indicating copy to clipboard operation
frontend-monorepo copied to clipboard

Account history

Open gordsport opened this issue 2 years ago • 2 comments

Depends on https://github.com/vegaprotocol/pennant/issues/625

Story

As a user I want to be able to inspect my account history So that I can understand the value of my portfolio over time

This would use the balanceChanges api, no subscription required

Acceptance Criteria

  • [ ] I can see my account balance for an asset over time on a chart
  • [ ] I can select a different asset
  • [ ] I can multi select different account types
  • [ ] Default account type is General
  • [ ] Default asset is whatever is first when listed alphabetically
  • [ ] I can select different time ranges
    • 1D, 7D, 1M, 3M, 1Y, YTD, ALL

Sketch

Screenshot 2022-11-30 at 16 28 52

Tasks

  • [ ] Add a sketch of what we talked about to help illustrate what needs to be done
  • [ ] Link to coin market cap example for reference

gordsport avatar May 25 '22 11:05 gordsport

So I've been looking into this today, there isn't really a specific API for historical positions. The positionsConnection query is historical in the sense that it will show all positions regardless of state. However what we can do is show account history over time via the balanceChanges query and allow for filtering by asset, account type, date and market

I've updated this ticket accordingly and deleted comments for clarity

mattrussell36 avatar Nov 24 '22 07:11 mattrussell36

Opportunity for later... could link this up with ledger entries to be able to identify where spikes and dips are just due to you depositing/ withdrawing etc.

AND select multiple accounts to show

pennyandrews avatar Dec 02 '22 16:12 pennyandrews