Skip to main content

CLI for making requests and searching the web

Project description

go2web

PyPI version

CLI for making requests and searching the web

go2web demo


Features

  • go2web fetch <url> — makes a raw HTTP/HTTPS request (no third-party library) and prints a clean, human-readable result inside a styled panel
  • go2web search <query> — searches Bing and presents an interactive picker; select a result to immediately fetch and display it
  • Smart content rendering — strips HTML tags, pretty-prints JSON, passes plain text through unchanged
  • Transparent redirect following — each hop is logged to stderr so you always see where you end up
  • Local response cache — responses are cached to ~/.go2web_cache.json for 30 s, with Cache-Control: no-store/no-cache respected
  • Usable as a libraryHTTPClient, CacheStore, ParserManager and search engines are all importable

Installation

go2web is a standalone CLI tool. Install it globally so it's available everywhere — no virtual environment needed.

# Recommended — uv (fastest, isolated)
uv tool install go2web

# pipx (isolated, widely available)
pipx install go2web

# pip (global, no isolation)
pip install go2web

Requires Python 3.12+. See full installation docs.

Tip: uv tool install and pipx install both create an isolated environment for go2web so it never conflicts with your project dependencies.


Quick start

go2web fetch https://example.com
go2web search python asyncio tutorial

CLI usage

go2web --help                       # show help
go2web fetch <URL>                  # fetch a URL and print human-readable output
go2web search <term …>              # search the web and pick a result interactively

The https:// scheme prefix is optional — go2web adds it automatically.

go2web fetch example.com            # same as https://example.com
go2web search "best pizza recipes"

See full CLI & usage docs.


Using as a library

go2web can also be used as a Python library. Add it to your project:

uv add go2web   # or: pip install go2web
from go2web.http.client import HTTPClient
from go2web.http.parsers.parser_manager import ParserManager

client = HTTPClient()
response = client.get("https://httpbin.org/json")

parser = ParserManager().get_parser(response.get_content_type())
print(parser.parse(response.body))

See API reference.


Documentation

Built with Zensical and deployed to GitHub Pages.

Live docs https://m33ga.github.io/go2web/
Local preview just docs-servehttp://localhost:8000
Build just docs-build

Development

git clone https://github.com/m33ga/go2web
cd go2web
uv tool install --editable .   # installs CLI with live updates

uv run pytest                  # tests
just qa                        # format + lint + type check + test

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

go2web-0.2.0.tar.gz (275.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

go2web-0.2.0-py3-none-any.whl (21.3 kB view details)

Uploaded Python 3

File details

Details for the file go2web-0.2.0.tar.gz.

File metadata

  • Download URL: go2web-0.2.0.tar.gz
  • Upload date:
  • Size: 275.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for go2web-0.2.0.tar.gz
Algorithm Hash digest
SHA256 837e71b672828022b6f37537df364cfc0f28043676a9ac70553ea69c2b86f3c3
MD5 ffcc3a248048ba627c82784964bbdc2e
BLAKE2b-256 2ed9fbe3dc6d1d5e557d124915dfbf7ba51de017597a156a4828cc23714b0ee7

See more details on using hashes here.

Provenance

The following attestation bundles were made for go2web-0.2.0.tar.gz:

Publisher: publish.yml on m33ga/go2web

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file go2web-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: go2web-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 21.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for go2web-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 80e7156a277712091bdc0e88da304dfc36ab9a5ce4327b84b230beffff8adbca
MD5 e304048df021c2529365739b619f8711
BLAKE2b-256 2bd0c339ef75b1f9f2bbeba44f9ceba74990505998536bd0adeac73777a7a761

See more details on using hashes here.

Provenance

The following attestation bundles were made for go2web-0.2.0-py3-none-any.whl:

Publisher: publish.yml on m33ga/go2web

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page