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.7.tar.gz (3.0 kB view details)

Uploaded Source

File details

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

File metadata

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

File hashes

Hashes for newswacafi-0.7.tar.gz
Algorithm Hash digest
SHA256 c681d07be47d2a86854e2d96add0f71f481d7d6e97ef6a80b1acd9f41bf70618
MD5 24ccbbb803db95a0be09be093916c277
BLAKE2b-256 a06200cccfd28dac5ec5bfbd4771067ad59eb466a825a716af89a929ad9be878

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