SUPPORT.TWILIO.COM END OF LIFE NOTICE: This site, support.twilio.com, is scheduled to go End of Life on February 27, 2024. All Twilio Support content has been migrated to help.twilio.com, where you can continue to find helpful Support articles, API docs, and Twilio blog content, and escalate your issues to our Support team. We encourage you to update your bookmarks and begin using the new site today for all your Twilio Support needs.

Format groupBy for Delivery Overview Public API Endpoints

Objective

If you encounter errors when adding the groupBy parameter, this guide explains how to correctly format it when using the Public API endpoints for Delivery Overview. Whether you are using the API tester, cURL, or the Segment Public API SDK, these steps will help you resolve the issue and format the value correctly.

 

Product

Twilio Segment

 

Environment

Segment Console

 

User Account Permission/Role(s) Required 

Access to a Segment workspace and permission to use the Segment Public API.

 

Procedure 

When making a request to the /delivery-overview endpoints and you want to use the groupBy parameter, you must format its value as a JSON array. For example:
  • To group by eventName, set the parameter as: ["eventName"]
  • If you want to group by multiple fields, include them as comma-separated strings within the array: ["eventName", "anotherField"].

 

Additional Information 

  • In the Segment Public API tester: Locate the groupBy field and enter the value as a JSON array (e.g., ["eventName"]). If grouping by more than one field, add each field within the same array.
    • Note: Using repeated query parameters or the 'Add item' button in the API tester will not work unless the value is formatted as a JSON array.
  • If using cURL or a direct API call: Ensure the groupBy parameter is passed as a JSON array string.

 

Have more questions? Submit a request
Powered by Zendesk