Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extend market data with preset by activitiesCount and date #3006

Open
2 tasks
dtslvr opened this issue Feb 15, 2024 · 6 comments · May be fixed by #3022 or #3460
Open
2 tasks

Extend market data with preset by activitiesCount and date #3006

dtslvr opened this issue Feb 15, 2024 · 6 comments · May be fixed by #3022 or #3460
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@dtslvr
Copy link
Member

dtslvr commented Feb 15, 2024

Add missing attributes activitiesCount and date (First Activitiy) to market data endpoint for presetId = CURRENCIES (api/v1/admin/market-data?presetId=CURRENCIES).

Steps to reproduce

  1. Go to Admin Control
  2. Click on Market Data
  3. Select preset Currencies in Filter by...
market-data-with-currencies-preset

Todo

  • Set activitiesCount and date as required in AdminMarketDataItem interface (see here)
  • Add activitiesCount and date to getMarketDataForCurrencies() (see here)
@dtslvr dtslvr added enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed labels Feb 15, 2024
@bikash-789
Copy link

@dtslvr Can I work on this?

@SirZemar
Copy link
Contributor

SirZemar commented Jun 1, 2024

Hey @dtslvr. If nobody is working on this and still open, I can have a go.

@SirZemar
Copy link
Contributor

SirZemar commented Jun 5, 2024

@dtslvr As you suggested in #3022 (comment), I would like to import this data, but couldn't figure out how. Any guidance you can give on this?

Also, can you clarify what activities are we looking for to display in each currency pair?

@dtslvr
Copy link
Member Author

dtslvr commented Jun 5, 2024

You could import this json file via Portfolio > Activities > Import Activities. As all activities are in USD, it won't have a big impact. Maybe better use this one 😃 With it, you should see a USDCHF entry in the table.

  • First Activity for USDCHF should be the date of the earliest Order where currency is CHF
  • Activities Count for USDCHF should be the number of Order where currency is CHF

@SirZemar
Copy link
Contributor

SirZemar commented Jun 5, 2024

Sounds good. However, I couldn't import the data yet 😅. It is the last step so I can test it. Can you help with this?
FireShot Capture 001 - Activities – Ghostfolio - localhost

@dtslvr
Copy link
Member Author

dtslvr commented Jun 6, 2024

However, I couldn't import the data yet 😅

Do you see this in your log when you start the server?

Fetching crumb and cookies from https://finance.yahoo.com/quote/AAPL...
...
fetch https://query1.finance.yahoo.com/v1/test/getcrumb
New crumb: t***N.t***G

If not, you probably need to reinstall the dependencies via yarn install, especially check for "yahoo-finance2": "2.11.3" (see #3441).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
3 participants