https://github.com/fcakyon/earth2-scraper
Up-to-date earth2.io data
https://github.com/fcakyon/earth2-scraper
data earth earth2 earth2io javascript json json-api prices-per-tile python scraper
Last synced: 9 months ago
JSON representation
Up-to-date earth2.io data
- Host: GitHub
- URL: https://github.com/fcakyon/earth2-scraper
- Owner: fcakyon
- Created: 2021-02-19T09:00:04.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2021-03-08T08:38:25.000Z (almost 5 years ago)
- Last Synced: 2025-02-08T09:47:17.735Z (10 months ago)
- Topics: data, earth, earth2, earth2io, javascript, json, json-api, prices-per-tile, python, scraper
- Language: Python
- Homepage:
- Size: 6.76 MB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Earth2.io Scraper
Up-to-date [earth2.io](https://earth2.io/) data

# Details
- [earth2.io](https://earth2.io/) data `(tile prices per country)` is automatically scraped and hosted in this repo daily.
- As an example, you can access to the scraped info of Italy `(IT)` for 20th February 2021 `(20210220)` at:
[https://raw.githubusercontent.com/fcakyon/earth2-scrapper/main/data/20210220/IT](https://raw.githubusercontent.com/fcakyon/earth2-scrapper/main/data/20210220/IT)
# Consuming API
When your backend is in Python i.e. in Django/Flask/FastAPI, you can access the JSON file’s data as shown below:
```python
import urllib.request, json
github_link = "https://raw.githubusercontent.com/fcakyon/earth2-scrapper/main/data/20210220/IT"
with urllib.request.urlopen(github_link) as url:
json_data = json.loads(url.read().decode())
print(json_data)
```
And if you want data in JavaScript using JQuery/React, you can access the JSON file’s data as shown below:
```js
let github_link = "https://raw.githubusercontent.com/fcakyon/earth2-scrapper/main/data/20210219/IT";
$.getJSON(github_link, function(data) {
//data is the JSON string
console.log(data);
});
```