Skip to main content

Client for the Offenes Köln API

Project description

Offenes Köln is a platform that allows for flexible access
to the content of the City of Cologne/Germany's city council information system.

Find more information about the platform at

More detailed information on the REST API is available at


pip install okclient

**Quick start**

import okclient
oc = okclient.Client()

# Search for documents containing "Haushalt"
result = oc.documents(query="haushalt")
for doc in result:
print, doc.title

# Retrieve the document with identifier "3323/2008"
# including attachments and thumbnails
result = oc.documents("3323/2008", attachments=True,
print result[0].date, result[0].title
print result[0].attachments[0].url
print result[0].attachments[0].content

# Find streets surrounding a geo position
# (reverse geocoding)
streets = oc.streets(lat=50.959, lon=6.946)
for street in streets:
(name, distance) = street
print "%s is %d meters away" % (name, distance)

# Find position of street "Mittelstraße"
# (also called geocoding)
mittelstr = oc.locations("Mittelstraße")
# return quasi-centroid of that street
print mittelstr.averages[0]
# print out all nodes of that streets
for node in mittelstr.nodes:
print node


Feel free to give feedback via the Issue tracking at

**Stay tuned**

Stay informed about changes in this client and the API by following our
commits on Github (see URL above), reading our Blog and/or following
the twitter account.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for okclient, version 0.3
Filename, size File type Python version Upload date Hashes
Filename, size okclient-0.3.tar.gz (4.9 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page