Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce number of data pulls from Airtable #4

Open
2 of 3 tasks
cweems opened this issue Mar 31, 2022 · 0 comments
Open
2 of 3 tasks

Reduce number of data pulls from Airtable #4

cweems opened this issue Mar 31, 2022 · 0 comments

Comments

@cweems
Copy link
Owner

cweems commented Mar 31, 2022

There are a few instances where the middleware is pulling all contacts from Airtable, just to match a single record. If we can refactor these then we'll be able to reduce the number of API calls to Airtable and improve app load time.

Functions to refactor:

  • getCustomerByNumber: called when a new conversation is created by Twilio Conversations on inbound SMS.
  • getCustomerById: called when a contact is viewed form the contact list.

We may also be able to filter the list of records retrieved from Airtable by filtering by owner.

  • Filter airtable contacts returned by owner in request.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant