• Stars
    star
    213
  • Rank 185,410 (Top 4 %)
  • Language
    Python
  • License
    MIT License
  • Created almost 10 years ago
  • Updated 12 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Python Wrapper to access the Overpass API

Python Overpass Wrapper

A Python Wrapper to access the Overpass API.

Have a look at the documentation to find additional information.

Latest Version License https://github.com/DinoTools/python-overpy/actions/workflows/ci.yml/badge.svg?branch=master https://coveralls.io/repos/DinoTools/python-overpy/badge.png?branch=master

Features

  • Query Overpass API
  • Parse JSON and XML response data
  • Additional helper functions

Install

Requirements:

Supported Python versions:

  • Python >= 3.6.2
  • PyPy3

Install:

$ pip install overpy

Examples

Additional examples can be found in the documentation and in the examples directory.

import overpy

api = overpy.Overpass()

# fetch all ways and nodes
result = api.query("""
    way(50.746,7.154,50.748,7.157) ["highway"];
    (._;>;);
    out body;
    """)

for way in result.ways:
    print("Name: %s" % way.tags.get("name", "n/a"))
    print("  Highway: %s" % way.tags.get("highway", "n/a"))
    print("  Nodes:")
    for node in way.nodes:
        print("    Lat: %f, Lon: %f" % (node.lat, node.lon))

Helper

Helper methods are available to provide easy access to often used requests.

import overpy.helper

# 3600062594 is the OSM id of Chemnitz and is the bounding box for the request
street = overpy.helper.get_street(
    "Straße der Nationen",
    "3600062594"
)

# this finds an intersection between Straße der Nationen and Carolastraße in Chemnitz
intersection = overpy.helper.get_intersection(
    "Straße der Nationen",
    "Carolastraße",
    "3600062594"
)

License

Published under the MIT (see LICENSE for more information)

More Repositories

1

dionaea

Home of the dionaea honeypot
Python
661
star
2

python-ssdeep

Python wrapper for ssdeep fuzzy hashing library
C
144
star
3

sslscan

SSLScan tests SSL/TLS enabled services to discover supported cipher suites
C
91
star
4

pysslscan

Framework and command-line tool to scan SSL enabled services
Python
35
star
5

python-flextls

Pure Python SSL, TLS and DTLS library
Python
35
star
6

dionaea-docker

Shell
15
star
7

Colorduino_GFX

C++
8
star
8

ArduRPC

RPC library for Arduino and other microcontroller based boards
C++
8
star
9

monitoring-check_routeros

Monitoring plugin for MikroTik devices for Icinga/Nagios/...
Python
8
star
10

monitoring-check_haproxy

Monitoring plugin to check HAProxy with Icinga, Nagios and other compatible monitoring solutions
Perl
7
star
11

Serial-I2C-Tester

Use the serial interface of an Arduino to send data to I2C devices.
Arduino
6
star
12

python-idoit

Wrapper to access the i-doit API
Python
5
star
13

monitoring-check_sophos_xg

Monitoring plugin to check Sophos XG firewalls with Icinga, Nagios and other compatible monitoring solutions
Perl
5
star
14

libemu

C
4
star
15

stftpd

Single-File TFTP Server
Python
4
star
16

liblcfg

This project is only keept for historical reasons
C
3
star
17

monitoring-check_json

Monitoring plugin to check JSON from REST APIs and files with Icinga, Nagios and other compatible monitoring solutions
Python
3
star
18

monitoring-check_network_interface

Monitoring plugin to check network interfaces with Icinga, Nagios and other compatible monitoring solutions
Python
3
star
19

monitoring-check_squid

Perl
2
star
20

ansible-role-dionaea

ansible role to install and/or update dionaea from git
Ruby
2
star
21

ArduRPC-handlers

C++
2
star
22

opkgsync

Python
2
star
23

monitoring-check_disk_io

Monitoring plugin to check disk io with Icinga, Nagios and other compatible monitoring solutions
Python
2
star
24

ArduRPC-python

Python
2
star
25

monitoring-check_systemd_service

Check if a systemd unit is active and report the current active time as perf data. [Mirror]
Perl
2
star
26

ansible-role-raspi_ro_root

Mount the filesystem of an Raspberry PI read-only
Shell
2
star
27

CLTMatrix

C++
2
star
28

monitoring-check_mikrotik

Monitoring plugin for Icinga, Nagios etc. [Mirror] https://git.dinotools.org/monitoring/check_mikrotik
Perl
2
star
29

check_rittal_cmc3

Plugin to monitor Rittal CMC3 devices
Perl
1
star