Skip to main content

Search1API Python SDK

Official synchronous and asynchronous Python clients for Search1API.

API documentation: search1api.com/docs

Install

pip install search1api

Search

from search1api import Search1API

client = Search1API()  # reads SEARCH1API_API_KEY
response = client.search(
    "latest AI agent frameworks",
    max_results=10,
    crawl_results=3,
)

for result in response["results"]:
    print(result["title"], result["link"])

Use the client as a context manager when it owns the HTTP connection pool:

with Search1API("your-api-key") as client:
    print(client.usage())

Async

from search1api import AsyncSearch1API

async with AsyncSearch1API() as client:
    response = await client.search("latest AI agent frameworks")

Deepcrawl

deepcrawl starts a task and waits for it to finish:

result = client.deepcrawl("https://example.com", type="all")
print(result["zipUrl"])

Use start_deepcrawl, get_deepcrawl_status, and wait_for_deepcrawl when the application needs to control persistence or polling itself.

The clients also support news, crawl, sitemap, trending, extract, usage, and batch operations exposed by the Search1API HTTP API. Requests time out after 30 seconds and retry 429 and transient 5xx responses twice by default. Authentication, payment, and validation errors are never retried. Deepcrawl task creation is not retried automatically because it is not idempotent.

Development

python -m venv .venv
. .venv/bin/activate
python -m pip install -e ".[dev]"
ruff format --check .
ruff check .
mypy src/search1api
pytest
python -m build

The checked-in OpenAPI snapshot is used to verify that the client covers every public operation.

License

MIT

Download files

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

Source Distribution

search1api-0.1.0.tar.gz (14.0 kB view details)

Uploaded Source

Built Distribution

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

search1api-0.1.0-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for search1api-0.1.0.tar.gz
Algorithm Hash digest
SHA256 bcea73f71f080a4c60af62c8bb4b0b046ea748590145985335c3ea886c4ebd75
MD5 d858adf0c85a8b9253412be503387639
BLAKE2b-256 89b6b5c0db9ce05e0fae27cfec508ddc1ee0ed897b836d15590167f489d21463

See more details on using hashes here.

Provenance

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

Publisher: release.yml on superagents-lab/search1api-python

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

File details

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

File metadata

  • Download URL: search1api-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for search1api-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 dab594d9e217322dfc74249022876ab3855e38ea3b3e44de0a58957fc43f7dc9
MD5 b8f7b5db9a7dec8e5c8a96a89e6be3fd
BLAKE2b-256 c40b7004cbb504a4c18edb70af12d940acc0edea7b1e844f33b621313809fa3d

See more details on using hashes here.

Provenance

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

Publisher: release.yml on superagents-lab/search1api-python

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.2.1

2 files

0.2.0

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