nordigen / nordigen-ruby Goto Github PK
View Code? Open in Web Editor NEWRuby library for the Nordigen API.
License: MIT License
Ruby library for the Nordigen API.
License: MIT License
Describe the bug
Even when providing date_from
and date_to
to get_transactions
all transactions are returned.
To Reproduce
# Filter transactions by specific date range
transactions = account.get_transactions(date_from: "2021-12-01", date_to: "2022-01-30")
Expected behavior
Only a subset of transactions returned.
Additional context
Looks like the Faraday call here https://github.com/nordigen/nordigen-ruby/blob/master/lib/nordigen-ruby.rb#L38 doesn't actually get the parameters.
Describe the bug
Old(ish) dependencies causes deprecation notices:
Top level ::CompositeIO is deprecated, require 'multipart/post' and use `Multipart::Post::CompositeReadIO` instead!
Top level ::Parts is deprecated, require 'multipart/post' and use `Multipart::Post::Parts` instead!
Faraday seems to be the only outdated gem:
~/d/ynai ▶ bundle outdated
Fetching gem metadata from https://rubygems.org/..........
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies...
Outdated gems included in the bundle:
* faraday (newest 2.5.2, installed 1.8.0)
* faraday-excon (newest 2.1.0, installed 1.1.0)
* faraday-httpclient (newest 2.0.1, installed 1.0.1)
* faraday-net_http (newest 3.0.0, installed 1.0.1)
* faraday-net_http_persistent (newest 2.1.0, installed 1.2.0)
* faraday-patron (newest 2.0.1, installed 1.0.0)
* faraday-rack (newest 2.0.0, installed 1.0.0)
And some Googling suggests that it's indeed the culprit. Pinning multipart-post
to an earlier version might fix it, but it's an unsatisfactory solution.
To Reproduce
Steps to reproduce the behavior:
Just require the gem in the Gemfile and requiring it in a ruby script seems to trigger it.
Expected behavior
No notices
Describe the solution you'd like
I would like to be able to save authentication tokens so that my application does not have to visit Nordigen's or the bank's website each time the user wants to update their transactions. I am aware of the fact that this is required by the PSD2 system every 90 days, but it should not be required on every invocation of the app.
Describe alternatives you've considered
I have implemented a login flow as per the example, but I cannot get the login flow working with client.set_token(...)
and an existing Refresh token, without still having to authorize my app by authenticating with the bank.
Additional context
Please add a specific example on how and what to store to be able to repeatedly access an account via Nordigen, without having to authenticate every time.
Thanks!
Hi, I was wondering how to access the premium content. I searched in the lib but didn't find the endpoint for:
accounts/premium/{id}/transactions/
In here shouldn't we add a premium condition in AccountApi:
url = if premium
"#{ENDPOINT}premium/#{@account_id}/"
else
"#{ENDPOINT}#{@account_id}/"
end
Thanks for your help !
Is your feature request related to a problem? Please describe.
Add the option to set user_language
and account_selection
when we create a requisition (init_session
)
Describe the solution you'd like
# lib/nordigen-ruby.rb
def init_session(redirect_url:, institution_id:, reference_id:, max_historical_days: 90, user_language: "en", account_selection: false)
# ...
new_requsition = @requisition.create_requisition(
redirect_url: redirect_url,
reference: reference_id,
institution_id: institution_id,
user_language: user_language,
account_selection: account_selection,
agreement: new_agreement["id"]
)
# ...
end
# lib/nordigen_ruby/api/requisitions.rb
def create_requisition(redirect_url:, reference:, institution_id:, user_language: "en", agreement: nil, account_selection: false)
# ...
payload = {
"redirect": redirect_url,
"reference": reference,
"institution_id": institution_id,
"user_language": user_language,
"account_selection": account_selection,
}
# ...
end
It would be nice to be able to suggest Pull Request
Is your feature request related to a problem? Please describe.
The Nordigen client is using parser_options: { object_class: OpenStruct }
by default when initializing the Faraday request:
https://github.com/nordigen/nordigen-ruby/blob/master/lib/nordigen-ruby.rb#L36
We are trying to get a transaction list to then send to your insights API for categorization, which needs a JSON input according to Nordigen's Open Banking Portal. It is really complicated to get the transactions in this format from the OpenStruct.
Describe the solution you'd like
It would be nice if these parser option could be optional.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.