I am trying to build event object for requesting segmentation for specific events.
I'm using this guide in the docs: https://www.docs.developers.amplitude.com/analytics/apis/dashboard-rest-api/#event-format-example
However I cannot figure out what to do when the property I'm goth filtering by AND grouping by is actually event name.
Here is the object I built, but it is not working:
{
"event_type": "_all",
"filters":
[
{
"subprop_type": "event",
"subprop_key": "Event Name",
"subprop_op": "is",
"subprop_value":
[
"event1",
"event2"
]
}
],
"group_by":
[
{
"type": "event",
"value": "Event Name"
}
]
}
I'm assuming something is wrong with 'subgroup_key' in filters and 'value' in group_by? But I cannot find instructions for what to do in this case
Found the setting, in case anyone else will be looking for it: in the API the property to get event name is
event_type_value
.so the call that worked is: