PHPackages                             kirill-latish/laravel-newsapi - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. kirill-latish/laravel-newsapi

ActiveProject[Framework](/categories/framework)

kirill-latish/laravel-newsapi
=============================

Laravel wrapper for https://newsapi.org/

1.0(8y ago)61.1k3MITPHPPHP &gt;=7.0.0

Since May 4Pushed 8y ago2 watchersCompare

[ Source](https://github.com/kirill-latish/laravel-newsapi)[ Packagist](https://packagist.org/packages/kirill-latish/laravel-newsapi)[ RSS](/packages/kirill-latish-laravel-newsapi/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (3)Versions (2)Used By (0)

Laravel Package for NewsAPI.org
===============================

[](#laravel-package-for-newsapiorg)

Laravel wrapper for [NewsAPI.org](https://newsapi.org) API calls. Documentation for the API can be found [here](https://newsapi.org/docs)

Installation
------------

[](#installation)

**1-** Require the package via Composer in your `composer.json`.

```
{
  "require": {
    "kirill-latish/laravel-newsapi": "^1.0"
  }
}
```

**2-** Run Composer to install or update the new requirement.

```
$ composer install
```

or

```
$ composer update
```

**3-** Add the service provider to your `app/config/app.php` file

```
NewsAPI\NewsAPIServiceProvider::class,
```

**4-** Add the facade to your `app/config/app.php` file

```
'NewsAPI' => NewsAPI\Facades\NewsAPI::class,
```

**5-** Publish the configuration file

```
$ php artisan vendor:publish --provider="NewsAPI\NewsAPIServiceProvider"
```

**6-** Review the configuration file and add your key (preferably through env: `'api_key' => env('NEWSAPI_KEY')` )

```
config/newsapi.php

```

Usage
-----

[](#usage)

Refer to the official [docs](https://newsapi.org/docs) as to which calls can be made and check the calls in traits under [NewsAPI\\Requests](NewsAPI%5CRequests).

For example, get all sources (if using facade):

```
use NewsAPI;

...

$response = NewsAPI::sources()->all();

```

The above returns an object containing a `sources` array.

Get a top headlines by country and category:

```

$response = NewsAPI::topHeadlines()->get([
            'country' => 'gb',
            'category'=>'sports'
        ]);

```

Get all news from bbc.co.uk in English for time period from 2018-05-01 to 2018-05-04 sorted by publication date:

```
        $response = NewsAPI::everything()->get([
            'language' => 'en',
            'domains'=>'bbc.co.uk',
            'from' => '2018-05-01',
            'to' => ''2018-05-04,
            'sortBy' => 'publishedAt',
        ]);

```

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2930d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/feb1304ee686d579d3b008701b28aca78156836600b3008f3a67c934f007f64b?d=identicon)[kirill-latish](/maintainers/kirill-latish)

---

Tags

apiframeworklaravel news

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/kirill-latish-laravel-newsapi/health.svg)

```
[![Health](https://phpackages.com/badges/kirill-latish-laravel-newsapi/health.svg)](https://phpackages.com/packages/kirill-latish-laravel-newsapi)
```

###  Alternatives

[nutgram/nutgram

The Telegram bot library that doesn't drive you nuts

714214.9k8](/packages/nutgram-nutgram)[lanin/laravel-api-debugger

Easily debug your JSON API.

2311.8M](/packages/lanin-laravel-api-debugger)[evias/nem-php

Composer Package for PHP (Laravel or Pure PHP), Wrapper to use the NEM blockchain REST API and SDK with NIS compatibility.

342.9k](/packages/evias-nem-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
