Solved

Query Metric Aggregate by list ID

  • 2 October 2023
  • 9 replies
  • 132 views

Badge +3

Hi there,

I'm currently working on obtaining the "Subscribed to List" metric with a specific List ID. My objective is to correlate metrics with list data, which requires me to access metrics filtered by List ID. I'm already familiar with using the Query Metric Aggregates Endpoint to retrieve metrics by Flow ID ($flow) and Campaign ID ($message).

Could you please guide me on how to retrieve metrics specifically by List ID? Your assistance is greatly appreciated.

Thank you for your response.

Best,
Santi

icon

Best answer by Brian Turcotte 23 October 2023, 21:27

View original

9 replies

Userlevel 7
Badge +36

Hi @santiagosanti!

 

According to this guide on using the endpoint, you can separate/filter the response using the filter or by attributes:

 

In your case, you would filter/group by ‘List’. For a list of the attributes by which you can filter/group, see here:

 

Best,

Brian

Badge +3

Hello,

I am looking for some guidance on how to retrieve the "Subscribed to List" metric for lists by List ID rather than List Name.

The reason I need to filter by List ID is because List Names are not guaranteed to be unique, while the List ID will unambiguously identify the list I want to analyze.

I've reviewed the API documentation I don't see a way to get metrics by List ID.

Could someone please advise if there is a way to get metrics for a particular list using the unique List ID value? That would allow me to correlate the metric data with the list meta data.

Any pointers would be greatly appreciated!.

Best,
Santi

Userlevel 7
Badge +36

Hi @santiagosanti!

At this time, List ID is not a supported attribute, but you could also use the Get Lists endpoint to build a dictionary of List Names and List IDs, and reference that.

 

Best,

Brian

Badge +3

Hi Brian,

Quick question - are list names guaranteed to be unique?

Thanks, Santi

Userlevel 7
Badge +36

Hi @santiagosanti!

No they’re not, so if your account has many lists, List ID would probably be more appropriate.

 

Best,

Brian

Badge +3

Hi Brian,

I've seen the API documentation I don't see a way to get metrics by List ID. Can I expect this in next API revision update?

Thanks,
Santi

Badge +3

Hi Brian,

any update on this?

Thanks,
Santi

Badge +3

Hi 

I don't see a way to get metrics by List ID. Can I expect this in next API revision update?

can anyone answer this?

Thanks,
Santi

Userlevel 7
Badge +36

Hi @santiagosanti!

Our API team is currently working on ways to streamline this, so I’ll make sure to update the thread when more information is available!

Best,

Brian

Reply