[英]can I access to network tab of google chrome developer tools with python?
I tried to get some information in a request in some web pages and I need some information that can find it from network tab of google chrome developer tools for example when I click on followers on Instagram web, the browser sends a GET method with a parameter named "query_id", I want to find it, I can find it in network tab in google chrome dev tools but now I want to find this parameter with python, how can I do it?我试图在某些网页的请求中获取一些信息,并且我需要一些可以从 google chrome 开发者工具的网络选项卡中找到它的信息,例如当我点击 Instagram 网站上的关注者时,浏览器会发送一个带有参数的 GET 方法名为“query_id”,我想找到它,我可以在谷歌浏览器开发工具的网络选项卡中找到它,但现在我想用python找到这个参数,我该怎么做? is there any way that I access network tab with python?有什么办法可以用python访问网络选项卡吗?
Would a Node.js solution work instead? 可以使用Node.js解决方案吗? Puppeteer may help you accomplish this task. 木偶可能会帮助您完成此任务。
If not, search around for Python libraries that interact with the Chrome DevTools Protocol . 如果不是,请搜索与Chrome DevTools协议交互的Python库。 This protocol gives you a lot of low-level information about pages. 该协议为您提供了许多有关页面的底层信息。
I used Selenium to do this.我使用硒来做到这一点。 Try logging the performance and find the information you used to find in the network tab.尝试记录性能并在网络选项卡中查找您以前查找的信息。
Check out this answer below:在下面查看这个答案:
https://stackoverflow.com/a/68363046/8491363 https://stackoverflow.com/a/68363046/8491363
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.