Restaurant Health Inspection Data

7 views
Skip to first unread message

Shawn Looker

unread,
Jan 21, 2014, 11:57:25 AM1/21/14
to code-fo...@googlegroups.com
James,

I talked to our contact at the city and he told us that health inspections are county level, but he'd be getting us a contact.  That being said, you can get some data directly with some finagling.

http://www.southernnevadahealthdistrict.org/restaurants/stores/restaurants.php will give you the "front page" of the health inspection site.

To look up a specific address I got this from the "copy curl request" via chrome's inspector, after doing a search for "Siri Thai" (Which is the best thai restaurant ever).

curl 'http://www.southernnevadahealthdistrict.org/restaurants/stores/restaurants.php' -H 'Origin: http://www.southernnevadahealthdistrict.org' -H 'Accept-Encoding: gzip,deflate,sdch' -H 'Host: www.southernnevadahealthdistrict.org' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36' -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' -H 'Accept: */*' -H 'Referer: http://www.southernnevadahealthdistrict.org/restaurants/inspections.php' -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' --data 'start=0&limit=20&reload=true&category_id=0&search_type=contains&restaurant_hotel=&restaurant_name=siri%20thai&restaurant_address=&current_grade=Z&restaurant_city=0&restaurant_zipcode=' --compressed

From there, you can abbreviate down to this:


If you want to search a specific location, just add back restaurant_name inside the data on the curl.

Hope this helps!
Shawn

James Estevez

unread,
Jan 21, 2014, 6:53:36 PM1/21/14
to code-fo...@googlegroups.com
Neat. Thanks for looking into this.

Cheers,
--
James Estevez

On 2014-01-21 08:57:25 PST Shawn Looker wrote:
> James,
>
> I talked to our contact at the city and he told us that health
> inspections are county level, but he'd be getting us a contact. That
> being said, you can get some data directly with some finagling.
>
> http://www.southernnevadahealthdistrict.org/restaurants/stores/restaurants.php will
> give you the "front page" of the health inspection site.
>
> To look up a specific address I got this from the "copy curl request"
> via chrome's inspector, after doing a search for "Siri Thai" (Which is
> the best thai restaurant ever).
>
> curl
> 'http://www.southernnevadahealthdistrict.org/restaurants/stores/restaurants.php'
> -H 'Origin: http://www.southernnevadahealthdistrict.org' -H
> 'Accept-Encoding: gzip,deflate,sdch' -H 'Host:
> www.southernnevadahealthdistrict.org
> <http://www.southernnevadahealthdistrict.org>' -H 'Accept-Language:
> en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64)
> AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63
> Safari/537.36' -H 'Content-Type: application/x-www-form-urlencoded;
> charset=UTF-8' -H 'Accept: */*' -H 'Referer:
> http://www.southernnevadahealthdistrict.org/restaurants/inspections.php'
> -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' --data
> 'start=0&limit=20&reload=true&category_id=0&search_type=contains&restaurant_hotel=&restaurant_name=siri%20thai&restaurant_address=&current_grade=Z&restaurant_city=0&restaurant_zipcode='
> --compressed
>
> From there, you can abbreviate down to this:
>
> curl
> 'http://www.southernnevadahealthdistrict.org/restaurants/stores/restaurants.php'
> --data 'start=0&limit=2'
>
> If you want to search a specific location, just add back restaurant_name
> inside the data on the curl.
>
> Hope this helps!
> Shawn
>
> --
> You received this message because you are subscribed to the Google
> Groups "Code For Vegas" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to code-for-vega...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.

Shawn Looker

unread,
Jan 21, 2014, 7:01:38 PM1/21/14
to James Estevez, code-fo...@googlegroups.com
Sure thing!  I'll let you know when I have some information for a county contact.

Shawn



For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups "Code For Vegas" group.
To unsubscribe from this group and stop receiving emails from it, send an email to code-for-vegas+unsubscribe@googlegroups.com.

Ishmael Thomas

unread,
Jan 22, 2014, 10:44:24 AM1/22/14
to code-fo...@googlegroups.com
Thanks!!!
Reply all
Reply to author
Forward
0 new messages