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.1.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.1-py3-none-any.whl (4.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: hyperclipco-0.1.1.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.1.tar.gz
Algorithm Hash digest
SHA256 c94ece1ddb3943954659208f1853379acc77aaccacb697d21dc178955d6fbbb2
MD5 737f3b1810b3a1ae3989d5b4aad10160
BLAKE2b-256 00447a62041c522c7358375297be59bdfc615e8f9de53a8520738afbbb3b11bd

See more details on using hashes here.

Provenance

The following attestation bundles were made for hyperclipco-0.1.1.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.1-py3-none-any.whl.

File metadata

  • Download URL: hyperclipco-0.1.1-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.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e624ac495677b72959e130fe52b1056f92df5b7a4c1c70da580fcec4504840d5
MD5 7836aea50bd18cd3a7f2f97f7226d29d
BLAKE2b-256 dc34b244de23e05b2f9cf201e8dd518ba1e123911f2685cfbf9754883de47782

See more details on using hashes here.

Provenance

The following attestation bundles were made for hyperclipco-0.1.1-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