Skip to main content

Python SDK for Analog — instantly distill webpages into structured data.

Reason this release was yanked:

Superseded by 0.10.0. This version predates the current sign-in flow (retired server-side) and is below the backend's minimum supported version — it can no longer authenticate or extract. Install the current release: pip install -U analog-sdk.

Project description

analog-sdk

Python SDK for Analog — instantly distill webpages into structured data.

Installation

pip install analog-sdk

Analog renders every page in a real headless browser (running its JS) before extraction, so client-side-built content — single-page apps, infinite scroll, content that hydrates client-side — is captured by default. The browser is built in (analog.Browser); its binaries download automatically on first use (~150 MB, one-time). To fetch them ahead of time — in CI or an agent harness, so the first call doesn't pause — run:

analog browser install

Prefer a plain HTTP GET (no JS)? Pass fetcher=HttpFetcher().

Authenticate

New to Analog? analog signup opens the account-creation page (invite code required during the private alpha). Then:

analog login

This opens your browser to sign in. The credential is minted straight into a local store and never shown on screen, so the model driving your session never sees it. Subsequent SDK and CLI usage picks it up automatically; sign out any time with analog logout.

Signing in requires a browser on the machine running analog login.

Try it straight from the shell:

analog get https://news.ycombinator.com

Run analog --help to see all commands (signup, login, logout, whoami, status, get).

If you don't want a globally-installed analog binary, use pipx install analog-sdk or uv tool install analog-sdk instead of plain pip install.

Usage

from analog import analog

result = analog("https://example.com")

Same one-liner whether or not the JS-aware fetcher is installed. When it is, JS-heavy pages just work.

See https://getanalog.io for full documentation.

Saved results

Every analog(url) call saves its result locally, so you can re-open or re-export it later — without re-fetching or re-rendering the page:

from analog import analog, history, latest

result = analog("https://example.com")
print(result.handle)        # "20260618-k7m2p9"

# Later — rehydrated from disk, no network:
again = latest()            # the most recent result
print(again.markdown)       # full-page markdown, stored alongside the data
for meta in history():      # everything saved, newest first
    print(meta.handle, meta.url)

Re-open a specific result with analog.open(handle). Artifacts live under your per-user cache directory (~/.cache/analog/results; ~/Library/Caches/analog/results on macOS; ANALOG_CACHE_DIR overrides) and store only safe derivatives — the structured result and full-page markdown, never raw HTML. Pass analog(url, save=False) to skip saving; the store is size-bounded and drops least-recently-opened results.

From the shell, analog get <url> saves and prints the handle, and analog history / analog open <handle> / analog export <handle> -f csv / analog rm <handle> manage saved results (latest works anywhere a handle does).

License

MIT — see LICENSE.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

analog_sdk-0.6.0.tar.gz (113.6 kB view details)

Uploaded Source

Built Distribution

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

analog_sdk-0.6.0-py3-none-any.whl (91.2 kB view details)

Uploaded Python 3

File details

Details for the file analog_sdk-0.6.0.tar.gz.

File metadata

  • Download URL: analog_sdk-0.6.0.tar.gz
  • Upload date:
  • Size: 113.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for analog_sdk-0.6.0.tar.gz
Algorithm Hash digest
SHA256 e78f9a4cc2bcda83cc2915e72b011996edcf1864d9f0e52afd805eb90e08e8bf
MD5 a745dd84f871e82a4a8c7736c5832b7a
BLAKE2b-256 878edf6723c7c340d3a37279eae4be26619b503c6680998e962d3e3fd2f7b47b

See more details on using hashes here.

Provenance

The following attestation bundles were made for analog_sdk-0.6.0.tar.gz:

Publisher: release-sdk-python.yml on getanalog/monorepo

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

File details

Details for the file analog_sdk-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: analog_sdk-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 91.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for analog_sdk-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 17e635c59c98f82755dcd920eddf164c50fd88403e9ae3b22859272b7fbca8a6
MD5 56c52ad8dfc62555c381ca970ca89474
BLAKE2b-256 144c6e5b8c690e9f55fe9723e05f9d1ed3428b84b42278823eb53609c7304edd

See more details on using hashes here.

Provenance

The following attestation bundles were made for analog_sdk-0.6.0-py3-none-any.whl:

Publisher: release-sdk-python.yml on getanalog/monorepo

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