Skip to main content

Python module to interact with a Peertube instance's API.

Project description

PyPeertube

Python module to interact with a Peertube instance's API.

Example

Search for videos tagged animal or dog and containing puppy in the title or description, printing the video's title and link of each result.

from pypeertube.client import ApiClient
from pypeertube.videos import search_videos

PEERTUBE_URL = "https://my.peertube.tld"
PEERTUBE_USERNAME = "my_username"
PEERTUBE_PASSWORD = "my_password"
SEARCH_STRING = "Puppy"
SEARCH_TAGS = ["animal", "dog"]

with ApiClient(PEERTUBE_URL, PEERTUBE_USERNAME, PEERTUBE_PASSWORD) as client:
    for video in search_videos(client, SEARCH_STRING, tags_or=SEARCH_TAGS):
        print(f"{video.name}: {client.base_url}/w/{video.short_uuid}")

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

pypeertube-1.1.0.tar.gz (26.3 kB view details)

Uploaded Source

Built Distribution

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

pypeertube-1.1.0-py3-none-any.whl (29.0 kB view details)

Uploaded Python 3

File details

Details for the file pypeertube-1.1.0.tar.gz.

File metadata

  • Download URL: pypeertube-1.1.0.tar.gz
  • Upload date:
  • Size: 26.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pypeertube-1.1.0.tar.gz
Algorithm Hash digest
SHA256 b3eaecff1e7b2871a2fa8e96934ac06f96862a369f9d270061a488e25ffa11f9
MD5 7e0a1cdaf351888b087b2f36f02b899d
BLAKE2b-256 6d675a447027ec0b8c75743b342f55ebeef7e55037dee0fa2a3f713e8dace140

See more details on using hashes here.

Provenance

The following attestation bundles were made for pypeertube-1.1.0.tar.gz:

Publisher: build.yml on CaramelConnoisseur/PyPeertube

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

File details

Details for the file pypeertube-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: pypeertube-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 29.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pypeertube-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7d87d8a537364a0d3fc6d16f62f90178c95c8cdcb55ab2b2acc70c4974dc3f67
MD5 f503fd2a24409e140553b6aea1a4a7ef
BLAKE2b-256 c99601d0e909470b4bc237cdccf2e41e08001c6eb4bf9fd492171501eadeebbf

See more details on using hashes here.

Provenance

The following attestation bundles were made for pypeertube-1.1.0-py3-none-any.whl:

Publisher: build.yml on CaramelConnoisseur/PyPeertube

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