Participant getCount is too slow
What is the number of participants you have?

depending of the entity, getCount is just a wrapper around get, so it might be the issue if you have lots of participants.

I haven't looked for participants, but writing (and contributing that back to civicrm core) a custom getCount api with a simplier query that only does select count() would probably makes it way faster