Skip to main content

Official Python SDK for the Caistro API

This project has been archived.

The maintainers of this project have marked this project as archived. No new releases are expected.

Project description

Caistro Python SDK

Official Python SDK for the Caistro API.

Installation

pip install caistro

Quick Start

from caistro import Caistro, Message

client = Caistro(api_key="your-api-key")

response = client.chat(
    messages=[
        Message(role="user", content="Write a tagline for a coffee shop")
    ]
)

print(response.choices[0].message.content)

Async Usage

import asyncio
from caistro.client import AsyncCaistro
from caistro import Message

async def main():
    async with AsyncCaistro(api_key="your-api-key") as client:
        response = await client.chat(
            messages=[
                Message(role="user", content="Write a tagline for a coffee shop")
            ]
        )
        print(response.choices[0].message.content)

asyncio.run(main())

Documentation

Full documentation: docs.caistro.com

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

caistro-0.1.0.tar.gz (2.8 kB view details)

Uploaded Source

Built Distribution

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

caistro-0.1.0-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file caistro-0.1.0.tar.gz.

File metadata

  • Download URL: caistro-0.1.0.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for caistro-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7b1351d7c7ef4d92203e9bdd07609d5c4ab15169c6957bb2d71dad746cabeaf7
MD5 e3722e3de1165ff1fa008e338388f6dc
BLAKE2b-256 2a99d7b6cb42a9577c6a2580c1e75de2a06e9b664938eaec7af0b2e80a468bc7

See more details on using hashes here.

File details

Details for the file caistro-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: caistro-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for caistro-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bf5008d09a1fc93996904f7c69e61ffc14cae5db34a6403ca8357470413313a4
MD5 26231834c6d9e84f882c82f64050a540
BLAKE2b-256 e4d1851076d48b06b401c0de01c4b2956df169525156aebf6c11c757be1bfd38

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