Skip to content

Commit fc83f76

Browse files
Add currency_symbol, base_currency_name, and base_currency_symbol attributes to TickerDetails class. (#241)
* add currency_symbol, base_currency_name, and base_currency_symbol attributes to TickerDetails class. useful for forex and crypto tickers * also in the from_dict method
1 parent a160d89 commit fc83f76

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

polygon/rest/models/tickers.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
from typing import Optional, List
2+
23
from ...modelclass import modelclass
34

45

@@ -78,6 +79,9 @@ class TickerDetails:
7879
cik: Optional[str] = None
7980
composite_figi: Optional[str] = None
8081
currency_name: Optional[str] = None
82+
currency_symbol: Optional[str] = None
83+
base_currency_name: Optional[str] = None
84+
base_currency_symbol: Optional[str] = None
8185
delisted_utc: Optional[str] = None
8286
description: Optional[str] = None
8387
ticker_root: Optional[str] = None
@@ -109,6 +113,9 @@ def from_dict(d):
109113
cik=d.get("cik", None),
110114
composite_figi=d.get("composite_figi", None),
111115
currency_name=d.get("currency_name", None),
116+
currency_symbol=d.get("currency_symbol", None),
117+
base_currency_name=d.get("base_currency_name", None),
118+
base_currency_symbol=d.get("base_currency_symbol", None),
112119
delisted_utc=d.get("delisted_utc", None),
113120
description=d.get("description", None),
114121
ticker_root=d.get("ticker_root", None),

0 commit comments

Comments
 (0)