Skip to main content

Haystack Enterprise SDK

Haystack Enterprise SDK

Experimental. This SDK is under active development. APIs and CLI commands may change without notice.

Python SDK and CLI for the Haystack Enterprise Platform.

Installation

Not published to a package registry yet — install directly from this repository with uv:

# Install as a CLI tool
uv tool install git+https://github.com/deepset-ai/haystack-enterprise-sdk.git

# Or add it as a dependency of your project
uv add git+https://github.com/deepset-ai/haystack-enterprise-sdk.git

Usage

haystack-enterprise --help

Authentication

haystack-enterprise login
haystack-enterprise logout

Files

# Upload a folder to a workspace
haystack-enterprise upload ./my-files

# List files in a workspace
haystack-enterprise list-files

# Download files to your local machine
haystack-enterprise download

Pipelines

# Validate a local pipeline against the platform
haystack-enterprise validate ./pipeline.py

# Run a local pipeline in the platform sandbox (shows a spinner with the elapsed time while it waits)
haystack-enterprise run ./pipeline.py

# Transient failures (network errors, timeouts, 429, 5xx) are retried twice by default; 0 disables it.
# Config and input errors always fail immediately.
haystack-enterprise run ./pipeline.py --retries 0

# Deploy a local pipeline as a service deployment (reused if it exists, otherwise created serverless).
# Asks at most which socket receives the query and which is the main output -- and nothing at all when
# your socket names already say so. Prints the service's chat-completions endpoint once it is serving.
haystack-enterprise deploy ./pipeline.py my-service

# Create a managed (provisioned) service instead, with explicit sizing
haystack-enterprise deploy ./pipeline.py my-service --managed --cpu 2 --memory 4Gi

# Deploy and get a shareable prototype link (a chat UI). Because that UI routes through the pipeline's
# input/output mapping, --share is also what asks you to review the mapping.
haystack-enterprise deploy ./pipeline.py my-service --share

# Check the status of a service deployment
haystack-enterprise service-status my-service

Calling a deployed service

A deployed service is served over an OpenAI-compatible chat-completions endpoint, which deploy prints once the service is running:

curl -N https://api.cloud.deepset.ai/api/v1/workspaces/<workspace>/deployments/<deployment-id>/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "<workspace>/<service-name>", "messages": [{"role": "user", "content": "Hello"}]}'

The response is a server-sent-event stream of chat.completion.chunk objects. Any OpenAI client works — point its base_url at everything up to and including /deployments/<deployment-id>.

Pass --verbose to any command for INFO/DEBUG logs, and <command> --help for its arguments.

Development

# Install uv if you don't have it
pip install uv

# Sync all dependencies (including dev dependencies)
uv sync --all-groups

# Run the CLI from source
uv run haystack-enterprise --help

See CONTRIBUTING.md for contribution guidelines.

Licenses

The SDK is licensed under Apache 2.0, see LICENSE.

Some bundled libraries are licensed under the MPL 2.0 license:

  • tqdm for progress bars
  • pathspec for pattern matching file paths
  • certifi for validating trustworthiness of SSL certificates

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

haystack_enterprise_sdk-0.1.0.tar.gz (117.0 kB view details)

Uploaded Source

Built Distribution

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

haystack_enterprise_sdk-0.1.0-py3-none-any.whl (137.0 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: haystack_enterprise_sdk-0.1.0.tar.gz
  • Upload date:
  • Size: 117.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for haystack_enterprise_sdk-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2b96407948b0483c03038c66c810ba37fa6f149be599204667095facc5040d54
MD5 554262fc207f5cdc955c6723c1acbfc5
BLAKE2b-256 54955ccf0a2168555b894a87976c2c29a6cb3f841cbdb3fa7a61e4140dd77a36

See more details on using hashes here.

Provenance

The following attestation bundles were made for haystack_enterprise_sdk-0.1.0.tar.gz:

Publisher: CI_pypi_release.yml on deepset-ai/haystack-enterprise-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

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

File metadata

File hashes

Hashes for haystack_enterprise_sdk-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fa6dde9a1dbc54a2a9bb1d39498e9c465180d4ba584806b6ec65fe60bd186240
MD5 fc2206ac0d66839d69d2ebce63e1bba4
BLAKE2b-256 883a76f2537adb6ab38350c66ad22dabee25cc57acafda25f8e8afbfe2c1a69f

See more details on using hashes here.

Provenance

The following attestation bundles were made for haystack_enterprise_sdk-0.1.0-py3-none-any.whl:

Publisher: CI_pypi_release.yml on deepset-ai/haystack-enterprise-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.1.2

2 files

This release

0.1.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page