Skip to main content

Official Python SDK for the Pod Engine podcast intelligence API — search 4M+ podcasts, fetch metadata, transcripts, charts and more.

Project description

Pod Engine Python SDK

Official Python client for the Pod Engine podcast intelligence API — search 4M+ podcasts, fetch metadata, transcripts, charts, guest profiles and more.

The client is fully generated from Pod Engine's published OpenAPI specification, so it stays in lockstep with the API and ships typed pydantic models for every request and response.

Install

pip install podengine
# or: uv add podengine

Requires Python 3.10+.

Quickstart (sync)

from podengine import PodEngine

pe = PodEngine(api_key="YOUR_API_KEY")

chart = pe.charts.get_latest_chart(chart_type="apple", country="us", category="top podcasts")
for entry in chart.podcasts:
    print(entry.rank, entry.title)

results = pe.search.search_podcasts(
    search_terms=[
        {
            "searchTerm": "startups",
            "searchType": "text",
            "searchTargets": ["podcast-title"],
            "searchTermOptions": {"matchMode": "optional"},
        }
    ],
)

Get an API key at https://www.podengine.ai/get-started.

Quickstart (async)

import asyncio
from podengine import AsyncPodEngine

async def main() -> None:
    async with AsyncPodEngine(api_key="YOUR_API_KEY") as pe:
        chart = await pe.charts.get_latest_chart(
            chart_type="apple", country="us", category="top podcasts"
        )
        print(chart)

asyncio.run(main())

Configuration

pe = PodEngine(
    api_key="YOUR_API_KEY",
    base_url="https://api.podengine.ai",  # override for staging; or set PODENGINE_API_URL
    source="my-app",                       # sent as the x-source header
    timeout=60.0,                          # per-request timeout (seconds)
    max_retries=2,                         # transient 429/5xx/network retries
)

Per-call overrides are available via RequestOptions:

from podengine import RequestOptions

chart = pe.charts.get_latest_chart(
    chart_type="apple",
    country="us",
    category="top podcasts",
    request_options=RequestOptions(timeout=10.0, max_retries=0),
)

Error handling

Every failure is a PodEngineError subclass:

from podengine import PodEngine, PodEngineAPIError, PodEngineConnectionError

pe = PodEngine(api_key="YOUR_API_KEY")
try:
    chart = pe.charts.get_latest_chart(chart_type="apple", country="us", category="top podcasts")
except PodEngineAPIError as err:
    print(err.status, err.message, err.request_id)  # non-2xx response
except PodEngineConnectionError as err:
    print("network failure:", err)                  # no HTTP response

License

MIT

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

podengine-0.1.0.tar.gz (95.8 kB view details)

Uploaded Source

Built Distribution

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

podengine-0.1.0-py3-none-any.whl (41.0 kB view details)

Uploaded Python 3

File details

Details for the file podengine-0.1.0.tar.gz.

File metadata

  • Download URL: podengine-0.1.0.tar.gz
  • Upload date:
  • Size: 95.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for podengine-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d1e14b655ae5d29875a20c39eba3e3867c0cdb0366f6086ea10fe7f8b7be97cd
MD5 2cc7a11d29b4a44d569bdaa942ed41d3
BLAKE2b-256 8e8ca41b5fbbc9a197b6068cd1643deb212c5ee42efc6e4f127e02b14ece8761

See more details on using hashes here.

Provenance

The following attestation bundles were made for podengine-0.1.0.tar.gz:

Publisher: publish.yml on podengine/podcast-api-client-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file podengine-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: podengine-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 41.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for podengine-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f374a5d390768ba3c36f5588353759f37a4f1a7ac2a09056f9dff2dada204b30
MD5 627d943aebaef5fc0b0245aadae5ba7c
BLAKE2b-256 b60478be63e4a62c5a76cd37a0372b1b3fa513f2ab7f63993d6b874955d5e0fc

See more details on using hashes here.

Provenance

The following attestation bundles were made for podengine-0.1.0-py3-none-any.whl:

Publisher: publish.yml on podengine/podcast-api-client-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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