Skip to content

Commit d5e217b

Browse files
committed
Update readme
1 parent a4bb031 commit d5e217b

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

README.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
[![Software License][ico-license]](LICENSE.md)
44

5-
An activitystreams 2.0 php package
5+
** This package is in active development, this is not a complete implementation of ActivityStreams 2.0 **
6+
7+
An activitystreams 2.0 php package.
68

79
## Install
810

@@ -13,6 +15,21 @@ $ composer require dansup/php-activitystreams
1315
```
1416

1517
## Usage
18+
``` php
19+
use Dansup\ActivityStreams\ServerFactory;
20+
21+
$server = ServerFactory::create(['version' => '2.0']);
22+
23+
$item = $server->object();
24+
25+
$item->setType('Note')
26+
$item->setId('http://example.org/note/123');
27+
$item->setName('Our Weather Is Fine');
28+
$item->setContent('I feel that the weather is appropriate to our season and location.');
29+
30+
echo $item->get();
31+
```
32+
1633

1734
## Change log
1835

0 commit comments

Comments
 (0)