Skip to main content

storyflo (Python)

Official Python client for the Storyflo audio news API. Wraps the six agent tools across all three protocols (public REST, OAuth 2.1, x402 micropayments).

pip install storyflo

Usage

from storyflo import StoryfloClient

# Public read — no auth, rate-limited per IP.
sf = StoryfloClient()

trending = sf.search_articles(vertical="tech", limit=5)
for a in trending["articles"]:
    audio = sf.get_audio_url(a["slug"])
    print(f"{a['title']} → {audio['audio_url']}")

OAuth (Claude / ChatGPT agents)

import os

sf = StoryfloClient(auth=("bearer", os.environ["STORYFLO_OAUTH_TOKEN"]))

sf.subscribe_topic(["tech", "finance"])
digest = sf.digest(window="24h", limit=5)

x402 micropayments (Coinbase AgentKit)

# `payment_header` is the base64-encoded EIP-712 authorization the
# AgentKit produces on settle. Each call costs $0.001-$0.30 USDC.
sf = StoryfloClient(auth=("x402", payment_header))
article = sf.get_article("interest-rates-q1")

API

Method Tool Auth required
search_articles(...) search_articles none / x402
get_article(slug) get_article none / x402
get_audio_url(slug) get_audio_url OAuth / x402
subscribe_topic(verticals) subscribe_topic OAuth (write scope)
list_subscriptions() list_subscriptions OAuth (read scope)
digest(window, limit, ...) digest OAuth / x402

Errors raise StoryfloError with .status and parsed .body.

License

MIT

Release files for storyflo 1.0.1

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

Source distribution (sdist)

Source distribution for storyflo 1.0.1
File Size Uploaded
storyflo-1.0.1.tar.gz 4.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for storyflo 1.0.1
File Interpreter ABI Platform
storyflo-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 8.3 kB

Release files / storyflo-1.0.1.tar.gz

Download URL storyflo-1.0.1.tar.gz
Size 4.0 kB
Tags Source
SHA-256 checksum
How to use checksums
600dd4864c990291482267532396c78f6cb29ba06cf02c1b3ad842639b24878d
BLAKE2b-256 checksum
How to use checksums
d43d3b01fb6481f1d43dd677fa0e643c40a41c344b961e0941bc07028ea25174
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.6

Release files / storyflo-1.0.1-py3-none-any.whl

Download URL storyflo-1.0.1-py3-none-any.whl
Size 4.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9832e06c82f224b7628e689fb7d6a89b547e4d70b373b532a5b39ab9d51232f6
BLAKE2b-256 checksum
How to use checksums
9f51fe0ccdb32b817ff4e826fbe2bb954534c6788c7d016d1a2d2d541a710a11
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.6

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files

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