Skip to content

Release v2.2.1

Choose a tag to compare

@github-actions github-actions released this 13 Aug 18:26
· 15 commits to main since this release

AI Spine SDK v2.2.1

Breaking Changes

  • API key is now required (no default value)
  • API key must start with 'sk_' prefix
  • New exception: InsufficientCreditsError for credit management

New Features

  • Added get_current_user() method to get user info and credits
  • Added check_credits() method to check remaining credits
  • Better error handling for 401, 403, and 429 status codes
  • Support for custom base_url with trailing slash handling

Installation

pip install ai-spine-sdk==2.2.1

Quick Start

from ai_spine import Client

# Initialize with your API key
client = Client(api_key="sk_your_api_key_here")

# Check your credits
credits = client.check_credits()
print(f"Remaining credits: {credits}")

# Execute a flow
result = client.execute_flow("flow_id", {"data": "value"})

Full Changelog: https://github.com/Dataframe-Consulting/ai-spine-sdk-python/commits/v2.2.1