flowa-browser-mcp 2.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. flowa_browser_mcp-2.0.0/.gitignore +8 -0
  2. flowa_browser_mcp-2.0.0/CHANGELOG.md +35 -0
  3. flowa_browser_mcp-2.0.0/CONTRIBUTING.md +9 -0
  4. flowa_browser_mcp-2.0.0/LICENSE +202 -0
  5. flowa_browser_mcp-2.0.0/NOTICE +6 -0
  6. flowa_browser_mcp-2.0.0/PKG-INFO +211 -0
  7. flowa_browser_mcp-2.0.0/README.md +180 -0
  8. flowa_browser_mcp-2.0.0/README.pt-BR.md +25 -0
  9. flowa_browser_mcp-2.0.0/SECURITY.md +22 -0
  10. flowa_browser_mcp-2.0.0/flowa_browser/__init__.py +1 -0
  11. flowa_browser_mcp-2.0.0/flowa_browser/api.py +1737 -0
  12. flowa_browser_mcp-2.0.0/flowa_browser/auditoria.py +63 -0
  13. flowa_browser_mcp-2.0.0/flowa_browser/cli.py +282 -0
  14. flowa_browser_mcp-2.0.0/flowa_browser/config.py +142 -0
  15. flowa_browser_mcp-2.0.0/flowa_browser/mcp.py +214 -0
  16. flowa_browser_mcp-2.0.0/flowa_browser/texto.py +260 -0
  17. flowa_browser_mcp-2.0.0/pyproject.toml +52 -0
  18. flowa_browser_mcp-2.0.0/skills/flowa-browser/SKILL.md +25 -0
  19. flowa_browser_mcp-2.0.0/tests/ambiente.py +105 -0
  20. flowa_browser_mcp-2.0.0/tests/apoio/__init__.py +1 -0
  21. flowa_browser_mcp-2.0.0/tests/apoio/navegador.py +78 -0
  22. flowa_browser_mcp-2.0.0/tests/apoio/servidor.py +196 -0
  23. flowa_browser_mcp-2.0.0/tests/conftest.py +79 -0
  24. flowa_browser_mcp-2.0.0/tests/paginas/arquivo-escondido.html +11 -0
  25. flowa_browser_mcp-2.0.0/tests/paginas/arrastar.html +15 -0
  26. flowa_browser_mcp-2.0.0/tests/paginas/editores.html +11 -0
  27. flowa_browser_mcp-2.0.0/tests/paginas/foco-desviado.html +10 -0
  28. flowa_browser_mcp-2.0.0/tests/paginas/foco.html +23 -0
  29. flowa_browser_mcp-2.0.0/tests/paginas/formulario.html +15 -0
  30. flowa_browser_mcp-2.0.0/tests/paginas/iframe-dentro.html +4 -0
  31. flowa_browser_mcp-2.0.0/tests/paginas/iframes.html +7 -0
  32. flowa_browser_mcp-2.0.0/tests/paginas/lista-longa.html +404 -0
  33. flowa_browser_mcp-2.0.0/tests/paginas/lista-sem-papel.html +11 -0
  34. flowa_browser_mcp-2.0.0/tests/paginas/login.html +11 -0
  35. flowa_browser_mcp-2.0.0/tests/paginas/marcar-opcao-campos.html +38 -0
  36. flowa_browser_mcp-2.0.0/tests/paginas/marcar-opcao-rolagem.html +23 -0
  37. flowa_browser_mcp-2.0.0/tests/paginas/marcar-opcao-variantes.html +74 -0
  38. flowa_browser_mcp-2.0.0/tests/paginas/marcar-opcao.html +38 -0
  39. flowa_browser_mcp-2.0.0/tests/paginas/moldura.html +4 -0
  40. flowa_browser_mcp-2.0.0/tests/paginas/opcao-longa.html +4 -0
  41. flowa_browser_mcp-2.0.0/tests/paginas/partido.html +9 -0
  42. flowa_browser_mcp-2.0.0/tests/paginas/rede.html +9 -0
  43. flowa_browser_mcp-2.0.0/tests/paginas/rotulo.html +20 -0
  44. flowa_browser_mcp-2.0.0/tests/paginas/seguranca.html +17 -0
  45. flowa_browser_mcp-2.0.0/tests/paginas/sensivel-acento.html +8 -0
  46. flowa_browser_mcp-2.0.0/tests/paginas/sensivel.html +9 -0
  47. flowa_browser_mcp-2.0.0/tests/paginas/sobreposto.html +10 -0
  48. flowa_browser_mcp-2.0.0/tests/paginas/spa.html +7 -0
  49. flowa_browser_mcp-2.0.0/tests/paginas/teclado.html +18 -0
  50. flowa_browser_mcp-2.0.0/tests/test_flowa_browser.py +498 -0
  51. flowa_browser_mcp-2.0.0/tests/test_marcar_opcao_portas.py +25 -0
  52. flowa_browser_mcp-2.0.0/tests/test_marcas_e_prazo.py +214 -0
  53. flowa_browser_mcp-2.0.0/tests/test_pagina_atual.py +87 -0
  54. flowa_browser_mcp-2.0.0/tests/test_seguranca.py +407 -0
@@ -0,0 +1,8 @@
1
+ .venv/
2
+ dist/
3
+ build/
4
+ *.egg-info/
5
+ __pycache__/
6
+ *.pyc
7
+ .pytest_cache/
8
+ .DS_Store
@@ -0,0 +1,35 @@
1
+ # Changelog
2
+
3
+ ## 2.0.0
4
+
5
+ First public release.
6
+
7
+ - Page as numbered accessibility tree, actions by number, report of what changed.
8
+ - Safety checks (not a security boundary): changed or covered items, sensitive actions, passwords, page text as data.
9
+ - `marcar_opcao` and `clicar_texto` for controls that are not in the reading.
10
+ - Network, console, emulation, performance, styles, drag and Lighthouse audit.
11
+ - MCP server `flowa-browser-mcp` and `flowa-browser` command.
12
+ - Pre-release security review: confirmation also for checkboxes, Enter/Space, drag and text clicks; password origin checked per frame and masked in network and console output; uploads limited to one folder.
13
+ - Fix: keyboard paths ask for the same confirmation as clicks. Keys are checked against the element that really has the focus (also inside closed shadow roots and same-process frames), an item with no visible area is activated only by the key that matches it, arrow keys check the radio group, and clicking a label checks its field.
14
+ - Accepting a confirm or prompt dialog about a sensitive action, and Delete or Backspace (also through `limpar`) outside a text field, now need confirmation.
15
+ - Fix: the dedicated browser reopens after it was closed, and one already running is adopted even without its port file; another program holding the port is not trusted.
16
+ - `rede` shows the requests of the current page; `historico` (CLI `--historico`) brings the earlier ones.
17
+ - A click that lands on the item's own label counts as a hit (not on a link, button or click handler inside it); a click that would land on the page background is now refused.
18
+ - A browser timeout is reported as a clear message instead of a Python traceback.
19
+ - Quick browser calls, including clicks and typing, wait up to 15 s (was 5 s), so a loaded computer no longer makes them fail.
20
+ - Every MCP tool has a title and read-only or destructive hints.
21
+ - Request and response bodies returned by `rede` hide the value of fields named like a secret (password, token, API key, card number and security code), including passwords the owner typed by hand. The match is by field name, in JSON, form and multipart bodies.
22
+ - Half of a split character coming from a page (as in text cut by length) no longer makes opening or reading it fail, or crashes the MCP server.
23
+ - A line separator character from a page in a console message no longer corrupts the log that `rede` and `console` read.
24
+ - Control characters from a page (terminal escape sequences, null bytes, text direction overrides) are removed from MCP tool results, command output and script mode, and no longer let a sensitive button name slip past the confirmation.
25
+ - Long embedded addresses (`data:`) are cut in the network log, which was rewritten in full on every action.
26
+ - Very long options of a native list are cut at 300 characters; `escolher` accepts the cut text.
27
+ - A malformed message from an MCP client gets an error reply instead of ending the server.
28
+ - Blank or invisible characters inside a button name (Hangul fillers, empty braille, private use, enclosing marks) no longer let it slip past the confirmation.
29
+ - A failure to open the dedicated browser is returned as an error instead of ending the MCP server.
30
+ - Calls running at the same time no longer read a half-written page state or log.
31
+ - Calls running at the same time no longer drop network and console records from the log.
32
+ - The control characters U+001C to U+001F and U+0085 inside a button name neither split nor join words before the confirmation check. A thin space inside a word, like look-alike letters, is still not covered.
33
+ - Fix: text no longer lands in a password field when the page moves the focus, or turns the field into a password field, before the text is sent; a page that moves the focus or changes the field while the text is being sent can still redirect it (see SECURITY.md); text is sent only when the focused element accepts text, whoever has the focus passes the same checks, and `senha` types only into the requested field.
34
+ - A very long address in a console message origin is cut.
35
+ - `abrir` refuses `file://` addresses unless `FLOWA_BROWSER_ALLOW_FILES=1` is set.
@@ -0,0 +1,9 @@
1
+ # Contributing
2
+
3
+ 1. Open an issue describing the problem or idea.
4
+ 2. Fork, create a branch, and add a test that shows the change.
5
+ 3. Run `python -m pytest` on macOS with Google Chrome installed.
6
+ 4. Open a pull request. Only maintainers merge.
7
+
8
+ Keep the safety checks: changes that weaken them need a discussion first. Be respectful; see [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md).
9
+ By contributing you agree that your contribution is licensed under Apache-2.0.
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -0,0 +1,6 @@
1
+ Flowa Browser MCP
2
+ Copyright 2026 Flowa Labs
3
+
4
+ The icon uses the "water-flow" glyph from Material Design Icons (Pictogrammers), Apache License 2.0.
5
+
6
+ This product depends on browser-harness (MIT License), https://github.com/browser-use/browser-harness
@@ -0,0 +1,211 @@
1
+ Metadata-Version: 2.5
2
+ Name: flowa-browser-mcp
3
+ Version: 2.0.0
4
+ Summary: MCP server and CLI that lets AI agents control a browser as text: reads pages as a numbered accessibility tree, without screenshots, with safety checks.
5
+ Project-URL: Homepage, https://github.com/flowa-labs/flowa-browser-mcp
6
+ Project-URL: Repository, https://github.com/flowa-labs/flowa-browser-mcp
7
+ Project-URL: Documentation, https://flowa-labs.github.io/flowa-browser-mcp/
8
+ Project-URL: Issues, https://github.com/flowa-labs/flowa-browser-mcp/issues
9
+ Project-URL: Changelog, https://github.com/flowa-labs/flowa-browser-mcp/blob/main/CHANGELOG.md
10
+ Author: Flowa Labs
11
+ License-Expression: Apache-2.0
12
+ License-File: LICENSE
13
+ License-File: NOTICE
14
+ Keywords: accessibility-tree,ai-agents,browser-automation,cdp,mcp,model-context-protocol,token-efficient,web-automation
15
+ Classifier: Development Status :: 4 - Beta
16
+ Classifier: Environment :: Console
17
+ Classifier: Intended Audience :: Developers
18
+ Classifier: Natural Language :: Portuguese (Brazilian)
19
+ Classifier: Operating System :: MacOS
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Programming Language :: Python :: 3.14
23
+ Classifier: Topic :: Internet :: WWW/HTTP :: Browsers
24
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
25
+ Classifier: Topic :: Software Development :: Libraries
26
+ Requires-Python: >=3.12
27
+ Requires-Dist: browser-harness==0.1.15
28
+ Provides-Extra: dev
29
+ Requires-Dist: pytest>=8; extra == 'dev'
30
+ Description-Content-Type: text/markdown
31
+
32
+ <!-- mcp-name: io.github.flowa-labs/flowa-browser-mcp -->
33
+
34
+ <p align="center"><img src="https://raw.githubusercontent.com/flowa-labs/flowa-browser-mcp/main/assets/icon.png" width="96" alt="Flowa Browser MCP icon"></p>
35
+
36
+ <h1 align="center">Flowa Browser MCP: token-efficient browser control for AI agents</h1>
37
+
38
+ <p align="center">An MCP server and CLI that reads web pages as a numbered accessibility tree and acts by item number.<br>Reads pages without screenshots. Heuristic safety checks on by default; they are not a security boundary.</p>
39
+
40
+ <p align="center">
41
+ <a href="https://github.com/flowa-labs/flowa-browser-mcp/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-Apache--2.0-blue" alt="Apache-2.0"></a>
42
+ <a href="https://github.com/flowa-labs/flowa-browser-mcp/actions/workflows/ci.yml"><img src="https://github.com/flowa-labs/flowa-browser-mcp/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
43
+ <img src="https://img.shields.io/badge/python-3.12%2B-blue" alt="Python 3.12+">
44
+ </p>
45
+
46
+ <p align="center"><a href="https://github.com/flowa-labs/flowa-browser-mcp/blob/main/README.pt-BR.md">Português</a></p>
47
+
48
+ If you are comparing browser tools for agents (Playwright MCP, Chrome DevTools MCP, agent-browser, Obscura), see the [measured comparison](#benchmarks) below.
49
+
50
+ ## How it works
51
+
52
+ ```mermaid
53
+ flowchart LR
54
+ A[AI agent<br>MCP client or shell] -->|open / read / act| B[Flowa Browser]
55
+ B -->|page as numbered text| A
56
+ B --> C{Safety checks}
57
+ C -->|item changed or covered| X[Refuse and explain]
58
+ C -->|pay, delete, send| Y["Refuse until confirmado=true"]
59
+ C -->|ok| D[browser-harness<br>Chrome DevTools Protocol]
60
+ D --> E[Google Chrome<br>dedicated profile or your own]
61
+ E -->|only what changed| B
62
+ ```
63
+
64
+ A page reads like this (output is currently in Portuguese):
65
+
66
+ ```text
67
+ [1] campo "Nome"
68
+ [2] campo "E-mail"
69
+ [3] lista "Estado"
70
+ [4] caixa "Aceito os termos"
71
+ [5] botão "Salvar"
72
+ ```
73
+
74
+ ## Quick start
75
+
76
+ Requirements: **macOS** (the only tested system), **Google Chrome**, **Python 3.12+**. Install it in an isolated environment (`uv tool` or `pipx`).
77
+
78
+ ```bash
79
+ uv tool install flowa-browser-mcp # or: pipx install flowa-browser-mcp
80
+ claude mcp add --scope user flowa-browser -- flowa-browser-mcp
81
+ ```
82
+
83
+ Any MCP client that runs a stdio server can use it:
84
+
85
+ ```json
86
+ { "mcpServers": { "flowa-browser": { "command": "flowa-browser-mcp" } } }
87
+ ```
88
+
89
+ Or from the shell:
90
+
91
+ ```bash
92
+ flowa-browser abrir https://example.com # open and read
93
+ flowa-browser agir 3 clicar # act on item 3
94
+ flowa-browser ler --busca "price" # read again, filtered
95
+ flowa-browser --help
96
+ ```
97
+
98
+ ## Tools
99
+
100
+ Tool names and messages are in Portuguese in this version.
101
+
102
+ | Tool | What it does |
103
+ |---|---|
104
+ | `abrir` | open a URL and return the page as text |
105
+ | `ler` | read the page (search, modes, pagination, only changes) |
106
+ | `agir` | act on item N: click, fill, choose, check, upload |
107
+ | `lote` | several actions in one call (a whole form) |
108
+ | `tecla` | press a key; with an item number, focuses that item first (the number is not a repeat count) |
109
+ | `clicar_texto` | click a visible element by its exact text |
110
+ | `marcar_opcao` | answer a radio or checkbox that is not in the reading |
111
+ | `arrastar` | drag item to item |
112
+ | `dialogo` | answer alert, confirm or prompt |
113
+ | `abas`, `usar_aba`, `fechar_aba`, `voltar`, `recarregar`, `soltar` | tabs and history |
114
+ | `rede`, `console` | network calls and console errors |
115
+ | `emular`, `desempenho`, `estilos` | device and network emulation, load metrics, CSS |
116
+ | `auditar` | Lighthouse audit (needs Node.js; dedicated browser only) |
117
+
118
+ ## Safety
119
+
120
+ - **Pressing Enter in a chat box** (a textarea or editable area, even inside a form, as in web messengers) can send a message without confirmation: the word list cannot tell it apart from a new line.
121
+ - **Changed items are refused, and so are clicks on covered items,** instead of clicking blindly. Drag and items inside iframes are not covered-checked, and a malicious page can defeat this check.
122
+ - **Sensitive actions** (pay, buy, delete, send, publish, transfer) are recognised by a word list on clicks, checkboxes, Enter and Space, arrow keys on radio groups, accepting a confirm or prompt dialog, drag, text clicks and `marcar_opcao` answers (not on choosing an option in a native list). Key presses are checked against the element that really has the focus, and Delete or Backspace outside a text field always count as sensitive. Such calls are refused unless they carry `confirmado=true`. That flag is set by the agent: the tool cannot verify that you approved, so configure your MCP client to ask before such calls.
123
+ - **Passwords:** the agent is refused when it tries to type into a password field; a page that moves the focus or changes the field while the text is being sent can still redirect it (see SECURITY.md). The `senha` action types a value only on an origin listed in `~/.config/flowa-browser-mcp/senhas.json`, checked for the frame that holds the field; the value comes from the `.env` file that entry points to. Listed values of 4 or more characters are masked in readings, network and console output (a value cut by truncation may show partially). Keep both files at `chmod 600`.
124
+ - **Secrets in network bodies:** request and response bodies hide fields named like a secret (password, token, API key, card number and security code) in JSON, form and multipart, including a password you typed by hand. The match is by field name, so treat these bodies as sensitive anyway.
125
+ - **Local files:** `abrir` refuses `file://` unless you set `FLOWA_BROWSER_ALLOW_FILES=1`.
126
+ - **File uploads** need confirmation and only accept files inside `~/.config/flowa-browser-mcp/uploads` (default; `FLOWA_BROWSER_UPLOAD_DIR` or `FLOWA_BROWSER_HOME` changes it).
127
+ - **Page text is data, not instructions:** readings, tabs, network, console and the list of changes in action reports are wrapped in markers with a random code. Item names quoted in a report's first line, error and dialog messages, and the output of `estilos`, `desempenho` and `auditar` are site data outside those markers.
128
+ - The engine's telemetry, update checks and cloud features are disabled.
129
+ - Running your own Python script through the command (`flowa-browser <<'PY'`) bypasses every check.
130
+
131
+ These checks reduce risk; they are not a sandbox. See [SECURITY.md](https://github.com/flowa-labs/flowa-browser-mcp/blob/main/SECURITY.md).
132
+
133
+ ## Two browsers
134
+
135
+ | | Dedicated browser (default) | `--real` |
136
+ |---|---|---|
137
+ | What | separate window and profile | your everyday Chrome |
138
+ | Logins | saved in that profile | the ones you already have |
139
+ | Permission | none; the debugging port on 127.0.0.1 is reachable by any local process | Chrome asks to allow remote debugging |
140
+
141
+ For the MCP server, set `FLOWA_BROWSER_REAL=1` to use your everyday browser.
142
+
143
+ ## Benchmarks
144
+
145
+ Five scripted tasks (full form, button behind a banner, item at the end of a 400-row list, field inside a cross-origin iframe, dialog followed by a page change) on local test pages. Tokens are estimated as characters / 3.5.
146
+
147
+ | Tool (run of 2026-11-26) | Tasks passed | Calls | Text returned (tokens) |
148
+ |---|---|---|---|
149
+ | **Flowa Browser** | 5 / 5 | **22** | **6,637** |
150
+ | agent-browser 0.45.0 | 5 / 5 | 27 | 8,810 |
151
+ | Chrome DevTools MCP 1.14.0 | 5 / 5 | 28 | 15,760 |
152
+ | Playwright MCP | 5 / 5 | 38 | 21,702 |
153
+
154
+ | Tool (run of 2026-11-29, 7 rounds) | Tasks passed | Calls per round | Text per round (tokens) |
155
+ |---|---|---|---|
156
+ | **Flowa Browser** | **35 / 35** | **22** | **7,465** |
157
+ | Obscura 0.2.7 | 28 / 35 | 25 | 12,957 |
158
+
159
+ ### Forms: fewest calls
160
+
161
+ | Full form task (2026-11-26) | Calls | Text returned (tokens) |
162
+ |---|---|---|
163
+ | **Flowa Browser** | **2** | **261** |
164
+ | agent-browser 0.45.0 | 8 | 332 |
165
+ | Chrome DevTools MCP 1.14.0 | 8 | 1,456 |
166
+ | Playwright MCP | 11 | 1,623 |
167
+
168
+ All four completed the form. `lote` fills it and submits in a single action call.
169
+
170
+ ### Why it is slower
171
+
172
+ **Where it loses:** agent-browser and Obscura are clearly faster, Obscura uses far less memory and returned less text on small pages.
173
+
174
+ - **It checks before and after acting:** waits for the item to stop moving, checks that nothing covers it, waits for the page to settle and reports what changed. The raw browser calls for one action took about 9 ms in our measurement; in the same run, on a heavily loaded machine, a checked action took about 790 ms (median).
175
+ - **It drives a full browser:** that costs memory (about 300 to 340 MB in total, with Chrome's 283 MB measured and the Python part estimated, against about 24 MB for Obscura) and is why cross-origin iframes and your logged-in sessions work. agent-browser drove the same Chrome and was still several times faster, so most of the speed gap is our checks and implementation, which can still be improved. Method, limits and the main numbers: [docs/benchmarks.md](https://github.com/flowa-labs/flowa-browser-mcp/blob/main/docs/benchmarks.md).
176
+
177
+ ## Comparisons published by others
178
+
179
+ Measured by the authors of each project. **We did not run them, and Flowa Browser is not part of any of them.** Dates are theirs; the Obscura README gives no date.
180
+
181
+ | Source | What they compared | What they report |
182
+ |---|---|---|
183
+ | [browser-harness](https://github.com/browser-use/browser-harness#compared-with-other-browser-tools) (2026-10-14) | its CLI, Playwright MCP, Chrome DevTools MCP, agent-browser on 100 tasks, one run each | no tool wins on score (56.3 to 61.0; every paired difference with the harness has a 95% CI that includes zero); the harness had the lowest median input tokens |
184
+ | [charlotte](https://github.com/TickTockBent/charlotte#benchmarks) (2026-08-08) | charlotte and Playwright MCP, characters returned on real sites | 1.1x to 139x smaller on arrival at a page |
185
+ | [caveman-browse](https://github.com/JuliusBrussee/caveman-browse) (2026-08-14) | tool definitions of caveman-browse, Playwright MCP, Chrome DevTools MCP | 297, 3,422 and 4,507 tokens; its own task pilot shows a case it loses |
186
+ | [Obscura](https://github.com/h4ckf0r0day/obscura#benchmarks) | page load, Obscura and Chrome | 51 to 84 ms against about 500 to 800 ms |
187
+
188
+ Flowa Browser runs on the browser-harness engine, but the evaluation above measured the harness's own interface, not this one.
189
+
190
+ ## Tests
191
+
192
+ 103 tests, most of them end-to-end against an isolated headless browser: reading, actions, iframes, dialogs, network, console, emulation, tabs, safety checks and password handling.
193
+
194
+ ```bash
195
+ uv venv && uv pip install -e ".[dev]" && .venv/bin/python -m pytest
196
+ ```
197
+
198
+ ## Limitations
199
+
200
+ - Only macOS is tested. Linux is untested; Windows does not work in this version (the command uses the Unix-only `fcntl` module).
201
+ - Tool names, messages and page markers are in Portuguese.
202
+ - Pages drawn on canvas have no accessibility tree to read.
203
+ - Callers that share a tab share its state. Callers with the same owner share one tab and its state, whether MCP server or command. The owner is `FLOWA_BROWSER_OWNER`, else the Claude Code session id, else `flowa-browser`: give each parallel server or command caller its own value. Agents that use the same MCP server share its tab.
204
+
205
+ ## Contributing and license
206
+
207
+ Issues and pull requests are welcome; see [CONTRIBUTING.md](https://github.com/flowa-labs/flowa-browser-mcp/blob/main/CONTRIBUTING.md). Changes are merged only after maintainer review.
208
+
209
+ Licensed under [Apache-2.0](https://github.com/flowa-labs/flowa-browser-mcp/blob/main/LICENSE). Built on [browser-harness](https://github.com/browser-use/browser-harness) (MIT).
210
+
211
+ Not affiliated with or endorsed by Google, Microsoft, Vercel, Anthropic or the authors of the compared tools. Product names belong to their owners.