We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
这里以自动化操作百度搜索为例子:
我们要做的是在百度输入框中填写 Python 字符串,然后点击搜索这个流程。
Python
[ { "component": "request", // 组件名称 "args": { // 参数集合,所有的组件-方法所需要的参数 "url": "https://www.baidu.com" }, "type": "browser" // 组件的方法,可以不写,默认是 `default` }, { "component": "input", "args": { "xpath": "//input[@id='kw']", "text": "Python" }, "type": "text" }, { "component": "click", "args": { "xpath": "//input[@id='su']" } }, { "component": "sleep", "args": { "time": 3600 } } ]
然后我们进入到 titans 目录下执行如下命令:
titans
python entry.py --type=common --name=common
然后我们就可以观察到整个浏览器自动化的流程了。