copyright (c) 2025 e-dream, inc
the project and application has generally been renamed from e-dream to infinidream. this module, however, has not yet been renamed, but it works fine with the current servers.
If you need to setup locally to test or run code, follow BUILD.md documentation.
Get an API key from your profile on the server, and store it in a .env file. Then connect as follows:
import os
from dotenv import load_dotenv
from edream_sdk.client import create_edream_client
load_dotenv()
edream_client = create_edream_client(
backend_url=os.getenv("BACKEND_URL", "https://api-alpha.infinidream.ai/api/v1"),
api_key=os.getenv("API_KEY")
)
user = edream_client.get_logged_user()
print(user)There's a file to test api client:
python tests/run.pythis file has an example of every API call.
Generate dreams using AI algorithms:
# Available algorithms
python tests/gen.py --algo animatediff # AnimateDiff video generation
python tests/gen.py --algo deforum # Deforum video generation
python tests/gen.py --algo uprez # Video upscaling
python tests/gen.py --algo qwen-image # Qwen image generation
python tests/gen.py --algo wan-t2v # Wan text-to-video generation
python tests/gen.py --algo wan-i2v # Wan image-to-video generation (uses image dream UUID)
python tests/gen.py --algo wan-i2v-lora # Wan image-to-video with LoRA (uses image dream UUID)The script will create the dream, poll for completion, and display the video/image URL when ready.
This Python SDK just wraps the servers' REST API. Its documentation is served by swagger on staging.