Skip to main content

Thin Python client for the SafeBrowse localhost daemon

Project description

safebrowse-client

Thin Python client for the SafeBrowse localhost daemon.

Install

pip install safebrowse-client

Example

from safebrowse_client import SafeBrowseClient

client = SafeBrowseClient("http://127.0.0.1:8787")
health = client.health()
print(health["status"])

This package is intentionally thin: policy enforcement lives in the SafeBrowse daemon.

Model-Connected Browser Template

The release package also includes a starter template for a model-connected browser agent that uses SafeBrowse while visiting normal external websites.

Generate a local copy:

from safebrowse_client import write_model_connected_browser_agent_template

path = write_model_connected_browser_agent_template("model_connected_browser_agent.py")
print(path)

Or inspect the template string directly:

from safebrowse_client import get_model_connected_browser_agent_template

print(get_model_connected_browser_agent_template())

The template is a real Python file with placeholders for:

  • your model client
  • Playwright browsing
  • SafeBrowse observation checks
  • SafeBrowse action gating before external navigation
  • example public sites such as https://arxiv.org and https://docs.python.org

Repository:

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

safebrowse_client-0.1.3.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

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

safebrowse_client-0.1.3-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file safebrowse_client-0.1.3.tar.gz.

File metadata

  • Download URL: safebrowse_client-0.1.3.tar.gz
  • Upload date:
  • Size: 6.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for safebrowse_client-0.1.3.tar.gz
Algorithm Hash digest
SHA256 cde48cf0ae039843c77c98cfef7a31e016ac70b7124b82cb7fe402ec6708910c
MD5 b47bf097ea4f94b1cfaf9663abaf898b
BLAKE2b-256 90f3a44377938df6bdc21d82fe450007bb6bbcedcd22e40934e4dd223f915bd7

See more details on using hashes here.

File details

Details for the file safebrowse_client-0.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for safebrowse_client-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 342d5217c9170fc9fbf5c70e28e7e39b22e9f4cba9ba306d0386454fb594aedc
MD5 2ff6d377d4965e6847f78371b138a5a3
BLAKE2b-256 f85090b5e84558469b421a67ebe413b361329ac7122a1a98404c42c3bd5739d5

See more details on using hashes here.

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