Scraping Go To Travel Accommodation

For a list of accommodations in Go To Travel

https://goto.jata-net.or.jp/assets/data/stay.csv

Since there is csv data in, you can get it without scraping

Development tools

https://developer.mozilla.org/ja/docs/Tools

You can check the request contents on the network monitor

stay_csv.png

import pandas as pd

df = pd.read_csv("https://goto.jata-net.or.jp/assets/data/stay.csv")

df["Prefectures"].value_counts()
Prefectures
Tokyo 2551
Nagano Prefecture 2328
Kyoto 2235
Hokkaido 1965
Okinawa Prefecture 1886
Shizuoka Prefecture 1629
Osaka 1494
Kanagawa Prefecture 1018
Yamanashi Prefecture 956
Hyogo prefecture 904
Chiba 864
Niigata Prefecture 855
Aichi prefecture 833
Gunma Prefecture 806
Fukuoka Prefecture 783
Tochigi Prefecture 715
Gifu Prefecture 661
Oita Prefecture 647
Fukushima Prefecture 631
Kagoshima prefecture 549
Kumamoto Prefecture 537
Mie Prefecture 525
Ishikawa Prefecture 521
Wakayama Prefecture 484
Hiroshima Prefecture 444
Yamagata Prefecture 409
Miyagi Prefecture 407
Nagasaki Prefecture 385
Ibaraki Prefecture 364
Fukui prefecture 352
Iwate Prefecture 335
Kagawa Prefecture 328
Okayama Prefecture 327
Saitama 312
Nara Prefecture 298
Ehime Prefecture 295
Shiga Prefecture 287
Toyama Prefecture 259
Shimane Prefecture 240
Kochi Prefecture 225
Tottori prefecture 221
Miyazaki prefecture 221
Aomori Prefecture 220
Akita 204
Yamaguchi Prefecture 201
Tokushima Prefecture 184
Saga Prefecture 168

Recommended Posts

Scraping Go To Travel Accommodation
Scraping 2 How to scrape
Connect to Postgresql with GO
How to define Go variables
[Go] How to use "... (3 periods)"
Scraping, preprocessing and writing to postgreSQL
Post to slack in Go language
How to install Go on Ubuntu
10 questions to check before web scraping