Skip to main content

⚡ High-performance Python proxy server with authentication, load balancing, caching, and multi-protocol support

Project description

ProxyCraft

ProxyCraft is the easiest and quickest way to deploy a web proxy.


License Python Build Status Version

HTTP HTTPS WebSocket SOCKS5 TCP/UDP


✨ Features

ProxyCraft offers many features:

  • 🔒 Protocol Support: Handle HTTP, HTTPS, WebSockets, TCP/UDP, and SOCKS proxies
  • 🔐 Authentication: Support for various auth methods (Basic, Digest, NTLM, Kerberos)
  • 🔄 Connection Pooling: Efficient reuse of connections to improve performance
  • ⚖️ Load Balancing: Distribute traffic across multiple proxies
  • 🏥 Health Checking: Automatic detection and recovery from failed proxies
  • 💾 Caching: Store and reuse responses for identical requests
  • 🔄 Retry Mechanisms: Automatically retry failed requests
  • 🔧 Circuit Breaking: Prevent cascading failures
  • 📊 Metrics Collection: Track proxy performance, latency, error rates
  • 🔐 TLS/SSL Termination: Handle encryption/decryption
  • 🌍 IP Rotation: Change public IP addresses for scraping
  • 🎯 Geo-targeting: Route requests through proxies in specific locations

🚀 Quick Start

Installation

pip install proxycraft

Or with uv:

uv add proxycraft

Basic Usage

from proxycraft import ProxyCraft

if __name__ == "__main__":
    proxycraft: ProxyCraft = ProxyCraft(config_file='proxy.json')
    proxycraft.serve(host='0.0.0.0', port=8091)

📋 Configuration Example

{
  "version": "1.0",
  "name": "Simple example",
  "endpoints": [
    {
      "prefix": "/",
      "match": "**/*",
      "backends": {
        "https": {
          "url": "https://jsonplaceholder.typicode.com/posts"
        }
      },
      "upstream": {
        "proxy": {
          "enabled": true
        }
      }
    }
  ]
}

🐳 Docker Usage

docker build -t proxycraft -f dockerfiles/proxycraft.Dockerfile .
docker run  -p 8080:8080 proxycraft

📄 License

Business Source License 1.1

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

proxycraft-1.0.0.tar.gz (132.3 kB view details)

Uploaded Source

Built Distribution

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

proxycraft-1.0.0-py3-none-any.whl (71.4 kB view details)

Uploaded Python 3

File details

Details for the file proxycraft-1.0.0.tar.gz.

File metadata

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

File hashes

Hashes for proxycraft-1.0.0.tar.gz
Algorithm Hash digest
SHA256 81650f928b07319e99113f766694a35fa834db2848d5c6d0452ae56bd322d525
MD5 336558a76da014d742891e830662f51d
BLAKE2b-256 6f81f722446e2a5e9552bab9756de16f3f185b37596400d2fd91122d6bb0095a

See more details on using hashes here.

File details

Details for the file proxycraft-1.0.0-py3-none-any.whl.

File metadata

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

File hashes

Hashes for proxycraft-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b5b852e28c61fbe16127804fd7c44634d6f640b5943d9255e20ffb62ef2ed3a5
MD5 78089dc2130d0d4e3e3300ce2e4c425a
BLAKE2b-256 96b13e3d49019c66b815a0fea15de95c03431406fb4a1feb9d972c6264afc226

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