具
Zippopotam.us API
2 endpointsUtilitiesGlobalsocial:read2 real examples
Returns places, states and coordinates for a postal code, and postal codes with positions for a city in a state.
View as Markdown| GET | /zippopotam/lookup | The places of one postal code in one country, with their state and position. |
| GET | /zippopotam/city | The postal codes of one city or town in a state or province, with the position of each. |
lookup
GET
/v1/zippopotam/lookupThe places of one postal code in one country, with their state and position.
scope social:read1 unitcached 24 h
Parameters
countrystring required | ISO 3166 country code, such as us or de. e.g. us |
postcodestring required | Postal code, such as 90210. e.g. 90210 |
tunnelstring | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
proxystring | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
profileIdstring | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |
Response data
9 fields
country | string |
countryCode | string |
places | Place[] |
latitude | number (double) |
longitude | number (double) |
name | string |
state | string |
stateCode | string |
postcode | string |
curl "https://api.hoshime.com/v1/zippopotam/lookup?country=us&postcode=90210" \ -H "Authorization: Bearer $HOSHIME_TOKEN"
const res = await fetch("https://api.hoshime.com/v1/zippopotam/lookup?country=us&postcode=90210", { headers: { Authorization: `Bearer ${process.env.HOSHIME_TOKEN}`, }, }); const { data, meta } = await res.json();
import os, requests res = requests.get( "https://api.hoshime.com/v1/zippopotam/lookup?country=us&postcode=90210", headers={"Authorization": f"Bearer {os.environ['HOSHIME_TOKEN']}"}, ) body = res.json()
{ "data": { "country": "United States", "countryCode": "US", "places": [ { "latitude": 34.0901, "longitude": -118.4065, "name": "Beverly Hills", "state": "California", "stateCode": "CA" } ], "postcode": "90210" }, "meta": { "cached": false, "endpoint": "lookup", "fetchedAt": "2026-11-06T09:41:00Z", "platform": "zippopotam", "requestId": "req_2Xb9kQ…", "units": 1 } }
city
GET
/v1/zippopotam/cityThe postal codes of one city or town in a state or province, with the position of each.
scope social:read1 unitcached 24 h
Parameters
countrystring required | ISO 3166 country code, such as us. e.g. us |
statestring required | State or province code, such as ca. e.g. ca |
citystring required | City or town name, such as beverly hills. e.g. beverly hills |
tunnelstring | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
proxystring | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
profileIdstring | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |
Response data
10 fields
country | string |
countryCode | string |
placeName | string |
places | CityPlace[] |
latitude | number (double) |
longitude | number (double) |
placeName | string |
postCode | string |
state | string |
stateCode | string |
curl "https://api.hoshime.com/v1/zippopotam/city?country=us&state=ca&city=beverly+hills" \ -H "Authorization: Bearer $HOSHIME_TOKEN"
const res = await fetch("https://api.hoshime.com/v1/zippopotam/city?country=us&state=ca&city=beverly+hills", { headers: { Authorization: `Bearer ${process.env.HOSHIME_TOKEN}`, }, }); const { data, meta } = await res.json();
import os, requests res = requests.get( "https://api.hoshime.com/v1/zippopotam/city?country=us&state=ca&city=beverly+hills", headers={"Authorization": f"Bearer {os.environ['HOSHIME_TOKEN']}"}, ) body = res.json()
{ "data": { "country": "United States", "countryCode": "US", "placeName": "Beverly Hills", "places": [ { "latitude": 33.7866, "longitude": -118.2987, "placeName": "Beverly Hills", "postCode": "90209" }, { "latitude": 34.0901, "longitude": -118.4065, "placeName": "Beverly Hills", "postCode": "90210" } ], "state": "California", "stateCode": "CA" }, "meta": { "cached": false, "endpoint": "city", "fetchedAt": "2026-11-06T09:41:00Z", "platform": "zippopotam", "requestId": "req_2Xb9kQ…", "units": 1 } }