Skip to main content

PyPresseportal

A Python interface into the presseportal.de API.

The website presseportal.de is a service provided by ‘news aktuell’, owned by dpa (Deutsche Presse Agentur). It is one of the biggest distributors of press releases and investor relations announcements in Germany. For example, almost all police and fire departments use this service to distribute their press releases.

PyPresseportal is in no way connected to presseportal.de, ‘news aktuell’ or dpa. PyPresseportal is independently developed by volunteers as an Open Source library.

An API key from presseportal.de is required to access data. You can find more information and apply for an API key at https://api.presseportal.de/en.

Quickstart

Installing with pip

Use pip on a command line to download PyPresseportal from PyPI and install it on your system:

$ pip install pypresseportal

Getting an API key

PyPresseportal requires a valid API key from https://api.presseportal.de/en. This website is also where you can find general information on the API as well as the API’s Terms.

Initializing the API

First, create an instance of the PresseportalApi class, using your API key:

>>> from pypresseportal import PresseportalApi
>>> api_object = PresseportalApi(YOUR_API_KEY)

Requesting data

Next, request data from the API through the PresseportalApi class. It contains several methods to access API data, all of which work very similarly.

The easiest way to access the most recently published stories is the get_stories() method. If you do not provide any arguments to this method, PyPresseportal defaults to retrieving the 50 most recent stories available.

For example:

>>> from pypresseportal import PresseportalApi
>>> api_object = PresseportalApi(YOUR_API_KEY)
>>> stories = api_object.get_stories()

get_stories() returns a list of Story objects. Access Story data through the individual Story object’s attributes.

For example:

>>> stories[0].title
"Kohls Wohnhaus hat keinen Denkmalwert"
>>> stories[0].id
"4622388"

Metadata

Release files for pypresseportal 0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pypresseportal 0.1
File Size Uploaded Provenance
pypresseportal-0.1.tar.gz 11.8 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for pypresseportal 0.1
File Interpreter ABI Platform
pypresseportal-0.1-py3-none-any.whl Python 3 none any Details

Total release size: 24.8 kB

Release files / pypresseportal-0.1.tar.gz

Download URL pypresseportal-0.1.tar.gz
Size 11.8 kB
Tags Source
SHA-256 checksum
How to use checksums
bd5088daacdcbd4af4f6358d42c822a293c43f44fb58507cea3cda4bec5ba069
BLAKE2b-256 checksum
How to use checksums
d131fc884265719accba5620978d207e7c5120ad41539d6228a3f06187259cb3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

Release files / pypresseportal-0.1-py3-none-any.whl

Download URL pypresseportal-0.1-py3-none-any.whl
Size 13.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0456d949d2063cd10e925ec05265fb70a0d46dde9a5be33ebb8e7ccb0ab45c84
BLAKE2b-256 checksum
How to use checksums
52e393eb46448bf6315b1beaedd0b4e325c47bbdf05d7d340bb5f9e3b34d19ac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

Security for pypresseportal 0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page