{{ pageId }} does look slightly different for dynamic CRM pages than a standard website page... instead of just a number, it looks something more like crm-XXXXXXXXXXX-{{ objectType }}-{{ objectId }}.
Bottom line... how can I access analytics for dynamic CRM pages?
This is due to the change in HubSpot API usage policy change.
What you can do is to go to your HubSpot Account on which you have defined your API call and create a private app there and use Bearer Token rather than API.
Hope this helps!
If we were able to answer your query, kindly help the community by marking it as a solution.