Skip to main content

yelpapi

Tests

LICENSE

This software is licensed under the BSD 3-Clause License. Please refer to the separate LICENSE file for the exact text of the license. You are obligated to give attribution if you use this code.

ABOUT

yelpapi is a pure Python implementation of Yelp's public REST APIs, including the Yelp Places API, the Yelp AI API, Yelp Insights, and the Home Services API. It is simple, fast, and robust to any changes Yelp may make to its APIs in the future.

REQUIREMENTS

This code requires Python 3.11 or higher and requests.

INSTALL

yelpapi is available on PyPI at https://pypi.org/project/yelpapi/.

Install using pip:

pip install yelpapi

USING THIS CODE

This API is demonstrated more thoroughly in examples.py, but the following chunk of code demonstrates basic use of yelpapi:

from yelpapi import YelpAPI
with YelpAPI(api_key) as yelp_api:
    search_results = yelp_api.search_query(term='ice cream', location='austin, tx')

You can also set timeouts so API calls do not block indefinitely in degraded network conditions:

from yelpapi import YelpAPI
with YelpAPI(api_key, timeout_s=3.0) as yelp_api:
    search_results = yelp_api.search_query(term='ice cream', location='austin, tx')

Under the covers, this module uses a requests.Session object for issuing all API calls, which offers potentially significant performance benefits over issuing separate API calls outside of a session. You should be sure to close the underlying session when all API interactions are complete. The above examples demonstrate using the class as a context manager, which will automatically close the connection when you're done and is the preferred way of using the class, but you can also manually close it like this if a context manager won't work for your use case:

from yelpapi import YelpAPI
yelp_api = YelpAPI(api_key)
try:
    search_results = yelp_api.search_query(term='ice cream', location='austin, tx')
finally:
    yelp_api.close()

METHODS

Yelp's GraphQL API is not wrapped, since it uses GraphQL queries rather than REST parameters.

Metadata

Release files for yelpapi 2.8.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 yelpapi 2.8.0
File Size Uploaded Provenance Actions
yelpapi-2.8.0.tar.gz 24.0 kB With provenance Details for yelpapi-2.8.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for yelpapi 2.8.0
File Interpreter ABI Platform Actions
yelpapi-2.8.0-py3-none-any.whl Python 3 none any Details for yelpapi-2.8.0-py3-none-any.whl

Total release size: 36.6 kB

Release files / yelpapi-2.8.0.tar.gz

Download URL yelpapi-2.8.0.tar.gz
Size 24.0 kB
Tags Source
SHA-256 checksum
How to use checksums
d28fa934a96622abb8e1401ea2a70dd67e383cfd6480f084ec7d7ed876be2ede
BLAKE2b-256 checksum
How to use checksums
f94a9359f2d4ae58f6a8d6e3fe38ee860f3144f1cb4cd206866d4a78182e82a7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

Release files / yelpapi-2.8.0-py3-none-any.whl

Download URL yelpapi-2.8.0-py3-none-any.whl
Size 12.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f4148d15cf703fc873c69048253938ab9cd2a71b1cf036f31af3f63f51e71fc7
BLAKE2b-256 checksum
How to use checksums
5512b38ccd90780d44528a8545ecfa15ab30b899f3877e089ff79762d16cc57c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

Security for yelpapi 2.8.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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for yelpapi-2.8.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

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.

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