PHP 8 / Composer Library for Twister
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
632 B

11 months ago
# twister-php
11 months ago
11 months ago
PHP 8 / Composer Tools for Twister API
11 months ago
## Install
11 months ago
`composer require twisterarmy/twister`
## Features
### Client
Twister client communication toolkit
### RSS
11 months ago
Useful to create twister news bot
11 months ago
11 months ago
#### Feed
11 months ago
11 months ago
Read remote URL and convert response to formatted twister messages
11 months ago
```
11 months ago
$array = \Twisterarmy\Twister\Rss::feed('url');
11 months ago
```
11 months ago
##### Attributes
11 months ago
11 months ago
* `url` - feed address
* `format` - `{title} {link}` by default
+ `{nl}` - new line
+ `{link}` - target link
+ `{title}` - item title
* `length` - `256` by default
* `errors` - array of errors
11 months ago
11 months ago
##### Result
11 months ago
```
11 months ago
[
time: int,
message: string
],
...
```