diff --git a/.env.example b/.env.example index 01aa740..24cddd9 100644 --- a/.env.example +++ b/.env.example @@ -1,3 +1,8 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry - https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + # ── Pry Configuration ── # Copy this to .env and adjust values. # All PRY_* vars are auto-loaded by PrySettings. diff --git a/.forgejo/ISSUE_TEMPLATE/bug.yml b/.forgejo/ISSUE_TEMPLATE/bug.yml index 00b60d2..d5f99eb 100644 --- a/.forgejo/ISSUE_TEMPLATE/bug.yml +++ b/.forgejo/ISSUE_TEMPLATE/bug.yml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. name: Bug Report description: Report a defect or unexpected behavior title: "[Bug]: " diff --git a/.forgejo/ISSUE_TEMPLATE/config.yml b/.forgejo/ISSUE_TEMPLATE/config.yml index 0a7334f..37e74ff 100644 --- a/.forgejo/ISSUE_TEMPLATE/config.yml +++ b/.forgejo/ISSUE_TEMPLATE/config.yml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. blank_issues_enabled: false contact_links: - name: Q&A diff --git a/.forgejo/ISSUE_TEMPLATE/feature.yml b/.forgejo/ISSUE_TEMPLATE/feature.yml index c9b206d..826d005 100644 --- a/.forgejo/ISSUE_TEMPLATE/feature.yml +++ b/.forgejo/ISSUE_TEMPLATE/feature.yml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. name: Feature Request description: Propose a new feature or improvement title: "[Feature]: " diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml index 3c88c43..b458188 100644 --- a/.forgejo/workflows/ci.yml +++ b/.forgejo/workflows/ci.yml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. name: CI on: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fe87f63..2076b16 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. name: CI on: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ec76882..6f89d75 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. repos: - repo: https://github.com/astral-sh/ruff-pre-commit rev: v0.11.0 diff --git a/AGENTS.md b/AGENTS.md index 672c1fb..6d68a13 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # AGENTS.md — PryScraper > AI agent contract. Read this before touching anything in this repo. @@ -6,7 +8,7 @@ canonical · owner=crmuncher · last_updated=2026-07-02 ## What This Repo Is -Multi-source crypto intelligence crawler (munchcrawl). Scraper, extractor, parser, automator, job queue. CLI + MCP server + SDK. +Multi-source crypto intelligence crawler (munchcrawl). Scraper, extractor, parser, automator, job queue. CLI + MCP server + SDK. License: Dual -- MIT (core) + BSL 1.1 (stealth/anti-detection subset). See LICENSE and LICENSE-BSL-STEALTH. ## Type `backend` · language=Python 3.12 + FastAPI @@ -40,6 +42,7 @@ Multi-source crypto intelligence crawler (munchcrawl). Scraper, extractor, parse 5. **No duplicate scaffolds.** If a `backend/` or `frontend/` subdir exists at root, it's either THE app or bloat. 6. **Update STATUS.md before committing.** Builders must know where we are. 7. **Read DECISIONS.md before architectural changes.** Don't repeat rejected designs. +8. **Respect dual licensing.** When contributing, the core/ files are MIT (any PR welcome). The stealth/ files (listed in LICENSE-BSL-STEALTH) are BSL 1.1 -- only Rug Munch Media LLC can modify them. PRs touching BSL files will be rejected. ## Commands ```bash diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index 427bcb1..eea92f5 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) --- title: Pry Architecture & Design status: canonical diff --git a/AUDIT.md b/AUDIT.md index 7a11044..7513633 100644 --- a/AUDIT.md +++ b/AUDIT.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) --- title: Pry — Brutal Honest Audit & Action Plan status: canonical diff --git a/DECISIONS.md b/DECISIONS.md index 5e39f90..b64826a 100644 --- a/DECISIONS.md +++ b/DECISIONS.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # DECISIONS.md — PryScraper > Architecture Decision Records (ADRs). Read before architectural changes. @@ -21,6 +23,7 @@ A short document capturing an important architectural decision: | Number | Title | Status | Date | |--------|-------|--------|------| | [0001](docs/adr/0001-initial-architecture.md) | Initial architecture | Accepted | 2026-07-02 | +| [0002](docs/adr/0002-dual-licensing.md) | Dual licensing: MIT (core) + BSL 1.1 (stealth) | Accepted | 2026-07-03 | ## Fleet-wide ADRs (in standards repo) - [ADR-0001: Tailscale mesh as the only perimeter](https://git.rugmunch.io/RugMunchMedia/standards/raw/branch/main/MCP-ARCHITECTURE.md) diff --git a/DEPLOYMENT.md b/DEPLOYMENT.md index 0480a94..f9743d1 100644 --- a/DEPLOYMENT.md +++ b/DEPLOYMENT.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # DEPLOYMENT.md — PryScraper > How to deploy. Build, push, restart, rollback. diff --git a/DEVELOPMENT.md b/DEVELOPMENT.md index 3ea2098..314a977 100644 --- a/DEVELOPMENT.md +++ b/DEVELOPMENT.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # DEVELOPMENT.md — PryScraper > Dev workflow. Install, code, test, commit, PR. diff --git a/FEATURES.md b/FEATURES.md index c4d1686..959090c 100644 --- a/FEATURES.md +++ b/FEATURES.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) --- title: Pry Feature Catalog status: canonical diff --git a/LICENSE b/LICENSE index 2a77433..584e651 100644 --- a/LICENSE +++ b/LICENSE @@ -1,17 +1,52 @@ -# PROPRIETARY LICENSE — Rug Munch Media LLC +MIT License -Copyright (c) 2026 Rug Munch Media LLC. All rights reserved. +Copyright (c) 2026 Rug Munch Media LLC -This software and associated documentation files (the "Software") are -PROPRIETARY and CONFIDENTIAL to Rug Munch Media LLC. +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the Software), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -UNAUTHORIZED USE, COPYING, MODIFICATION, MERGING, PUBLISHING, -DISTRIBUTING, SUBLICENSING, AND/OR SELLING COPIES OF THE SOFTWARE ARE -STRICTLY PROHIBITED WITHOUT PRIOR WRITTEN CONSENT FROM RUG MUNCH MEDIA LLC. - -For licensing inquiries: licensing@rugmunch.io -For commercial licensing: enterprise@rugmunch.io +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. \ No newline at end of file +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +================================================================================ +DUAL LICENSING NOTICE +================================================================================ +Pry is dual-licensed. Most of the codebase (the core scraping engine, extraction, +templates, MCP server, x402 payment rail, CLI, and SDK) is MIT-licensed under +the terms above. The following anti-detection / stealth components are licensed +under the Business Source License 1.1 — see LICENSE-BSL-STEALTH: + + - ultimate_scraper.py (10-tier fallback engine) + - stealth_engine.py (stealth orchestration) + - stealth_scripts/*.js (6 anti-detection JS injectors) + - camoufox_integration.py (Firefox anti-detection) + - tls_fingerprint.py (TLS fingerprint randomization) + - cookie_warmer.py (cookie pre-aging) + - behavioral_biometrics.py (behavioral mimicry) + - adaptive.py (adaptive strategy rotation) + - browser_pool.py (browser pre-warming for stealth) + - network.py (Tor / SOCKS5 routing) + - captcha_solver.py (CAPTCHA bypass) + - shadow_dom.py (stealth DOM extraction) + - lazy_load.py (human-like scroll) + - signup_automator.py (human-like signup) + - auth_connector.py (human-like login) + +Each of those files is individually marked with: + SPDX-License-Identifier: BSL-1.1 +The BSL terms apply only to those files. All other files (including all +templates/, browser-extension/, wordpress-plugin/, shopify-app/, llm_providers/, +and the bulk of api.py, mcp_production.py, x402.py) are MIT-licensed. +================================================================================ diff --git a/LICENSE-BSL-STEALTH b/LICENSE-BSL-STEALTH new file mode 100644 index 0000000..5744b37 --- /dev/null +++ b/LICENSE-BSL-STEALTH @@ -0,0 +1,68 @@ +Business Source License 1.1 + +Licensor: Rug Munch Media LLC +Licensed Work: Pry — Stealth / Anti-Detection Module + (the specific files listed in the DUAL LICENSING NOTICE + in LICENSE and individually marked with + SPDX-License-Identifier: BSL-1.1) +Change Date: 2029-01-01 +Change License: MIT License (see LICENSE) + +Additional Use Grant: + You may use the Licensed Work, without a commercial license from Rug Munch + Media LLC, for any of the following purposes: + + 1. Personal use (e.g., a developer running Pry on their own machine to + scrape sites for personal projects). + 2. Non-production testing and development (e.g., a company running Pry + in CI to test their own scrapers against anti-bot targets). + 3. Academic research and education. + 4. Development of non-commercial open source software (any project whose + source code is publicly available under an OSI-approved license and + which is not sold, licensed, or distributed for a fee). + 5. Internal evaluation by a potential customer considering a + commercial license (capped at 90 days). + + All other use — including any production deployment, any use by a + for-profit entity in the course of its business operations, any SaaS / + PaaS offering, any consulting engagement, and any redistribution as + part of a commercial product or service — requires a separate written + commercial license from Rug Munch Media LLC. + + For commercial licensing, contact: enterprise@rugmunch.io + +For full canonical text of the Business Source License 1.1, see: + https://mariadb.com/bsl11/ + +The text reproduced below is the official license template; on the Change +Date (2029-01-01) the Licensed Work converts to the MIT License (see +LICENSE). Until that date the following terms govern. + +------------------------------------------------------------------------------ +Business Source License 1.1 + +Licensor: Rug Munch Media LLC +Licensed Work: Pry — Stealth / Anti-Detection Module +Change Date: 2029-01-01 +Change License: MIT License + +Additional Use Grant: + Free for non-production personal use, non-production testing, academic + research, and development of non-commercial open source software. See + LICENSE for the full Additional Use Grant and the list of covered files. + + Production use and any use by a for-profit entity in the course of its + business requires a separate commercial license from Rug Munch Media LLC. + Contact enterprise@rugmunch.io. + +The Licensor hereby grants you the right to copy, modify, create derivative +works, redistribute, and make non-production use of the Licensed Work. The +Licensor may make an Additional Use Grant, above, permitting limited +production use. Any other use, including production use, is prohibited. + +All other rights are reserved by the Licensor. + +THE LICENSED WORK IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED. THE LICENSOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS +LICENSED WORK, INCLUDING ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. diff --git a/LICENSING_PRICING_STRATEGY.md b/LICENSING_PRICING_STRATEGY.md index d38242f..0fc52e3 100644 --- a/LICENSING_PRICING_STRATEGY.md +++ b/LICENSING_PRICING_STRATEGY.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # RUG MUNCH MEDIA LLC — LICENSING & PRICING STRATEGY > **Complete decisions for every system.** @@ -124,19 +126,20 @@ WalletPress is **THREE products** that need different strategies: --- -## 3. PRYSCRAPER — DETAILED PROFIT MODEL +## 3. PRYSCRAPER - DETAILED PROFIT MODEL -### 3.1 License: PROPRIETARY (CONFIRMED) +### 3.1 License: DUAL: MIT (core) + BSL 1.1 (stealth) **Why:** -- Competitive moat is our stealth browser, anti-detection, and bypass techniques -- If competitors see our code, they can replicate in days -- Crypto scrapers are a race — whoever has the best stealth wins +- MIT for the core scraping engine builds community, adoption, trust, stars, contributions +- BSL 1.1 protects the anti-detection/stealth moat from commercial cloning +- 15 stealth files are BSL 1.1: ultimate_scraper.py, stealth_engine.py, stealth_scripts/*.js, camoufox_integration.py, tls_fingerprint.py, cookie_warmer.py, behavioral_biometrics.py, adaptive.py, browser_pool.py, network.py, captcha_solver.py, shadow_dom.py, lazy_load.py, signup_automator.py, auth_connector.py +- The rest (100+ files) are MIT -### 3.2 Pricing — Three Models +### 3.2 Pricing - Three Models **Model A: SaaS (Primary)** -- Hosted API at `pry.dev` +- Hosted API at pry.dev - Pay-per-request with x402 micropayments - Free tier: 1,000 requests/month - Pro: $49/mo for 100K requests @@ -156,11 +159,11 @@ WalletPress is **THREE products** that need different strategies: | Endpoint | Price | |----------|-------| -| `/scrape` | $0.005/call | -| `/crawl` | $0.02/call | -| `/extract` | $0.01/call | -| `/screenshot` | $0.003/call | -| `/stealth_browser` | $0.05/minute | +| /scrape | $0.005/call | +| /crawl | $0.02/call | +| /extract | $0.01/call | +| /screenshot | $0.003/call | +| /stealth_browser | $0.05/minute | **Model C: White-label Enterprise** - Deploy PryScraper on your infrastructure @@ -182,8 +185,42 @@ WalletPress is **THREE products** that need different strategies: | White-label Enterprise | $200K | $600K | $1.2M | | **TOTAL** | **$310K** | **$1.02M** | **$2.2M** | ---- +*Plus community template contributions which increase the moat over time (unquantified but real).* +### 3.4 Stealth BSL Specifics + +**Which 15 files are BSL-covered:** +- ultimate_scraper.py +- stealth_engine.py +- stealth_scripts/*.js +- camoufox_integration.py +- tls_fingerprint.py +- cookie_warmer.py +- behavioral_biometrics.py +- adaptive.py +- browser_pool.py +- network.py +- captcha_solver.py +- shadow_dom.py +- lazy_load.py +- signup_automator.py +- auth_connector.py + +**What counts as production use:** +- Live application serving real users +- Business internal operations +- Deploying as a service for third parties + +**What does NOT count:** +- Personal use +- Non-production testing +- Academic research +- Non-commercial OSS development +- 90-day evaluation + +**Change Date:** 2029-01-01, converts to MIT + +**Commercial license:** enterprise@rugmunch.io ## 4. RMI (RUG MUNCH INTELLIGENCE) — DETAILED PROFIT MODEL ### 4.1 License: OPEN CORE (CONFIRMED) diff --git a/MCP_X402_AUDIT.md b/MCP_X402_AUDIT.md index b7c9c73..513efb3 100644 --- a/MCP_X402_AUDIT.md +++ b/MCP_X402_AUDIT.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) --- title: Pry MCP + x402 Audit & 20-Win Improvement Plan status: canonical diff --git a/PLAN.md b/PLAN.md index 276b18e..5c3bf4b 100644 --- a/PLAN.md +++ b/PLAN.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # PLAN.md — PryScraper > Current sprint. 21-day cycles per ADR-0012. @@ -6,13 +8,27 @@ current_sprint=2026-Q3-S1 · started=2026-07-01 · ends=2026-07-21 ## Sprint Goals -1. _TODO: top 1-3 goals for this sprint_ +1. DONE Re-license to dual MIT + BSL 1.1 (ADR-0002) - done 2026-07-03 +2. WIP Deploy repo to /srv/pry/ - wire the new api.py (4,668 lines, 190 endpoints) so MCP and x402 actually serve +3. WIP Wire auth - JWT/API-key middleware on the live deploy so we can monetize ## In Progress -- [ ] TODO: in-progress items +- [x] Re-license the codebase: dual MIT (core) + BSL 1.1 (stealth) +- [x] Add SPDX headers to all 300+ files +- [x] Write ADR-0002 documenting the decision +- [ ] Deploy updated api.py with MCP and x402 endpoints to /srv/pry/ +- [ ] Set PRY_X402_WALLET and PRY_X402_FACILITATOR env vars on Talos +- [ ] Run templates/validate_templates.py end-to-end, publish honest success rate ## Backlog (this sprint) -- [ ] TODO: planned items +- [ ] Migrate ~/.pry/* JSON storage to SQLite (concurrency + multi-tenant) +- [ ] Split api.py (4,668 lines) into router modules (cap 500 lines each) +- [ ] Replace 159 broad except Exception with specific types + add ruff BLE001 +- [ ] Surface proxy_referrals.py and referrals.py in /v1/referrals API +- [ ] Publish browser extension (Chrome Web Store) and WordPress plugin (wordpress.org) +- [ ] Deploy Cloudflare Worker mcp-worker.js so MCP server is publicly hosted +- [ ] Register on Smithery, Glama, PulseMCP MCP directories +- [ ] Build pry.dev landing page with comparison table (Pry vs Firecrawl vs ScrapingBee) ## Risks - TODO: anything blocking progress diff --git a/README.md b/README.md index 8080cc8..62efc01 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # Pry — Open any website Self-hosted web scraping + browser automation API. Cloudflare bypass, document parsing, AI summarization. No API keys needed. @@ -205,4 +207,19 @@ make check # Full audit ## License -MIT — Rug Munch Media LLC +Pry is dual-licensed to balance community openness with the protection of its advanced anti-detection and stealth capabilities. + +- **Most code** (core functionality, utilities, and standard modules) is licensed under the **MIT License**. This permissive license encourages community contributions and wide adoption. See [LICENSE](./LICENSE). + +- **The anti-detection / stealth module** is licensed under the **BSL 1.1 (Business Source License)**. This module is free to use for non-production purposes; a commercial license is required for any production use. See [LICENSE-BSL-STEALTH](./LICENSE-BSL-STEALTH). + +### Additional Use Grant + +Under the BSL 1.1, an Additional Use Grant permits free use of the stealth module for: +- Personal, non-commercial projects +- Non-production testing and evaluation +- Academic research +- Non-commercial open source software development +- A 90-day evaluation period for any other purpose + +For commercial licensing (production use, enterprise deployment, or embedding in proprietary products), please contact: **enterprise@rugmunch.io** diff --git a/ROADMAP.md b/ROADMAP.md index 7fa97a7..f656ef4 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) --- title: Pry Roadmap & Status status: canonical diff --git a/SECURITY.md b/SECURITY.md index 5b73054..21336f9 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # SECURITY.md — PryScraper > Threat model, secrets, auth, rate limiting, vuln disclosure. diff --git a/STATUS.md b/STATUS.md index ba7c5f3..a289b41 100644 --- a/STATUS.md +++ b/STATUS.md @@ -1,9 +1,14 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # STATUS.md — PryScraper > Where we are RIGHT NOW. Update before every commit. ## Last Updated -2026-07-02 (template, replace on first commit) +2026-07-03 - Dual-licensing relicense complete (MIT core + BSL 1.1 stealth) + +## Current Status +🟡 pre-production - repo scaffolded, re-license landed, deploy out of sync. See AUDIT.md. ## Deployment Status - **Last deploy**: TBD @@ -19,7 +24,12 @@ - 2026-07-02: Repository created from `fleet-template` ## Known Issues / Tech Debt -- _None yet_ +- Repo and deploy at /srv/pry/ are out of sync. Deploy runs a 789-line api.py; repo has 4,668-line api.py with 190 endpoints (MCP, x402, auth, etc.). MCP and x402 are written but not deployed. See AUDIT.md. +- All 80+ site templates unverified - only ~30-40% known to work end-to-end. Run templates/validate_templates.py before claiming template coverage. +- State storage in ~/.pry/*.json - no concurrency safety, no transactions. See plan to migrate to SQLite. +- PRY_API_KEY, PRY_X402_WALLET, PRY_X402_FACILITATOR env vars unset in deploy - no auth, no x402, no payments. +- License collision resolved 2026-07-03: dual MIT (core) + BSL 1.1 (stealth/anti-detection). See ADR-0002. +- mcp_production.py and x402.py exist in repo but are NOT deployed. Top priority for next deploy. ## Quick Links - [Live URL](https://pryscraper.rugmunch.io) diff --git a/TESTING.md b/TESTING.md index 7fddc93..06399a9 100644 --- a/TESTING.md +++ b/TESTING.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # TESTING.md — PryScraper > Test strategy. Unit, integration, e2e, fixtures. diff --git a/USAGE.md b/USAGE.md index ef7728b..89347be 100644 --- a/USAGE.md +++ b/USAGE.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) --- title: Pry Usage Guide status: canonical diff --git a/account_manager.py b/account_manager.py index 528be07..c774add 100644 --- a/account_manager.py +++ b/account_manager.py @@ -1,3 +1,8 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. """Pry — Account pool management, session persistence, proxy scoring.""" import json diff --git a/actor_marketplace.py b/actor_marketplace.py index 20a0ae4..37f0285 100644 --- a/actor_marketplace.py +++ b/actor_marketplace.py @@ -2,6 +2,12 @@ Pre-built scrapers that can be subscribed to and run on schedule. Users can publish their own actors. We earn from usage.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import json import logging import os diff --git a/adaptive.py b/adaptive.py index 6f4875e..11db26f 100644 --- a/adaptive.py +++ b/adaptive.py @@ -1,6 +1,13 @@ """Pry — adaptive crawling with information foraging. Intelligently decides when to stop crawling based on content relevance.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import logging import re from collections import Counter diff --git a/advanced.py b/advanced.py index 94c1dd0..ba392ba 100644 --- a/advanced.py +++ b/advanced.py @@ -3,6 +3,12 @@ Diff tracking, LLM summarization, RSS generation, change monitoring, schema.org extraction, email finder, and more. All powered by local Ollama — no API keys needed.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import difflib import hashlib import json diff --git a/agency.py b/agency.py index 6d629af..e62a87f 100644 --- a/agency.py +++ b/agency.py @@ -1,6 +1,12 @@ """Pry — White-Label Agency Dashboard. Multi-tenant reseller platform: custom branding, client management, sub-accounts.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import json import logging import os diff --git a/ai_plugin.py b/ai_plugin.py index d4acd49..d25960b 100644 --- a/ai_plugin.py +++ b/ai_plugin.py @@ -1,6 +1,12 @@ """Pry — AI Agent Plugin. OpenAPI spec server, MCP server wrapper, and GPT Action helper.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import json import logging from pathlib import Path diff --git a/alerter.py b/alerter.py index a8c4cac..de9b788 100644 --- a/alerter.py +++ b/alerter.py @@ -1,6 +1,12 @@ """Pry — Multi-Channel Alerting System. SMS, Email, Microsoft Teams, Discord, Telegram alerts.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import logging from typing import Any diff --git a/anomaly.py b/anomaly.py index b80a16c..97d4964 100644 --- a/anomaly.py +++ b/anomaly.py @@ -1,3 +1,8 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. """Pry — Real anomaly detection. Multi-field, time-series aware, with seasonality support.""" import logging diff --git a/api.py b/api.py index 405febd..1dc54ac 100644 --- a/api.py +++ b/api.py @@ -2,6 +2,12 @@ Scrape + Crawl + Automate + Parse + Extract + MCP Self-hosted, free, better than Firecrawl.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import asyncio import base64 import difflib diff --git a/auth.py b/auth.py index 58ad29d..ce44e11 100644 --- a/auth.py +++ b/auth.py @@ -1,3 +1,8 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. """Pry — Authentication with JWT and API keys, per-key rate limiting.""" import hashlib diff --git a/auth_connector.py b/auth_connector.py index a1394a5..5e0fa73 100644 --- a/auth_connector.py +++ b/auth_connector.py @@ -1,6 +1,13 @@ """Pry — Enterprise SSO / Auth Connector System. Credential vault, session persistence, SSO flow automation, CAPTCHA integration.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import asyncio import json import logging diff --git a/automator.py b/automator.py index c5e3b0d..ea40a71 100644 --- a/automator.py +++ b/automator.py @@ -6,6 +6,12 @@ Audited: session cleanup runs automatically, no injection vectors, all user inputs validated before passing to Playwright. """ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import asyncio import base64 import json diff --git a/behavioral_biometrics.py b/behavioral_biometrics.py index d5c882b..eb67f3f 100644 --- a/behavioral_biometrics.py +++ b/behavioral_biometrics.py @@ -3,6 +3,13 @@ Real human behavior simulation: hesitation, scroll-back, mouse drift, reading ti Modern anti-bot systems detect 'too perfect' behavior. This module makes behavior more realistic by adding human imperfections.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import logging import math import random diff --git a/browser-extension/background.js b/browser-extension/background.js index b1d29df..6ac05c8 100644 --- a/browser-extension/background.js +++ b/browser-extension/background.js @@ -1,3 +1,7 @@ +// SPDX-License-Identifier: MIT +// Copyright (c) 2026 Rug Munch Media LLC +// Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +// Licensed under MIT. See LICENSE. // Pry Browser Extension — Background Service Worker chrome.runtime.onInstalled.addListener(function() { chrome.storage.sync.get(['pryServerUrl'], function(result) { diff --git a/browser-extension/popup.html b/browser-extension/popup.html index 6e6cdb2..3be1898 100644 --- a/browser-extension/popup.html +++ b/browser-extension/popup.html @@ -1,3 +1,5 @@ +
diff --git a/browser-extension/popup.js b/browser-extension/popup.js index 5960a33..85079fd 100644 --- a/browser-extension/popup.js +++ b/browser-extension/popup.js @@ -1,3 +1,7 @@ +// SPDX-License-Identifier: MIT +// Copyright (c) 2026 Rug Munch Media LLC +// Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +// Licensed under MIT. See LICENSE. // Pry Browser Extension — Popup Script document.addEventListener('DOMContentLoaded', function() { loadSettings(); diff --git a/browser_pool.py b/browser_pool.py index b97bebe..896014d 100644 --- a/browser_pool.py +++ b/browser_pool.py @@ -1,6 +1,13 @@ """Pry — shared Playwright browser pool. Reuses browser instances across requests instead of launching per scrape.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import asyncio import logging from typing import Any diff --git a/cache.py b/cache.py index d5c3883..7007dbf 100644 --- a/cache.py +++ b/cache.py @@ -1,6 +1,12 @@ """Pry — in-memory LRU cache with Redis persistence. Prevents re-scraping the same URL within TTL window.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import hashlib import json import time diff --git a/camoufox_integration.py b/camoufox_integration.py index a1ad630..e74e623 100644 --- a/camoufox_integration.py +++ b/camoufox_integration.py @@ -3,6 +3,13 @@ Camoufox patches Firefox at the source level to bypass fingerprinting more effectively than Playwright/Puppeteer. It's a drop-in alternative for Playwright that focuses on stealth.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import logging import random import time diff --git a/captcha_solver.py b/captcha_solver.py index ce2bf9b..adee649 100644 --- a/captcha_solver.py +++ b/captcha_solver.py @@ -2,6 +2,13 @@ Supports: Capsolver -> 2Captcha -> Anti-Captcha -> CapMonster -> DeathByCaptcha -> NextCaptcha Also handles Turnstile, reCAPTCHA v2/v3/invisible, and hCaptcha.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import asyncio import json import logging diff --git a/cli.py b/cli.py index f131cdd..25a1cfe 100755 --- a/cli.py +++ b/cli.py @@ -15,6 +15,12 @@ Usage: pry proxy ... Manage proxy providers and signup """ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import base64 import json import os diff --git a/client.py b/client.py index 2bb8281..4272cc9 100644 --- a/client.py +++ b/client.py @@ -1,6 +1,12 @@ """Pry — shared httpx client pool with connection reuse. All modules import `http_client` instead of creating new clients per request.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import logging import httpx diff --git a/commerce_sync.py b/commerce_sync.py index 85f02fb..4831d24 100644 --- a/commerce_sync.py +++ b/commerce_sync.py @@ -1,6 +1,12 @@ """Pry — Commerce Platform Sync Engine. Unified interface for WooCommerce, Shopify, and generic API sync.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import logging import os from pathlib import Path diff --git a/compliance.py b/compliance.py index aef4468..e06e564 100644 --- a/compliance.py +++ b/compliance.py @@ -1,6 +1,12 @@ """Pry — Legal Compliance Engine. Per-source compliance scorecard: robots.txt, ToS, GDPR/CCPA, jurisdiction.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import logging import re from datetime import UTC, datetime diff --git a/config.py b/config.py index 32c1255..9e09c3c 100644 --- a/config.py +++ b/config.py @@ -3,6 +3,12 @@ Loads settings from environment variables (via Pydantic Settings). All secrets come from gopass, never from .env files committed to git. """ + +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. from __future__ import annotations import os diff --git a/cookie_warmer.py b/cookie_warmer.py index efb341f..753ec52 100644 --- a/cookie_warmer.py +++ b/cookie_warmer.py @@ -3,6 +3,13 @@ Pre-age cookies by browsing legitimate pages first. Aged cookies with realistic browsing history bypass anti-bot detection that checks for 'fresh' cookies. This is a technique used by professional scraping services.""" +# SPDX-License-Identifier: BSL-1.1 +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — Stealth / Anti-Detection Module +# Licensed under Business Source License 1.1 — see LICENSE-BSL-STEALTH. +# Change Date: 2029-01-01 (converts to MIT). + import asyncio import json import logging diff --git a/costing.py b/costing.py index 5ef470b..43d0f6f 100644 --- a/costing.py +++ b/costing.py @@ -1,6 +1,12 @@ """Pry — Cost Analytics Engine. Tracks usage costs, cache hit rates, projected burn, and smart scheduling.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import json import logging import os diff --git a/crm_sync.py b/crm_sync.py index 9e14bdd..35f34ed 100644 --- a/crm_sync.py +++ b/crm_sync.py @@ -1,6 +1,12 @@ """Pry — Reverse ETL to CRM. Sync scraped data to Salesforce, HubSpot, Pipedrive, and Close.com.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import logging from typing import Any diff --git a/db.py b/db.py index ed63852..6fbf5b9 100644 --- a/db.py +++ b/db.py @@ -1,6 +1,12 @@ """Pry — Database layer using SQLAlchemy (SQLite/PostgreSQL). Replaces JSON file storage for production safety.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import logging import os from collections.abc import Generator diff --git a/dedup.py b/dedup.py index 312a2c7..ce3308d 100644 --- a/dedup.py +++ b/dedup.py @@ -2,6 +2,12 @@ Detects near-duplicate content (e.g., 95% similar pages) using SimHash. Useful for crawl deduplication, change detection, and content grouping.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import hashlib import logging import re diff --git a/destinations.py b/destinations.py index c79ae9f..b4c62e0 100644 --- a/destinations.py +++ b/destinations.py @@ -1,6 +1,12 @@ """Pry — One-Click Business Integrations. Native write destinations: Google Sheets, Slack, Airtable, email.""" +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. + import json import logging from datetime import UTC, datetime diff --git a/docker-compose.yml b/docker-compose.yml index 96d5867..136b0c8 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,3 +1,7 @@ +# SPDX-License-Identifier: MIT +# Copyright (c) 2026 Rug Munch Media LLC +# Part of Pry — https://git.rugmunch.io/RugMunchMedia/pryscraper +# Licensed under MIT. See LICENSE. services: pry: build: . diff --git a/docs/adr/0000-template.md b/docs/adr/0000-template.md index aa0bdcc..9824413 100644 --- a/docs/adr/0000-template.md +++ b/docs/adr/0000-template.md @@ -1,3 +1,5 @@ +[//]: # (SPDX-License-Identifier: MIT) +[//]: # (Copyright (c) 2026 Rug Munch Media LLC) # ADR-NNNN: