# News API (Notifications)

> Reference for the Leantime Notifications News JSON-RPC service: every leantime.rpc.Notifications.News method with its parameters and return values.

Source: https://docs.leantime.io/api/classes/leantime/domain/notifications/services/news/

`leantime.rpc.Notifications.News.`


## Available Methods
### `leantime.rpc.Notifications.News.__construct`

__construct - get database connection

```json
{
    "method": "leantime.rpc.Notifications.News.__construct",
    "jsonrpc": "2.0",
    "id": 1,
    "params": {
        "settingService": \Leantime\Domain\Setting\Services\Setting,
    }
}
```








**Parameters:**

| Parameter | Type | Description |
|-----------|------|-------------|
| `settingService` | **\Leantime\Domain\Setting\Services\Setting** |  |


**Returns:**

```json
{
    "jsonrpc": "2.0",
    "id": 1,
    "result": mixed
}
```



---
### `leantime.rpc.Notifications.News.getFeed`

getFeed - Fetches the feed from a remote URL and returns the contents as a SimpleXMLElement object

```json
{
    "method": "leantime.rpc.Notifications.News.getFeed",
    "jsonrpc": "2.0",
    "id": 1,
    "params": {
    }
}
```









**Returns:**
- The parsed XML content as a SimpleXMLElement object
```json
{
    "jsonrpc": "2.0",
    "id": 1,
    "result": \SimpleXMLElement
}
```



---