What fields should I save in database

(Mass Venture) #1

What fields are ideal to save in our database? Currently I am saving:

  • refresh_token
  • account_id
  • account_name (for displaying)
  • access_token
  • token_expirated_at

But I am wondering if we should save

  • funding source url (is anyone doing this?)
  • transfer urls (thinking we should so we can ping for status)

(Spencer Hunter) #2

We’d probably recommend storing all associations to a unique resource after one is created. Transfers, Funding source, etc. Ultimately it depends on your app, how many calls you want to make to our API, how you’re presenting information within your app.

With regards to updating information such as transfer statuses, we’d highly recommend setting up a webhook-subscription. Polling tends to be inefficient and not the best way to receive near realtime information on updates to resources.