A Python wrapper for Yelp API
Project description
ezapi-yelp
A Python wrapper for Yelp Fusion API
Install
From PyPi
pip install ezapi-yelp
From GitHub
pip install git+https://github.com/zehengl/ezapi-yelp.git
Usage
from yelp import YelpFusion
token = "..."
yelp_fusion = YelpFusion(token)
print(yelp_fusion.business_search(location="San Francisco"))
print(yelp_fusion.transaction_search("delivery", location="San Francisco"))
print(yelp_fusion.business_details("WavvLdfdP6g8aZTtbBQHTw"))
print(
yelp_fusion.business_match(
name="Gary Danko",
address1="800 N Point St",
city="San Francisco",
state="CA",
country="US",
)
)
print(yelp_fusion.reviews("WavvLdfdP6g8aZTtbBQHTw"))
print(
yelp_fusion.autocomplete(
text="Gary Danko", latitude=37.80587, longitude=-122.42058
)
)
print(yelp_fusion.all_categories())
print(yelp_fusion.category_details("hotdogs"))
print(yelp_fusion.event_lookup("oakland-saucy-oakland-restaurant-pop-up"))
print(yelp_fusion.event_search(location="Oakland"))
print(yelp_fusion.featured_event(location="Oakland"))
Test
git clone git@github.com:zehengl/ezapi-yelp.git
cd ezapi-yelp
export yelp_token="..."
python -m venv .venv
source .venv/bin/activate
pip install -e .
pip install -r requirements-test.txt
pytest
Use $Env:yelp_token="..."
to set the api key environment variable on Windows.
Credits
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ezapi-yelp-0.4.10.tar.gz
(8.7 kB
view details)
Built Distribution
File details
Details for the file ezapi-yelp-0.4.10.tar.gz
.
File metadata
- Download URL: ezapi-yelp-0.4.10.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fc808cd8b4c05f9bf57ec08052ce0d3188d7dc0ad2e8b87cac97c6e0855ffccf |
|
MD5 | 3b4aaeff14bc080ac0e246a28ac87f0e |
|
BLAKE2b-256 | d35947d713018d7b1e3a9d0069df440f4af9d58c853de8880b83ba3320d6d829 |
File details
Details for the file ezapi_yelp-0.4.10-py3-none-any.whl
.
File metadata
- Download URL: ezapi_yelp-0.4.10-py3-none-any.whl
- Upload date:
- Size: 4.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ca776f6f10ed55e9f549d807d82da8aad25dbd2849f112f3beffed43efc8b15d |
|
MD5 | a8114d2d72a88ac126d30717347f445b |
|
BLAKE2b-256 | f200a4cf49791b7b581af6b8146898446ee68f78fb03ba54a8d1c3666d5799e0 |