Skip to main content

crewai-botsrated

One-click attach

Free. No key for local attach. Pairs with the host runtime. Not a second runtime. Paid checks are not required to attach.

pip install "botsrated[x402]"
from botsrated import PaymentGuard
guard = PaymentGuard(preset="carefulBuyer")  # omit preset = warn only, never stops a payment
guard.install(x402_client)                   # the x402 client your agent already pays with

The pair-with package is not on PyPI yet: pip install -e integrations/crewai, then attach_payment_guard from crewai_botsrated.

Preflight and the guard surface signed receipt links (receipt_url). When org ledger is enabled, paid checks write there by default. No custody. Facts, not grades.

Live docs: botsrated.com/docs/guard#crewai.

Default install

Pairs with CrewAI. Payment-client wrap and an optional before-pay tool hook. Not a crew, process, flow, or agent loop. Free. No key for local attach. Today: pip install "botsrated[x402]" and PaymentGuard. The pair-with package is not on PyPI yet: pip install -e integrations/crewai (botsrated>=0.3.1,<0.4).

Pair-with package (not on PyPI yet):

# Free. No key for local attach. Not a runtime.
# Optional BOTSRATED_TOKEN for Desk remote policy.
from crewai_botsrated import attach_payment_guard
# Omit preset = advice. Omit fail_mode = open.
guard = attach_payment_guard(x402_client)

It does not sign a payment and does not hold funds.

Install in 3 steps

  1. Free. No key for local attach. Install the guard that works today: pip install "botsrated[x402]", then PaymentGuard on the x402 client your agent already pays with (one-click above). The pair-with package is not on PyPI yet. From a checkout, in a clean virtualenv: pip install -e integrations/crewai (pulls botsrated>=0.3.1,<0.4).
  2. On the pair-with package, attach to your x402 client. Installing does not attach a guard:
from crewai_botsrated import attach_payment_guard
guard = attach_payment_guard(x402_client)
  1. Omit preset for advice only (carefulBuyer / strict stop an unobserved payTo when you pass them). Omit fail_mode to stay open. "closed" stops the payment when BotsRated or your policy cannot answer. A missing decision is never a pass. A remote pass never clears a local block.

BOTSRATED_TOKEN is optional. Omit token and the guard reads BOTSRATED_TOKEN. On botsrated 0.3.0 and later it is sent only as remote_policy={"token", "fail_mode"}, never as a bare string. A configured token on a core without parse_remote_policy raises and is not dropped. The policy decision is not signed. Get a token in Desk.

Omit fail_mode and the guard stays open. "closed" stops the payment when BotsRated or your policy cannot answer. A missing decision is never a pass. A remote pass never clears a local block. Nothing defaults you to closed.

Before-pay hook and token

register_botsrated_pre_tool_hook(guard, paid_tools={"pay_seller"}) registers CrewAI PRE_TOOL_CALL (@on(InterceptionPoint.PRE_TOOL_CALL)). On a block it raises HookAborted(reason=..., source="botsrated") and does not run that tool. Older CrewAI uses @before_tool_call and returns False. Tools that are not named are left alone. botsrated_preflight(url) is the free preflight and does not attach a guard.

BOTSRATED_TOKEN is optional. Omit token and the guard reads BOTSRATED_TOKEN. On botsrated 0.3.0 and later it is sent only as remote_policy={"token", "fail_mode"}, never as a bare string. A configured token on a core without parse_remote_policy raises and is not dropped. The policy decision is not signed. Get a token in Desk.

Tests: pytest -m "not live" in this directory. They do not kick off a crew.

Metadata

Release files for crewai-botsrated 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for crewai-botsrated 0.1.0
File Size Uploaded Provenance Actions
crewai_botsrated-0.1.0.tar.gz 14.5 kB With provenance Details for crewai_botsrated-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for crewai-botsrated 0.1.0
File Interpreter ABI Platform Actions
crewai_botsrated-0.1.0-py3-none-any.whl Python 3 none any Details for crewai_botsrated-0.1.0-py3-none-any.whl

Total release size: 23.5 kB

Release files / crewai_botsrated-0.1.0.tar.gz

Download URL crewai_botsrated-0.1.0.tar.gz
Size 14.5 kB
Tags Source
SHA-256 checksum
How to use checksums
900d17e139c4c4ff3ecadbbd1239081724e504ef28d8d9f743a12cfac6942abb
BLAKE2b-256 checksum
How to use checksums
5d07cdf5b57929ee3e2c7037e1a3003fd29a92a53dcf7ab06f9103efc626f288
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / crewai_botsrated-0.1.0-py3-none-any.whl

Download URL crewai_botsrated-0.1.0-py3-none-any.whl
Size 9.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
089ae02f3a4f6127625bf25bde5378d81d2dd8debce9fec9e7d2216982377f5c
BLAKE2b-256 checksum
How to use checksums
e394fce3f0cf723d71756fabc80452290f5369c7090b659c1b622c33a31edf02
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Security for crewai-botsrated 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for crewai_botsrated-0.1.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page