Skip to main content

TrustOriginality.ai — Python SDK

Thin wrapper around the TrustOriginality.ai REST API for AI-content detection, composite KYC verification and the signed provenance registry.

Install

pip install trustoriginality
# Local dev from repo: pip install ./sdk/python

Quick start

from trustoriginality import TrustOriginality

client = TrustOriginality(api_key="to_live_...")  # create keys in the panel under API Keys

# Text
res = client.analyze_text("The content you want to analyze...")
print(res["isAIGeneratedLikely"], res["score"])

# Image — from a local file or a public URL
res = client.analyze_image(file="photo.jpg", name="Campaign visual")
res = client.analyze_image(url="https://example.com/photo.jpg")

# Audio / video work the same way
res = client.analyze_audio(file="voice.mp3")
res = client.analyze_video(url="https://example.com/clip.mp4")

# Composite KYC: ID document + selfie (+ optional voice)
res = client.verify_kyc(document="id-card.jpg", selfie="selfie.jpg", voice="sample.wav")
print(res["riskLevel"], res["recommendation"])

# Provenance registry
res = client.register_provenance(file="original.png", declaration="human-created")
print(res["contentHash"], res["verifyUrl"])
record = client.get_provenance(res["contentHash"])

Errors

All non-2xx responses raise TrustOriginalityError with status_code and the parsed API payload:

from trustoriginality import TrustOriginality, TrustOriginalityError

try:
    client.analyze_image(url="https://example.com/missing.jpg")
except TrustOriginalityError as e:
    print(e.status_code, e.payload)

Self-hosted / on-prem (TrustOriginality Box)

Point the client at your Box instead of the cloud panel:

client = TrustOriginality(api_key="unused", base_url="http://box.local:8080")

Note: Box endpoints use /analyze/image style paths; cloud-specific features (credits, provenance) are panel-only. See TrustOriginality_Box/README.md.

Metadata

Release files for trustoriginality 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for trustoriginality 0.1.0
File Size Uploaded Provenance
trustoriginality-0.1.0.tar.gz 3.6 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for trustoriginality 0.1.0
File Interpreter ABI Platform
trustoriginality-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 7.6 kB

Release files / trustoriginality-0.1.0.tar.gz

Download URL trustoriginality-0.1.0.tar.gz
Size 3.6 kB
Tags Source
SHA-256 checksum
How to use checksums
662193b3a4b07bb1a6c3009706de2ec113d0301cb09ff22579aeb2f80d5fa02f
BLAKE2b-256 checksum
How to use checksums
11d4b6a615e792e503fc26b27986d4b18d5da636f3b1f5cbfea1b4282b9a0d93
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.2

Release files / trustoriginality-0.1.0-py3-none-any.whl

Download URL trustoriginality-0.1.0-py3-none-any.whl
Size 3.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
60b1275f47ce48d3136d0be56d476cb9407ca48f72a021d938bf0e46f0178c9e
BLAKE2b-256 checksum
How to use checksums
1d6435387fd3c4fe3f585f7a8abd53bb8dc0a3dd799b973b818beaae265b5430
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.2

Security for trustoriginality 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page