Dec 27, 2022 05:17 AM - edited Dec 27, 2022 09:32 PM
Hi, My Airtable use case is to maintain Farmer’s finances. We have developed a WhatsApp bot, and by using webhook triggers the information gets stored in Airtable.
I am using webhooks to populate the Expense Amount field. For eg: The bot asks the question about the Expense Amount, as soon as the user answers this question, the webhook triggers, and the value of the Expense Amount gets updated.
What I am trying to achieve is, if the User enters the Expense Amount for the same expense type, the field should add/sum the new value to the previously populated value.
For eg: If the user John, enters the Expense Amount for E1 as 200 again then the Expense Amount field should be 300(100 + 200).
I want to append the new incoming values in the field and not overwrite it.
Any advice or help is appreciated
Dec 27, 2022 10:16 AM
Can you provide more details on what your webhook currently does? Does it create a new record, or does it find the existing record and overwrite the values? What platform are you using to make these data changes?
I also recommend considering a new linked table where all transactions with the same user and expense type are linked to the same record, and then use a rollup field to sum the values. This will preserve the individual record data and also provide you with the sum.
Dec 27, 2022 09:28 PM
I have edited the question.
1. The webhook updates the Expense Amount field.
2. WhatsApp is our source of information, all the information gets stored/ updated based on the bot flow.
Can you please guide me to some articles or similar implementations for reference?