Skip to main content

BBCNews

A python package to get news from BBC.

Installation

pip3 install BBCHeadlines

Usage

Get all top articles of right now:

from BBCHeadlines import news
print(news())

Get the top article:

print(news(limit=1))

Sample response:

[
    {
        "title":"US election: Trump campaign seeks partial recount in Wisconsin",
        "title_detail":{
            "type":"text/plain",
            "language":"None",
            "base":"http://feeds.bbci.co.uk/news/world/rss.xml",
            "value":"US election: Trump campaign seeks partial recount in Wisconsin"
        },
        "summary":"Two counties will be asked to recount votes as Donald Trump continues to contest the election result.",
        "summary_detail":{
            "type":"text/html",
            "language":"None",
            "base":"http://feeds.bbci.co.uk/news/world/rss.xml",
            "value":"Two counties will be asked to recount votes as Donald Trump continues to contest the election result."
        },
        "links":[
            {
                "rel":"alternate",
                "type":"text/html",
                "href":"https://www.bbc.co.uk/news/world-us-canada-54994212"
            }
        ],
        "link":"https://www.bbc.co.uk/news/world-us-canada-54994212",
        "id":"https://www.bbc.co.uk/news/world-us-canada-54994212",
        "guidislink":False,
        "published":"Wed, 18 Nov 2020 18:40:53 GMT",
        "published_parsed":time.struct_time(tm_year=2020,
        tm_mon=11,
        tm_mday=18,
        tm_hour=18,
        tm_min=40,
        tm_sec=53,
        tm_wday=2,
        tm_yday=323,
        tm_isdst=0)
    }
]

Metadata

Release files for BBCHeadlines 4

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

Source distribution (sdist)

Source distribution for BBCHeadlines 4
File Size Uploaded Provenance Actions
BBCHeadlines-4.tar.gz 1.9 kB Without provenance Details for BBCHeadlines-4.tar.gz

Built distribution (wheel)

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

Total release size: 4.8 kB

Release files / BBCHeadlines-4.tar.gz

Download URL BBCHeadlines-4.tar.gz
Size 1.9 kB
Tags Source
SHA-256 checksum
How to use checksums
e0435499354f4aae3459d3e206c201ce37173ebab4c5f010bdf04ae72d280f36
BLAKE2b-256 checksum
How to use checksums
2be2e1f4ecbb31254601806018498d03cfbe15fc0be2d0f1bb297b0a0320c874
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.6.4

Release files / BBCHeadlines-4-py3-none-any.whl

Download URL BBCHeadlines-4-py3-none-any.whl
Size 2.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fcd523b986a7450993f169ee2d79676853c52ef8e915d6e400b35e94d5ef83e1
BLAKE2b-256 checksum
How to use checksums
347b198b26645052feff4a23859ad2a471dee48dae844d972cc399940f0ef04f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.6.4

Security for BBCHeadlines 4

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.

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