Skip to content

Commit

Permalink
πŸŽ‰ Plaid handling non-us bank and language (#151)
Browse files Browse the repository at this point in the history
Co-authored-by: David Papp <david.papp@whenthen.com>
  • Loading branch information
pigri and David Papp committed Jun 1, 2023
1 parent 227e425 commit 6d6c425
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/integrations/plaid/plaidIntegration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,16 @@ export class PlaidIntegration {

app.post('/create_link_token', async (req, res) => {
const clientUserId = this.user.client_user_id
const country_codes = process.env.COUNTRY_CODES ? process.env.COUNTRY_CODES.split(',') : ['US']
const language = process.env.LANGUAGE ? process.env.LANGUAGE : 'en'
const options: CreateLinkTokenOptions = {
user: {
client_user_id: clientUserId
},
client_name: 'Mintable',
products: ['transactions'],
country_codes: ['US'], // TODO
language: 'en' // TODO
country_codes,
language
}
if (req.body.access_token) {
options.access_token = req.body.access_token
Expand Down

0 comments on commit 6d6c425

Please sign in to comment.