Registry / llm-agents / asknews

asknews

JSON →
library0.13.51pypypi✓ verified 83d ago

Python SDK for AskNews, providing access to news aggregation and analysis APIs. Current version: 0.13.40. Release cadence: frequent (multiple per month).

pip install asknews
INSTALL
IMPORT
SIG · ASKNEWS
A
asknews
llm-agentspythonv0.13.51
Install
7.0s avg
Import
Disk
50MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.13.51 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 50.8MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 7.0s · import 0.000s · 50MB
50MB installed
● package 50MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

AskNewsSDK
from asknews_sdk import AskNewsSDK
from asknews import AskNews
AsyncAskNewsSDK
from asknews_sdk import AsyncAskNewsSDK

Initialize client with environment variables and fetch news articles.

import os from asknews import AskNews client = AskNews( api_key=os.environ.get('ASKNEWS_API_KEY', ''), user_id=os.environ.get('ASKNEWS_USER_ID', '') ) news = client.news.search_news(query='AI', return_type='articles') print(news)
Debug
Known issues
breakingIn v0.13.0, the SDK migrated from 'asknews_sdk' to 'asknews' package. Imports and API structure changed.
fix
Uninstall old package (pip uninstall asknews-sdk) and install asknews (pip install asknews). Update imports from asknews_sdk to asknews.
affects: <0.13.0
gotchaThe API key and user ID must be provided together. Missing either will cause authentication failure.
fix
Set both environment variables: ASKNEWS_API_KEY and ASKNEWS_USER_ID.
affects: all
gotchaThe search_news method's 'return_type' parameter defaults to 'articles', but some endpoints expect 'story' or 'alert'. Using wrong type may return empty results.
fix
Check the API docs for the correct return_type value for your query.
affects: all
Upgrade
Version history
0.13.51latest on PyPI · released May 30, 2026
Audit
Dependencies
httpxrequiredHTTP client used for API requests
pydanticrequireddata validation and settings management
Agent activity
38 hits · last 30 days
node
30
Perplexity
1
OpenAI (training)
1
Resources
asknews — pip install asknews · libregistry