Python SDK for the VidContext video intelligence API
Project description
vidcontext
Python SDK for the VidContext video intelligence API.
Analyze any video and get structured text output — context summaries, ad breakdowns, competitor analysis, and more.
Install
pip install vidcontext
Quick start
import vidcontext
# Uses VIDCONTEXT_API_KEY env var
result = vidcontext.analyze("video.mp4", mode="context")
print(result.result)
Async usage
from vidcontext import VidContext
async with VidContext(api_key="vc_...") as client:
result = await client.analyze("video.mp4", mode="ad")
print(result.result)
Sync usage
from vidcontext import SyncVidContext
with SyncVidContext(api_key="vc_...") as client:
result = client.analyze("video.mp4", mode="context")
print(result.result)
credit_info = client.get_credits()
print(f"Credits: {credit_info.credits}")
Fire-and-forget
job = vidcontext.submit("video.mp4", mode="editor")
print(job.job_id) # Check status later
Analysis modes
| Mode | Output |
|---|---|
context |
Scene-by-scene description for AI agents |
editor |
Shot list with timecodes for video editors |
analysis |
Deep content analysis with themes and structure |
ad |
Ad performance breakdown with scores |
ecommerce |
Product and UX analysis for online stores |
training |
Training/educational content evaluation |
ugc |
User-generated content quality assessment |
competitor |
Competitive intelligence from video content |
Account methods
with SyncVidContext() as client:
profile = client.get_profile()
credits = client.get_credits()
usage = client.get_usage()
packs = client.get_credit_packs()
keys = client.list_api_keys()
Error handling
from vidcontext import VidContextError, AuthenticationError, JobTimeoutError
try:
result = vidcontext.analyze("video.mp4")
except AuthenticationError:
print("Bad API key")
except JobTimeoutError:
print("Processing took too long")
except VidContextError as e:
print(f"API error: {e}")
Requirements
- Python 3.10+
httpx(installed automatically)
Get an API key
Sign up at vidcontext.com and go to Developer settings.
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
vidcontext-0.1.0.tar.gz
(11.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vidcontext-0.1.0.tar.gz.
File metadata
- Download URL: vidcontext-0.1.0.tar.gz
- Upload date:
- Size: 11.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a758f11ec48f5bfedbb63c01e5c9fac28f98b384e393e1d56d317bab89e04bb5
|
|
| MD5 |
e31b73f1cd4f08ca12562f0072c7010c
|
|
| BLAKE2b-256 |
da500faf445c830fd53a2b7dcb3ba79003a0815f658739a36203bc70344a952f
|
File details
Details for the file vidcontext-0.1.0-py3-none-any.whl.
File metadata
- Download URL: vidcontext-0.1.0-py3-none-any.whl
- Upload date:
- Size: 14.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ab108b3e5be46f549bd33646f760ce733349dc639ea0c0a3081d64ab38c31a00
|
|
| MD5 |
b557849964229164de5b5a2ea015b2ba
|
|
| BLAKE2b-256 |
5b5833e98638b590b42e890be1a3fcc0aa09ded9c5229d4c1f2d0661b96203e1
|