diff --git a/website/content/excel/functions.json b/website/content/excel/functions.json index be335898a82..54a2329f3b1 100644 --- a/website/content/excel/functions.json +++ b/website/content/excel/functions.json @@ -11,12 +11,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, polygon, tiingo, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -29,6 +23,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fmp, polygon, tiingo, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Number of days to look back. (provider: fmp)", "name": "timeseries", @@ -90,14 +90,14 @@ "name": "CRYPTO.SEARCH", "parameters": [ { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", + "description": "Search query.", + "name": "query", "optional": true, "type": "string" }, { - "description": "Search query.", - "name": "query", + "description": "Options: fmp, defaults to fmp.", + "name": "provider", "optional": true, "type": "string" } @@ -117,12 +117,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, polygon, tiingo, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -135,6 +129,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fmp, polygon, tiingo, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Data granularity. (provider: fmp, tiingo)", "name": "interval", @@ -270,14 +270,14 @@ "name": "DERIVATIVES.OPTIONS.UNUSUAL", "parameters": [ { - "description": "Options: intrinio, defaults to intrinio.", - "name": "provider", + "description": "Symbol to get data for. (the underlying symbol)", + "name": "symbol", "optional": true, "type": "string" }, { - "description": "Symbol to get data for. (the underlying symbol)", - "name": "symbol", + "description": "Options: intrinio, defaults to intrinio.", + "name": "provider", "optional": true, "type": "string" }, @@ -298,12 +298,6 @@ "id": "ECONOMY.CALENDAR", "name": "ECONOMY.CALENDAR", "parameters": [ - { - "description": "Options: fmp, tradingeconomics, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -316,6 +310,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fmp, tradingeconomics, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Country of the event (provider: tradingeconomics)", "name": "country", @@ -351,12 +351,6 @@ "name": "countries", "type": "any" }, - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The unit of measurement for the data.\nOptions:\n- `growth_previous`: Percent growth from the previous period.\nIf monthly data, this is month-over-month, etc\n- `growth_same`: Percent growth from the same period in the previous year.\nIf looking at monthly data, this would be year-over-year, etc.\n- `index_2015`: Rescaled index value, such that the value in 2015 is 100.", "name": "units", @@ -386,6 +380,12 @@ "name": "end_date", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -399,14 +399,14 @@ "name": "ECONOMY.FRED_SEARCH", "parameters": [ { - "description": "Options: fred, defaults to fred.", - "name": "provider", + "description": "The search word(s).", + "name": "query", "optional": true, "type": "string" }, { - "description": "The search word(s).", - "name": "query", + "description": "Options: fred, defaults to fred.", + "name": "provider", "optional": true, "type": "string" }, @@ -474,12 +474,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fred, intrinio, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -498,6 +492,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fred, intrinio, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Frequency aggregation to convert high frequency data to lower frequency.\nNone = No change\na = Annual\nq = Quarterly\nm = Monthly\nw = Weekly\nd = Daily\nwef = Weekly, Ending Friday\nweth = Weekly, Ending Thursday\nwew = Weekly, Ending Wednesday\nwetu = Weekly, Ending Tuesday\nwem = Weekly, Ending Monday\nwesu = Weekly, Ending Sunday\nwesa = Weekly, Ending Saturday\nbwew = Biweekly, Ending Wednesday\nbwem = Biweekly, Ending Monday\n(provider: fred)", "name": "frequency", @@ -539,12 +539,6 @@ "id": "ECONOMY.GDP.FORECAST", "name": "ECONOMY.GDP.FORECAST", "parameters": [ - { - "description": "Options: oecd, defaults to oecd.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return. Units for nominal GDP period. Either quarter or annual.", "name": "period", @@ -569,6 +563,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: oecd, defaults to oecd.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Country to get GDP for. (provider: oecd)", "name": "country", @@ -586,12 +586,6 @@ "id": "ECONOMY.GDP.NOMINAL", "name": "ECONOMY.GDP.NOMINAL", "parameters": [ - { - "description": "Options: oecd, defaults to oecd.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The unit of measurement for the data. Units to get nominal GDP in. Either usd or usd_cap indicating per capita.", "name": "units", @@ -610,6 +604,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: oecd, defaults to oecd.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Country to get GDP for. (provider: oecd)", "name": "country", @@ -627,12 +627,6 @@ "id": "ECONOMY.GDP.REAL", "name": "ECONOMY.GDP.REAL", "parameters": [ - { - "description": "Options: oecd, defaults to oecd.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The unit of measurement for the data. Either idx (indicating 2015=100), qoq (previous period) or yoy (same period, previous year).)", "name": "units", @@ -651,6 +645,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: oecd, defaults to oecd.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Country to get GDP for. (provider: oecd)", "name": "country", @@ -668,12 +668,6 @@ "id": "ECONOMY.MONEY_MEASURES", "name": "ECONOMY.MONEY_MEASURES", "parameters": [ - { - "description": "Options: federal_reserve, defaults to federal_reserve.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -691,6 +685,12 @@ "name": "adjusted", "optional": true, "type": "boolean" + }, + { + "description": "Options: federal_reserve, defaults to federal_reserve.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -720,12 +720,6 @@ "id": "EQUITY.CALENDAR.DIVIDEND", "name": "EQUITY.CALENDAR.DIVIDEND", "parameters": [ - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -737,6 +731,12 @@ "name": "end_date", "optional": true, "type": "string" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -749,12 +749,6 @@ "id": "EQUITY.CALENDAR.EARNINGS", "name": "EQUITY.CALENDAR.EARNINGS", "parameters": [ - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -766,6 +760,12 @@ "name": "end_date", "optional": true, "type": "string" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -778,12 +778,6 @@ "id": "EQUITY.CALENDAR.IPO", "name": "EQUITY.CALENDAR.IPO", "parameters": [ - { - "description": "Options: intrinio, defaults to intrinio.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Symbol to get data for.", "name": "symbol", @@ -808,6 +802,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: intrinio, defaults to intrinio.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Status of the IPO. [upcoming, priced, or withdrawn] (provider: intrinio)", "name": "status", @@ -837,12 +837,6 @@ "id": "EQUITY.CALENDAR.SPLITS", "name": "EQUITY.CALENDAR.SPLITS", "parameters": [ - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -854,6 +848,12 @@ "name": "end_date", "optional": true, "type": "string" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -888,12 +888,6 @@ "id": "EQUITY.DISCOVERY.FILINGS", "name": "EQUITY.DISCOVERY.FILINGS", "parameters": [ - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -918,6 +912,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Flag for whether or not the filing is done. (provider: fmp)", "name": "isDone", @@ -962,12 +962,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -979,6 +973,12 @@ "name": "limit", "optional": true, "type": "number" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -1024,12 +1024,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, polygon, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1042,6 +1036,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fmp, intrinio, polygon, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "The specific fiscal year. Reports do not go beyond 2008. (provider: intrinio)", "name": "fiscal_year", @@ -1142,17 +1142,17 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return.", "name": "limit", "optional": true, "type": "number" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -1170,12 +1170,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, polygon, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1188,6 +1182,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fmp, intrinio, polygon, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "The specific fiscal year. Reports do not go beyond 2008. (provider: intrinio)", "name": "fiscal_year", @@ -1288,17 +1288,17 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return.", "name": "limit", "optional": true, "type": "number" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -1362,14 +1362,14 @@ "name": "EQUITY.FUNDAMENTAL.FILINGS", "parameters": [ { - "description": "Options: fmp, intrinio, sec, defaults to fmp.", - "name": "provider", + "description": "Symbol to get data for.", + "name": "symbol", "optional": true, "type": "string" }, { - "description": "Symbol to get data for.", - "name": "symbol", + "description": "Options: fmp, intrinio, sec, defaults to fmp.", + "name": "provider", "optional": true, "type": "string" }, @@ -1436,12 +1436,6 @@ "name": "tag", "type": "string" }, - { - "description": "Options: intrinio, defaults to intrinio.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -1477,6 +1471,12 @@ "name": "sort", "optional": true, "type": "string" + }, + { + "description": "Options: intrinio, defaults to intrinio.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -1544,12 +1544,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, polygon, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1562,6 +1556,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fmp, intrinio, polygon, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "The specific fiscal year. Reports do not go beyond 2008. (provider: intrinio)", "name": "fiscal_year", @@ -1662,12 +1662,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return.", "name": "limit", @@ -1679,6 +1673,12 @@ "name": "period", "optional": true, "type": "string" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -1767,12 +1767,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1785,6 +1779,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fmp, intrinio, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Include trailing twelve months (TTM) data. (provider: fmp)", "name": "with_ttm", @@ -1851,12 +1851,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1869,6 +1863,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: fmp, intrinio, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Include trailing twelve months (TTM) data. (provider: fmp, intrinio)", "name": "with_ttm", @@ -1897,12 +1897,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: intrinio, defaults to intrinio.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1921,6 +1915,12 @@ "optional": true, "type": "number" }, + { + "description": "Options: intrinio, defaults to intrinio.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "The specific fiscal year. Reports do not go beyond 2008. (provider: intrinio)", "name": "fiscal_year", @@ -1943,12 +1943,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1960,6 +1954,12 @@ "name": "structure", "optional": true, "type": "string" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -1977,12 +1977,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time period of the data to return.", "name": "period", @@ -1994,6 +1988,12 @@ "name": "structure", "optional": true, "type": "string" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -2011,17 +2011,17 @@ "name": "query", "type": "string" }, - { - "description": "Options: intrinio, defaults to intrinio.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return.", "name": "limit", "optional": true, "type": "number" + }, + { + "description": "Options: intrinio, defaults to intrinio.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -2035,14 +2035,14 @@ "name": "EQUITY.FUNDAMENTAL.TRAILING_DIVIDEND_YIELD", "parameters": [ { - "description": "Options: tiingo, defaults to tiingo.", - "name": "provider", + "description": "Symbol to get data for.", + "name": "symbol", "optional": true, "type": "string" }, { - "description": "Symbol to get data for.", - "name": "symbol", + "description": "Options: tiingo, defaults to tiingo.", + "name": "provider", "optional": true, "type": "string" } @@ -2112,18 +2112,18 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return.", "name": "limit", "optional": true, "type": "number" }, + { + "description": "Options: fmp, intrinio, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Type of the transaction. (provider: fmp)", "name": "transactionType", @@ -2210,12 +2210,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "A specific date to get data for.", "name": "date", @@ -2227,6 +2221,12 @@ "name": "page", "optional": true, "type": "number" + }, + { + "description": "Options: fmp, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -2266,12 +2266,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, polygon, tiingo, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Time interval of the data to return.", "name": "interval", @@ -2290,6 +2284,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fmp, intrinio, polygon, tiingo, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Number of days to look back (Only for interval 1d). (provider: fmp);\nThe number of results to return per page. (provider: intrinio);\nThe number of data entries to return. (provider: polygon)", "name": "limit", @@ -2598,12 +2598,6 @@ "id": "EQUITY.SEARCH", "name": "EQUITY.SEARCH", "parameters": [ - { - "description": "Options: intrinio, sec, defaults to intrinio.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Search query.", "name": "query", @@ -2616,6 +2610,12 @@ "optional": true, "type": "boolean" }, + { + "description": "Options: intrinio, sec, defaults to intrinio.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "When true, return companies that are actively traded (having stock prices within the past 14 days). When false, return companies that are not actively traded or never have been traded. (provider: intrinio)", "name": "active", @@ -2842,14 +2842,14 @@ "name": "ETF.SEARCH", "parameters": [ { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", + "description": "Search query.", + "name": "query", "optional": true, "type": "string" }, { - "description": "Search query.", - "name": "query", + "description": "Options: fmp, defaults to fmp.", + "name": "provider", "optional": true, "type": "string" }, @@ -2898,12 +2898,6 @@ "id": "FIXEDINCOME.CORPORATE.COMMERCIAL_PAPER", "name": "FIXEDINCOME.CORPORATE.COMMERCIAL_PAPER", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -2933,6 +2927,12 @@ "name": "grade", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -2945,12 +2945,6 @@ "id": "FIXEDINCOME.CORPORATE.HQM", "name": "FIXEDINCOME.CORPORATE.HQM", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "A specific date to get data for.", "name": "date", @@ -2962,6 +2956,12 @@ "name": "yield_curve", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -2974,12 +2974,6 @@ "id": "FIXEDINCOME.CORPORATE.ICE_BOFA", "name": "FIXEDINCOME.CORPORATE.ICE_BOFA", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -2998,6 +2992,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "The type of category. (provider: fred)", "name": "category", @@ -3033,12 +3033,6 @@ "id": "FIXEDINCOME.CORPORATE.MOODY", "name": "FIXEDINCOME.CORPORATE.MOODY", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3057,6 +3051,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "The type of spread. (provider: fred)", "name": "spread", @@ -3074,12 +3074,6 @@ "id": "FIXEDINCOME.CORPORATE.SPOT_RATES", "name": "FIXEDINCOME.CORPORATE.SPOT_RATES", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3105,6 +3099,12 @@ "name": "category", "optional": true, "type": "any" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3117,12 +3117,6 @@ "id": "FIXEDINCOME.GOVERNMENT.TREASURY_RATES", "name": "FIXEDINCOME.GOVERNMENT.TREASURY_RATES", "parameters": [ - { - "description": "Options: federal_reserve, fmp, defaults to federal_reserve.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3134,6 +3128,12 @@ "name": "end_date", "optional": true, "type": "string" + }, + { + "description": "Options: federal_reserve, fmp, defaults to federal_reserve.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3146,12 +3146,6 @@ "id": "FIXEDINCOME.GOVERNMENT.US_YIELD_CURVE", "name": "FIXEDINCOME.GOVERNMENT.US_YIELD_CURVE", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "A specific date to get data for. Defaults to the most recent FRED entry.", "name": "date", @@ -3163,6 +3157,12 @@ "name": "inflation_adjusted", "optional": true, "type": "boolean" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3175,12 +3175,6 @@ "id": "FIXEDINCOME.RATE.AMERIBOR", "name": "FIXEDINCOME.RATE.AMERIBOR", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3193,6 +3187,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Period of AMERIBOR rate. (provider: fred)", "name": "parameter", @@ -3210,12 +3210,6 @@ "id": "FIXEDINCOME.RATE.DPCREDIT", "name": "FIXEDINCOME.RATE.DPCREDIT", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3228,6 +3222,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "FRED series ID of DWPCR data. (provider: fred)", "name": "parameter", @@ -3245,12 +3245,6 @@ "id": "FIXEDINCOME.RATE.ECB", "name": "FIXEDINCOME.RATE.ECB", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3268,6 +3262,12 @@ "name": "interest_rate_type", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3280,12 +3280,6 @@ "id": "FIXEDINCOME.RATE.EFFR", "name": "FIXEDINCOME.RATE.EFFR", "parameters": [ - { - "description": "Options: federal_reserve, fred, defaults to federal_reserve.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3298,6 +3292,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: federal_reserve, fred, defaults to federal_reserve.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Period of FED rate. (provider: fred)", "name": "parameter", @@ -3338,12 +3338,6 @@ "id": "FIXEDINCOME.RATE.ESTR", "name": "FIXEDINCOME.RATE.ESTR", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3356,6 +3350,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Period of ESTR rate. (provider: fred)", "name": "parameter", @@ -3373,12 +3373,6 @@ "id": "FIXEDINCOME.RATE.IORB", "name": "FIXEDINCOME.RATE.IORB", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3390,6 +3384,12 @@ "name": "end_date", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3402,12 +3402,6 @@ "id": "FIXEDINCOME.RATE.SONIA", "name": "FIXEDINCOME.RATE.SONIA", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3420,6 +3414,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Period of SONIA rate. (provider: fred)", "name": "parameter", @@ -3437,12 +3437,6 @@ "id": "FIXEDINCOME.SOFR", "name": "FIXEDINCOME.SOFR", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3455,6 +3449,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Period of SOFR rate. (provider: fred)", "name": "period", @@ -3472,12 +3472,6 @@ "id": "FIXEDINCOME.SPREADS.TMC", "name": "FIXEDINCOME.SPREADS.TMC", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3495,6 +3489,12 @@ "name": "maturity", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3507,12 +3507,6 @@ "id": "FIXEDINCOME.SPREADS.TMC_EFFR", "name": "FIXEDINCOME.SPREADS.TMC_EFFR", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3530,6 +3524,12 @@ "name": "maturity", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3542,12 +3542,6 @@ "id": "FIXEDINCOME.SPREADS.TREASURY_EFFR", "name": "FIXEDINCOME.SPREADS.TREASURY_EFFR", "parameters": [ - { - "description": "Options: fred, defaults to fred.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3565,6 +3559,12 @@ "name": "maturity", "optional": true, "type": "string" + }, + { + "description": "Options: fred, defaults to fred.", + "name": "provider", + "optional": true, + "type": "string" } ], "result": { @@ -3595,14 +3595,14 @@ "name": "INDEX.CONSTITUENTS", "parameters": [ { - "description": "Options: fmp, defaults to fmp.", - "name": "provider", + "description": "Index for which we want to fetch the constituents.", + "name": "index", "optional": true, "type": "string" }, { - "description": "Index for which we want to fetch the constituents.", - "name": "index", + "description": "Options: fmp, defaults to fmp.", + "name": "provider", "optional": true, "type": "string" } @@ -3622,12 +3622,6 @@ "name": "symbol", "type": "string" }, - { - "description": "Options: fmp, intrinio, polygon, defaults to fmp.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "Start date of the data, in YYYY-MM-DD format.", "name": "start_date", @@ -3640,6 +3634,12 @@ "optional": true, "type": "string" }, + { + "description": "Options: fmp, intrinio, polygon, defaults to fmp.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Number of days to look back. (provider: fmp)", "name": "timeseries", @@ -3716,18 +3716,18 @@ "name": "symbols", "type": "string" }, - { - "description": "Options: benzinga, fmp, intrinio, polygon, tiingo, defaults to benzinga.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return.", "name": "limit", "optional": true, "type": "number" }, + { + "description": "Options: benzinga, fmp, intrinio, polygon, tiingo, defaults to benzinga.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Specify headline only (headline), headline + teaser (abstract), or headline + full body (full). (provider: benzinga)", "name": "display", @@ -3841,18 +3841,18 @@ "id": "NEWS.WORLD", "name": "NEWS.WORLD", "parameters": [ - { - "description": "Options: benzinga, fmp, intrinio, tiingo, defaults to benzinga.", - "name": "provider", - "optional": true, - "type": "string" - }, { "description": "The number of data entries to return. Here its the no. of articles to return.", "name": "limit", "optional": true, "type": "number" }, + { + "description": "Options: benzinga, fmp, intrinio, tiingo, defaults to benzinga.", + "name": "provider", + "optional": true, + "type": "string" + }, { "description": "Specify headline only (headline), headline + teaser (abstract), or headline + full body (full). (provider: benzinga)", "name": "display", @@ -3977,14 +3977,14 @@ "name": "REGULATORS.SEC.INSTITUTIONS_SEARCH", "parameters": [ { - "description": "Options: sec, defaults to sec.", - "name": "provider", + "description": "Search query.", + "name": "query", "optional": true, "type": "string" }, { - "description": "Search query.", - "name": "query", + "description": "Options: sec, defaults to sec.", + "name": "provider", "optional": true, "type": "string" }, @@ -4023,14 +4023,14 @@ "name": "REGULATORS.SEC.SCHEMA_FILES", "parameters": [ { - "description": "Options: sec, defaults to sec.", - "name": "provider", + "description": "Search query.", + "name": "query", "optional": true, "type": "string" }, { - "description": "Search query.", - "name": "query", + "description": "Options: sec, defaults to sec.", + "name": "provider", "optional": true, "type": "string" }, @@ -4052,14 +4052,14 @@ "name": "REGULATORS.SEC.SIC_SEARCH", "parameters": [ { - "description": "Options: sec, defaults to sec.", - "name": "provider", + "description": "Search query.", + "name": "query", "optional": true, "type": "string" }, { - "description": "Search query.", - "name": "query", + "description": "Options: sec, defaults to sec.", + "name": "provider", "optional": true, "type": "string" }, @@ -4081,14 +4081,14 @@ "name": "REGULATORS.SEC.SYMBOL_MAP", "parameters": [ { - "description": "Options: sec, defaults to sec.", - "name": "provider", + "description": "Search query.", + "name": "query", "optional": true, "type": "string" }, { - "description": "Search query.", - "name": "query", + "description": "Options: sec, defaults to sec.", + "name": "provider", "optional": true, "type": "string" } diff --git a/website/content/excel/usage/basics.md b/website/content/excel/usage/basics.md index d496e82e12e..49b6a12fde8 100644 --- a/website/content/excel/usage/basics.md +++ b/website/content/excel/usage/basics.md @@ -37,9 +37,9 @@ Examples: 3. Getting the earnings calendar: ```excel - =OBB.EQUITY.CALENDAR.IPO(;;"2023-11-20") + =OBB.EQUITY.CALENDAR.IPO(;"2023-11-20") ``` :::tip -If you want to skip a parameter just use semi-colon (or comma depending on your number separator) without any value. In example iii. we are skipping the first parameter (provider) and the second parameter (symbol). +If you want to skip a parameter use semi-colon (or comma depending on your number separator) without any value. In example iii. we are skipping the first parameter (symbol). ::: diff --git a/website/generate_excel_markdown.py b/website/generate_excel_markdown.py index d05a551b669..9ff8dca6470 100644 --- a/website/generate_excel_markdown.py +++ b/website/generate_excel_markdown.py @@ -21,8 +21,6 @@ XL_FUNCS_URL = "https://excel.openbb.co/assets/functions.json" class CommandLib(PathHandler): """Command library.""" - # No commands should be added manually until we decide how to proceed - MANUAL_MAP = {} XL_TYPE_MAP = { "bool": "Boolean", "float": "Number", @@ -32,8 +30,6 @@ class CommandLib(PathHandler): "string": "Text", } EXAMPLE_PARAMS: Dict[str, Dict] = { - "last": {"symbol": '"AAPL"', "tag": '"EBITDA"'}, - "hist": {"symbol": '"AAPL"', "tag": '"EBITDA"'}, "crypto": {"symbol": '"BTCUSD"'}, "currency": {"symbol": '"EURUSD"'}, "derivatives": {"symbol": '"AAPL"'}, @@ -56,8 +52,6 @@ class CommandLib(PathHandler): self.xl_funcs = self.read_xl_funcs() self.seo_metadata = self.read_seo_metadata() - self.update() - @staticmethod def fetch(): """Fetch the excel functions.""" @@ -65,11 +59,6 @@ class CommandLib(PathHandler): with open(XL_FUNCS_PATH, "w") as f: json.dump(r.json(), f, indent=2) - def update(self): - """Update with manual map.""" - for key, value in self.MANUAL_MAP.items(): - self.route_map[key] = self.route_map[value] - def read_seo_metadata(self) -> dict: """Get the SEO metadata.""" with open(SEO_METADATA_PATH) as f: @@ -95,18 +84,16 @@ class CommandLib(PathHandler): return self.xl_funcs.get(cmd, {}).get("name", ".").split(".")[-1].lower() return "" - def _get_signature(self, cmd: str, path_only: bool = False) -> str: + def _get_signature(self, cmd: str, parameters: dict) -> str: """Get the signature of the command.""" if cmd in self.route_map: sig = "=OBB." + self.xl_funcs[cmd].get("name", "") - if path_only: - return sig sig += "(" - for p in self.xl_funcs[cmd]["parameters"]: - if p.get("optional", False): - sig += f'[{p["name"]}]' + for p_name, p_info in parameters.items(): + if p_info["required"]: + sig += f"{p_name}" else: - sig += f'{p["name"]}' + sig += f"[{p_name}]" sig += ";" sig = sig.strip("; ") + ")" return sig @@ -132,7 +119,7 @@ class CommandLib(PathHandler): parameters[p["name"]] = { "type": self.to_xl(str(p["type"])), "description": p["description"].replace("\n", " "), - "optional": str(p.get("optional", False)).title(), + "required": not p.get("optional", False), } return parameters @@ -151,20 +138,15 @@ class CommandLib(PathHandler): return {} - def _get_examples(self, cmd: str) -> dict: - cmd_info = self.xl_funcs[cmd] - if cmd in self.route_map: - parameters = cmd_info["parameters"] - minimal_eg = "=OBB." + cmd_info.get("name", "") + "(" - category = cmd.split("/")[1] - for p in parameters: - p_name = p["name"] - if not p.get("optional", False): - p_value = self.EXAMPLE_PARAMS.get(category, {}).get(p_name, "") - minimal_eg += f"{p_value};" - minimal_eg = minimal_eg.strip("; ") + ")" - return {"A. Minimal": minimal_eg} - return {} + def _get_examples(self, signature_: str, parameters: dict) -> dict: + minimal_eg = signature_.split("(")[0] + "(" + category = signature_.split(".")[1].lower() + for p_name, p_info in parameters.items(): + if p_info["required"]: + p_value = self.EXAMPLE_PARAMS.get(category, {}).get(p_name, "") + minimal_eg += f"{p_value};" + minimal_eg = minimal_eg.strip("; ") + ")" + return {"A. Minimal": minimal_eg} def get_info(self, cmd: str) -> Dict[str, Any]: """Get the info for a command.""" @@ -172,11 +154,11 @@ class CommandLib(PathHandler): if not name: return {} description = self.xl_funcs[cmd].get("description", "").replace("\n", " ") - signature_ = self._get_signature(cmd) parameters = self._get_parameters(cmd) + signature_ = self._get_signature(cmd, parameters) data = self._get_data(cmd) return_ = self.xl_funcs[cmd].get("result", {}).get("dimensionality", "") - examples = self._get_examples(cmd) + examples = self._get_examples(signature_, parameters) if model_name := self._get_model(cmd): return { "name": name, @@ -252,17 +234,21 @@ class Editor: def get_parameters() -> str: parameters = "## Parameters\n\n" - parameters += "| Name | Type | Description | Optional |\n" + parameters += "| Name | Type | Description | Required |\n" parameters += "| ---- | ---- | ----------- | -------- |\n" for field_name, field_info in cmd_info["parameters"].items(): name = field_name type_ = field_info["type"] description = field_info["description"] - optional = field_info["optional"] - if optional == "True": - parameters += f"| {name} | {type_} | {description} | {optional} |\n" + required = field_info["required"] + required_str = str(required).title() + if required: + parameters += f"| **{name}** | **{type_}** | **{description}** | **{required_str}** |\n" else: - parameters += f"| **{name}** | **{type_}** | **{description}** | **{optional}** |\n" + parameters += ( + f"| {name} | {type_} | {description} | {required_str} |\n" + ) + parameters += "\n" return parameters