Skip to main content

api-ulp

A simple Python client for the ULP search API.

Installation

pip install api-ulp

Requirements

  • Python 3.7+
  • requests >= 2.20.0

Quick Start

from api_ulp import ApiUlp

client = ApiUlp(api_key="YOUR_API_KEY")
results = client.search(query="hello world", limit=10)
print(results)

Usage

Initialize the client

from api_ulp import ApiUlp

client = ApiUlp(api_key="YOUR_API_KEY")
Parameter Type Required Description
api_key str Yes Your ULP API key

search(query, limit)

Performs a POST search request against the ULP API.

results = client.search(query="search_target", limit=100)
print(results)
Parameter Type Required Default Description
query str Yes — The search term / target
limit int No 100 Maximum number of results to return

Returns: dict — Parsed JSON response from the API.


Error Handling

import requests
from api_ulp import ApiUlp

client = ApiUlp(api_key="YOUR_API_KEY")

try:
    results = client.search(query="hello", limit=50)
    print(results)
except ValueError as e:
    # Bad arguments (empty query, invalid limit, missing key)
    print(f"Invalid input: {e}")
except requests.exceptions.HTTPError as e:
    # API returned 4xx or 5xx
    print(f"API error: {e}")
except requests.exceptions.ConnectionError as e:
    # Could not reach the server
    print(f"Connection error: {e}")
except requests.exceptions.Timeout as e:
    # Request took longer than 30 seconds
    print(f"Timeout: {e}")

API Details

Property Value
Endpoint POST https://api-1-wi9u.onrender.com/api/search
Auth Header X-API-Key: YOUR_KEY
Content-Type application/json
Timeout 30 seconds

Raw request equivalent

import requests

url = "https://api-1-wi9u.onrender.com/api/search"
headers = {"X-API-Key": "YOUR_KEY", "Content-Type": "application/json"}
data = {"query": "search_target", "limit": 100}

response = requests.post(url, headers=headers, json=data)
print(response.json())

License

MIT

Metadata

Release files for api-ulp 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for api-ulp 0.1.0
File Size Uploaded Provenance
api_ulp-0.1.0.tar.gz 2.9 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for api-ulp 0.1.0
File Interpreter ABI Platform
api_ulp-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 6.3 kB

Release files / api_ulp-0.1.0.tar.gz

Download URL api_ulp-0.1.0.tar.gz
Size 2.9 kB
Tags Source
SHA-256 checksum
How to use checksums
ea172436eab92a0ffb3de90313b1b6fceb7385b014f330a9252db92309997d71
BLAKE2b-256 checksum
How to use checksums
dd4c786f4753c4f8b4b4dc87bef52bb8b3fd19645c41b2daf078d1ef39bd1a5e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Release files / api_ulp-0.1.0-py3-none-any.whl

Download URL api_ulp-0.1.0-py3-none-any.whl
Size 3.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2d51f0bdec1f9c2562beec3fedc2a01090d6d3025656b15a828a9506f647ee63
BLAKE2b-256 checksum
How to use checksums
41344f942531a5bac8ab0df132331502baa71739ae175cbcef370f0bb1bf25e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Security for api-ulp 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

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