Structured Output to Google Spreadsheet
# support
r
Hi, is there an automated way to update a google spreadsheet with strucutred output collected from a call? I am using Dashboard Vapi and have configured structured outputs to my assistant to collected data. I have also created a Google Spreadsheet tool that is linked to the assistant. How should I prompt the assistant? Is this even possible? Currently I have the following in my assistant prompt: END OF THE CALL After the call has ended, make a call to the tool offer_google_sheet and update the Google spreadsheet with the following structured output: C: {{first_name}} D: {{company_name}} E: phone_number F: monthly_revenue G: requested_amount_aud H: timeline I: challenge J: product_interest_level K: remove_from_list L: success_evaluation
v
Yes, this is possible! To automate updating your Google Spreadsheet, prompt your assistant like this:
Copy code
After the call ends, use the tool `choco_up_offer_google_sheet` to append a new row with these values:
["{{first_name}}", "{{company_name}}", "{{phone_number}}", "{{monthly_revenue}}", "{{requested_amount_aud}}", "{{timeline}}", "{{challenge}}", "{{product_interest_level}}", "{{remove_from_list}}", "{{success_evaluation}}"]
Make sure your tool configuration matches the column order, and confirm all required fields are present before appending the row. For more details, see the [Google Sheets integration documentation](https://docs.vapi.ai/assistants/tools/google-sheets). Source: - [Google Sheets integration documentation](https://docs.vapi.ai/assistants/tools/google-sheets)
v
Message marked as helpful by @Rahul! 🎉
r
Thanks, that seemed to work. How do I add instructions to start making the updates from Column C onwards, as he first column has been mapped to an ID that is auto-generated by the spreadsheet itself. In the tool I have set the range as Leads!C:L, but that does not seem to make a difference.
c
Hi Rahul — yes, you can append starting at column C. Two important notes and a concise prompt you can use: 1. Range semantics: In the Google Sheets Add Row tool, setting range to "Leads!C:L" only restricts where the row is appended, but the tool still treats the values array as the row to append starting at the first column of that range (i.e., it will place the first value into column C). So your current range is fine. 2. Ensure values order = columns C→L. The tool doesn't accept explicit "write to C" labels — you must supply the values array in the exact order of columns C through L. Also confirm spreadsheetId/range are correct and the sheet headers/format don't block appends. Recommended assistant instruction (paste into your end-of-call flow): After the call ends, call the Google Sheets tool choco_up_offer_google_sheet with: • spreadsheetId: • range: "Leads!C:L" • values: ["{{first_name}}", "{{company_name}}", "{{phone_number}}", "{{monthly_revenue}}", "{{requested_amount_aud}}", "{{timeline}}", "{{challenge}}", "{{product_interest_level}}", "{{remove_from_list}}", "{{success_evaluation}}"] Make sure the tool's values array maps one-to-one with columns C→L. If you need the sheet to keep an auto-generated ID in column A, and other system data in B, leave those columns alone — appends to Leads!C:L will fill columns C–L only. If rows are still misaligned, paste a sample tool payload you see in Call Logs and I’ll verify field ordering.