Group by item in parent list, then by item in sub list, how to display count and both criteria?

I have lists with different currencies and tokens and I do a COUNT() on token.

currency: "USD",
services [
 category {token: "Stay", token: "Sports"}

But I need the COUNT to be per currency too so I get a list like:

{currency: "USD", token: "Stay", count: 1},
{currency: "USD", token: "Sports", count: 1}

Current formula
GROUP<currency>(FLATTEN(MAP(data.getProviders, item.currency)), currency, {category: GROUP(FLATTEN(MAP<service>(FLATTEN(MAP<provider>(data.getProviders,, service.category)), item.token, {count: COUNT(items), token: key})})
…returns this, but i want to see the property "currency": USD as well either inside the object or as a list