0

I want to integrate Google's mobile-friendly and desktop-friendly API with PageSpeed Insights API. But I'm unable to differentiate the Audit section.

How to differentiate Passed Audits, Diagnostics, and Opportunities in PageSpeed Insights API.

Garry
  • 69
  • 8
  • you need to be a lot more specific in what you want here, why is the integration relevant for a start? What are you trying to achieve (and what is "desktop-friendly API" as I didn't even know that existed, do you want to add links to the relevant APIs?) and are you aware you need to run PSI twice to get a mobile and a desktop result? With regards to differentiating, what do you mean, the data returned contains a section near the bottom `"categories": {`, is that what you are looking for to know what goes where? As for passed audits the `score` is the key value for all items for pass / fail. – GrahamTheDev Feb 18 '21 at 19:20
  • Hi, I am integrating for a webpage and similar to https://developers.google.com/speed/pagespeed/insights. – Garry Feb 18 '21 at 19:25
  • `https://www.googleapis.com/pagespeedonline/v5/runPagespeed?url='.$pageurl.'&screenshot=true&strategy=desktop&key='.$key` – Garry Feb 18 '21 at 19:26
  • I am aware of that hehe. At the moment though your question is not clear and I don't know what "desktop-friendly API" is? Are you just talking about page speed insights itself? Also is `categories:{` as I said, near the bottom of the API response, what you are looking for as that details what section each thing goes in. – GrahamTheDev Feb 18 '21 at 20:03

0 Answers0