Code Monkey home page Code Monkey logo

financialmodelingprep.net's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

financialmodelingprep.net's Issues

Case sensitive parameters

Hi Matthi,

Can you confirm this with me? It looks like the period enum isn't working as a parameter

It seems like the parameters are case sensitive:

doesn't work (note capital Q in Quarter)
https://financialmodelingprep.com/api/v3/analyst-estimates/APY.TO?period=Quarter&limit=22&apikey=abc
works:
https://financialmodelingprep.com/api/v3/analyst-estimates/APY.TO?period=quarter&limit=22&apikey=abc

When it doesn't work it seems to be returning the annual results and the period enum defaults to a capitalised string

It seems to be on all endpoints (or at least the couple I've tried)

Error on GetEnterpriseValueAsync

There are some error on getting the enterprise values, for example with symbol AAPL you get the data, with ticket NNN you get the following json error:

System.Text.Json.JsonException: The JSON value could not be converted to System.Int64. Path: $[2].minusCashAndCashEquivalents | LineNumber: 24 | BytePositionInLine: 43.
---> System.FormatException: Either the JSON value is not in a supported format, or is out of bounds for an Int64.
at System.Text.Json.Utf8JsonReader.GetInt64()

Maybe you can change the type of the the following properties in classes
MatthiWare.FinancialModelingPrep.Model.CompanyValuation.EnterpriseValueResponse to double:

  • AddTotalDebt
  • MinusCashAndCashEquivalents

GetAnalystEstimatesAsync fails

For some tickers like SHUR.BR the data for year 2018 contains null. As a result of this the deserialization fails.
All value fields on AnalystEstimateItem should be nullable.

Target .NET5 & .NET6

To make the transition to .NET 6 easier we should target both for now.
Eventually we can remove .NET 5 target.

Rate limit amount of requests per second

In order to comply with the ToS of FMP we need to ensure a max of 10 requests per second is being send to the API.

  • Rate limit the HttpClient
  • Make max allowed requests/sec configurable (default 10)

An Issue when retrieving Quartal ballance sheets for TSLA

Hi getting ERROR when calling this:
var test = api.CompanyValuation.GetBalanceSheetStatementAsync("TSLA", MatthiWare.FinancialModelingPrep.Model.Period.Quarter, 10000).Result;

May I ask you to fix this serialization ERROR?

System.Text.Json.JsonException: The JSON value could not be converted to System.Double. Path: $[52].othertotalStockholdersEquity | LineNumber: 2904 | BytePositionInLine: 39.
---> System.InvalidOperationException: Cannot get the value of a token type 'Null' as a number.
at System.Text.Json.Utf8JsonReader.TryGetDouble(Double& value)
at System.Text.Json.Utf8JsonReader.GetDouble()
at System.Text.Json.Serialization.Converters.DoubleConverter.ReadNumberWithCustomHandling(Utf8JsonReader& reader, JsonNumberHandling handling)
at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
at System.Text.Json.Serialization.Converters.IEnumerableDefaultConverter2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state) --- End of inner exception stack trace --- at System.Text.Json.ThrowHelper.ReThrowWithPath(ReadStack& state, Utf8JsonReader& reader, Exception ex) at System.Text.Json.Serialization.JsonConverter1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state)
at System.Text.Json.JsonSerializer.ReadCore[TValue](JsonConverter jsonConverter, Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state)
at System.Text.Json.JsonSerializer.ReadCore[TValue](Utf8JsonReader& reader, Type returnType, JsonSerializerOptions options)
at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, Type returnType, JsonSerializerOptions options)
at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options)
at MatthiWare.FinancialModelingPrep.Core.Http.FinancialModelingPrepHttpClient.GetJsonAsync[T](String urlPattern, NameValueCollection pathParams, QueryStringBuilder queryString)

Deserialization error when a json property is null

These properties can be null:
CompanyProfileResponse.Price
CompanyProfileResponse.Changes
HistoricalPriceItem.UnadjustedVolume

Can you please add these fixes? It seems FmP is using null values more and more?
Thank you

An Issue when retrieving statements

Hi, getting a deserialization ERROR when retrieving financial statements for many tickers, this was for ticker MTG.

ERROR when retrieving data for symbol: MTG message: System.Text.Json.JsonException: The JSON value could not be converted to System.Double. Path: $[0].interestIncome | LineNumber: 21 | BytePositionInLine: 26.
---> System.InvalidOperationException: Cannot get the value of a token type 'Null' as a number.
at System.Text.Json.Utf8JsonReader.TryGetDouble(Double& value)
at System.Text.Json.Utf8JsonReader.GetDouble()
at System.Text.Json.Serialization.Converters.DoubleConverter.ReadNumberWithCustomHandling(Utf8JsonReader& reader, JsonNumberHandling handling, JsonSerializerOptions options)
at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.Metadata.JsonPropertyInfo1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
at System.Text.Json.Serialization.Converters.ObjectDefaultConverter1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
at System.Text.Json.Serialization.JsonCollectionConverter2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value) at System.Text.Json.Serialization.JsonConverter1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state)

May I ask you to fix this serialization ERROR?
Thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.