Skip to main content

Une bibliothèque Python pour interagir avec l'API de Newswacafi.

Project description

Newswacafi

Description

NEWSwacafi est une initiative innovante destinée à fournir aux décideurs et analystes une compréhension approfondie des dynamiques au Sahel. En exploitant la puissance du web scraping et des analyses de données avancées, notre plateforme offre des insights précieux pour anticiper les tensions et conflits.

Cette librairie permet d'exploiter l'API de Newswacafi avec Python.

Installation

pip install newswacafi

Utilisation

from newswacafi.api import NewswacafiClient
from datetime import date

client = NewswacafiClient(
    api_key="6a07a7ee-***-b4504ebc0e68",
    api_secret="pbkdf2_sha256$6000***+g1R2MDOzS/QMoJstT6bWZTTVTcQlQ3cc="
)

news = client.get_news(
    start_date=date(2024, 1, 1), 
    end_date=date(2024, 2, 1), 
    country=['bf', 'ne'], 
    category=['politique'], 
    source=['lefaso.net', 'levenementniger.com']
)

print(news.data[0].title)

License

MIT

Project details


Download files

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

Source Distribution

newswacafi-0.5.tar.gz (2.9 kB view details)

Uploaded Source

Built Distribution

newswacafi-0.5-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file newswacafi-0.5.tar.gz.

File metadata

  • Download URL: newswacafi-0.5.tar.gz
  • Upload date:
  • Size: 2.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.7

File hashes

Hashes for newswacafi-0.5.tar.gz
Algorithm Hash digest
SHA256 e14a20f2476f4b75f7142cfa895b8af898ae24366a234d3b5921a829d1be9b18
MD5 2bb0eb6423320a684752e2210047a719
BLAKE2b-256 913c2e33eb484c4f43b93f54f470e65e84a218ac9aca5a6c903f1925bac66cc9

See more details on using hashes here.

File details

Details for the file newswacafi-0.5-py3-none-any.whl.

File metadata

  • Download URL: newswacafi-0.5-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.7

File hashes

Hashes for newswacafi-0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 75f9b41f4411f91a8ed2bfab42ccf9dba314845928324aa072ae17c095a23167
MD5 ceb41da6bc9bef313b4b300f271f2db7
BLAKE2b-256 81be0903181916433fee26781aeb9f86d4bc9b3105644e3dba29c8ad159d8ebe

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page