Skip to main content

Official Python SDK for the Hyperclip API — create, poll, and manage flow runs.

Project description

hyperclipco

PyPI PyPI downloads Python versions

Official Python SDK for the Hyperclip API.

Installed as hyperclipco (the unscoped hyperclip name was already taken on PyPI). Imports as hyperclipco.

Install

pip install hyperclipco

Requires Python 3.9+.

Quickstart

import os, uuid
from hyperclipco import Hyperclip

hc = Hyperclip(
    api_key=os.environ["HYPERCLIP_API_KEY"],
    base_url="https://YOUR-PROJECT.supabase.co/functions/v1/api-v1",
)

ref = hc.runs.create(
    flow_id="a3c7f1ea-1234-4abc-bb11-5faed63c7e90",
    inputs={"prompts": {0: "a lighthouse at dawn"}},
    idempotency_key=str(uuid.uuid4()),
)

run = hc.runs.wait(
    ref["id"],
    on_update=lambda r: print(r["status"], r.get("current_step")),
)

if run["status"] == "completed":
    print("Video:", run["video_url"])
else:
    print(run["error_code"], run["error_message"])

Configuration

Argument Env var Required
api_key HYPERCLIP_API_KEY yes
base_url HYPERCLIP_BASE_URL yes
timeout no (defaults to 30s)
client no (inject your own httpx.Client)

API

  • hc.runs.create(flow_id=..., flow_schema=..., inputs=..., idempotency_key=...)
  • hc.runs.get(run_id)
  • hc.runs.list(limit=..., status=...)
  • hc.runs.cancel(run_id)
  • hc.runs.wait(run_id, timeout=600, poll_interval=4, on_update=...) — polls until terminal
  • hc.flows.list()
  • hc.flows.get(flow_id)

Errors raise HyperclipError (with .status and .code). Timeouts raise HyperclipTimeoutError.

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

hyperclipco-0.1.2.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

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

hyperclipco-0.1.2-py3-none-any.whl (4.3 kB view details)

Uploaded Python 3

File details

Details for the file hyperclipco-0.1.2.tar.gz.

File metadata

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

File hashes

Hashes for hyperclipco-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0937c79245fb8aff286285e1144d786f5aa9f238f4dda9e476bd3263d07aa36e
MD5 6b8fed3d42f581e8d52d464c6224479d
BLAKE2b-256 5429bcb2f3a610cbde671a52d587d29b9ccc8b12e1d6957f5f597abaad8061b2

See more details on using hashes here.

Provenance

The following attestation bundles were made for hyperclipco-0.1.2.tar.gz:

Publisher: publish-python.yml on hyperclip/hyperclip

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

File details

Details for the file hyperclipco-0.1.2-py3-none-any.whl.

File metadata

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

File hashes

Hashes for hyperclipco-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 13f380853f99ad622a714c5e962cf9c4fd36e3d3290f33108f572cc938ada69d
MD5 cb1a7908e896217f36dffaaa537a713d
BLAKE2b-256 66de5b616581cdbce51cc32355ffec17730dde5478540bd5f2a824eeb2231889

See more details on using hashes here.

Provenance

The following attestation bundles were made for hyperclipco-0.1.2-py3-none-any.whl:

Publisher: publish-python.yml on hyperclip/hyperclip

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