Skip to content
This repository was archived by the owner on Jul 27, 2025. It is now read-only.

Initial pass at Plaid EU#1555

Merged
Shpigford merged 11 commits intomainfrom
plaid-eu
Jan 31, 2025
Merged

Initial pass at Plaid EU#1555
Shpigford merged 11 commits intomainfrom
plaid-eu

Conversation

@Shpigford
Copy link
Copy Markdown
Member

No description provided.

@Shpigford Shpigford requested a review from zachgoll December 18, 2024 17:04
@Shpigford
Copy link
Copy Markdown
Member Author

@zachgoll First high-level pass at adding EU support. You've got a better handle of how the Plaid stuff works, so let me know if I'm off base here.

Copy link
Copy Markdown
Contributor

@zachgoll zachgoll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reached out to Plaid and they said there is no way to figure out whether an "Item" is US or EU just based on the Plaid Item data.

So the biggest thing we're missing currently here is that identifying piece of data stored on PlaidItem. I think since there are only 2 possible clients, we could consider a field called plaid_region that is a string and in our model we could probably validate that too:

class PlaidItem < ApplicationRecord
  enum :plaid_region, { us: "us", eu: "eu" }
end

Which would then allow us to easily access it like, some_item.eu?

Otherwise, I think EU should work largely the same as US and I believe our existing implementation will properly handle these multi-currency accounts fine.

Comment thread .env.example Outdated
Comment thread db/schema.rb
Comment thread app/models/concerns/plaidable.rb
Comment thread app/views/accounts/new/_method_selector.html.erb Outdated
Signed-off-by: Josh Pigford <josh@joshpigford.com>
@Shpigford
Copy link
Copy Markdown
Member Author

@zachgoll Take a look now.

@Shpigford Shpigford requested a review from zachgoll December 19, 2024 15:20
Copy link
Copy Markdown
Contributor

@zachgoll zachgoll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I like this strategy of passing it from the Stimulus controller. Should work nicely!

Comment thread db/schema.rb Outdated
Comment thread app/controllers/plaid_items_controller.rb
Comment thread app/models/plaid_item.rb Outdated
@Shpigford Shpigford marked this pull request as ready for review January 31, 2025 17:09
@Shpigford
Copy link
Copy Markdown
Member Author

@zachgoll Two things I'm not sure on...

  1. Do we need to add Canada ("CA") to the region stuff? Or will "US" properly cover it thanks to get_country_codes?
  2. There are failing system tests that I'm not familiar enough with to not potentially completely break them.

@Shpigford Shpigford requested a review from zachgoll January 31, 2025 17:10
Copy link
Copy Markdown
Contributor

@zachgoll zachgoll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Shpigford to my understanding, you have the CA configuration correct here. I believe CA is fully covered under the "US" client:

CleanShot 2025-01-31 at 12 19 42

Comment thread app/views/accounts/new/_method_selector.html.erb Outdated
@Shpigford
Copy link
Copy Markdown
Member Author

@zachgoll ✅ Anything else before merging this?

@zachgoll
Copy link
Copy Markdown
Contributor

@Shpigford I think we're all set. Only thing I can think of is making sure these are set in prod:

PLAID_EU_CLIENT_ID=
PLAID_EU_SECRET=

@Shpigford Shpigford merged commit 4bf7250 into main Jan 31, 2025
@Shpigford Shpigford deleted the plaid-eu branch January 31, 2025 18:14
@henrikbjorn
Copy link
Copy Markdown

Not to hijack, but would GoCardless be an idea also? That is easily obtainable for self-hosting.

@Shpigford
Copy link
Copy Markdown
Member Author

Not to hijack, but would GoCardless be an idea also? That is easily obtainable for self-hosting.

https://github.com/maybe-finance/maybe/discussions/141

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants