Costco
Costco 매장 찾기 API
미국 우편번호나 위도와 경도 근처의 코스트코 매장: 주소, 전화번호, 거리, 매장·약국·타이어 센터 영업시간, 부서, 서비스, 주유소 영업시간과 가격. 요청당 1크레딧, costco.ca에서는 2크레딧입니다.
POST/api/v1/costco/warehouses
Authorizations
AuthorizationstringheaderrequiredBearer authentication header of the form Bearer <token>, where <token> is your Scavio API key (e.g. Bearer sk_live_your_key).
Body
application/jsonzipstring미국 우편번호. zip, 또는 latitude와 longitude를 보내세요.
Example: 10025
latitudenumber위도, -90에서 90. 미국 이외 지역에서는 longitude와 함께 사용하세요.
Example: 40.7993
longitudenumber경도, -180에서 180.
Example: -73.9668
limitintegerdefault:10반환할 가장 가까운 매장 수, 1-50.
Example: 5
countryenum<string>default:us코스트코 사이트. us와 ca는 모든 파라미터를 지원하며, uk, au, mx, jp, kr, tw는 키워드, 정렬, 페이지 이동만 지원합니다.
Example: uk
us— costco.com, 미국.ca— costco.ca, 캐나다.uk— 영국.au— 호주.mx— 멕시코.jp— 일본.kr— 한국.tw— 대만.
Request
from scavio import ScavioClient
client = ScavioClient(api_key="sk_live_your_key")
nearby = client.costco.warehouses(zip="10025", limit=5)
for w in nearby["data"]["warehouses"]:
gas = w["gas_station"]
print(w["warehouse_id"], w["name"], w["distance_miles"], gas and gas["prices"]["regular"])Response
"country": "us",
"count": 5,
},
"response_time": 2315
}