Skip to main content

A Python client for the Vsports API

Project description

Vsports API

FILE: /vsports/vsports/README.md

This file contains the documentation for the Vsports API package

The Vsports API is a Python package that provides an interface for interacting with the Vsports API. It allows users to access various endpoints and retrieve sports-related data efficiently.

Features

  • Access to multiple endpoints of the Vsports API.
  • Support for caching using Redis to improve performance.
  • Easy-to-use methods for retrieving events, teams, and other sports data.

Installation

You can install the Vsports API package using pip:

pip install vsports

Usage

Here is a simple example of how to use the Vsports API:

import json
from vsports import VsportsAPI

MYTOKEN = "your_token_here"
redis_config = {
    "host": "localhost", 
    "port": 6379, 
    "db": 0,
    "ttl": 300
}

vsports = VsportsAPI(MYTOKEN, redis_config=redis_config)
result = vsports.events_by_date("2025-01-24", usecache=True)
if result:
    print(json.dumps(result, indent=2))

result = vsports.teams_by_tournament(118, usecache=True)
if result:
    for team in result:
        print(team['name'])

License

This project is licensed under the MIT License - see the LICENSE file for details.

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

vsports-1.0.1.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

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

vsports-1.0.1-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file vsports-1.0.1.tar.gz.

File metadata

  • Download URL: vsports-1.0.1.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for vsports-1.0.1.tar.gz
Algorithm Hash digest
SHA256 198c350c4841983b978a6f01180d8eb39041cdc8d52990b4ed210653b1ed0116
MD5 765b60048e0bf32d5635dc7d5fa3aae9
BLAKE2b-256 cfe47d2ff783911f4912f98eec0a9a8f3eafeb3be3ec9ef650eacccb0c74dde9

See more details on using hashes here.

File details

Details for the file vsports-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: vsports-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for vsports-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5232eecdd9fdbaad4d4817db7a6b99422724bf160e5ee02e5dcc34813107b486
MD5 37e3d3ff4dcc96eabbd7f0e948532433
BLAKE2b-256 cf47c580989ccdecb3925ba6f5f359f548476eef0c9af3e1fc90de8851d685ce

See more details on using hashes here.

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