Skip to main content

Python SDK

The official Python SDK provides a convenient way to interact with the Meibel API.

Installation

pip install meibel

Quick Start

from meibel import MeibelClient

# Initialize the client
client = MeibelClient(api_key="your-api-key")

# Make API calls
# ...

Async Support

The SDK provides both synchronous and asynchronous clients:
from meibel import AsyncMeibelClient
import asyncio

async def main():
    client = AsyncMeibelClient(api_key="your-api-key")
    # Make async API calls
    # ...
    await client.close()

asyncio.run(main())

Configuration

client = MeibelClient(
    api_key="your-api-key",
    base_url="https://api.example.com",  # Custom base URL
    timeout=30.0,  # Request timeout in seconds
)

Resources

  • client.agents - Create, manage, and publish AI agents
  • client.agents.sessions - Create, manage, and chat with agent sessions
  • client.artifact_schemas - Define structured output schemas for agent artifacts
  • client.batches - Create and manage batch processing definitions
  • client.batches.executions - Run, monitor, and manage batch executions
  • client.confidence_scoring - Track and analyze confidence scores
  • client.datasources - Manage data source connections
  • client.datasources.data_elements - Manage data elements within datasources
  • client.datasources.downloads - Export datasources as downloadable files
  • client.datasources.file_uploads - Upload and manage content files
  • client.datasources.ingest - Trigger and monitor datasource ingestion
  • client.datasources.tables - Manage table and column descriptions for AI context
  • client.documents - Parse and transform documents into structured data
  • client.metadata_model_catalog - Browse available metadata extraction models
  • client.sessions - View session details across agents