2017 © Pedro Peláez
 

library php-activitystreams

Activity Streams is a simple specification used to describe social actions around the web. http://activitystrea.ms

image

dansup/php-activitystreams

Activity Streams is a simple specification used to describe social actions around the web. http://activitystrea.ms

  • Sunday, December 31, 2017
  • by dansup
  • Repository
  • 2 Watchers
  • 9 Stars
  • 12 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 3 Versions
  • 9 % Grown

The README.md

php-activitystreams

A PHP implementation of the Activity Streams 2.0 specification, (*1)

![Software License][ico-license] Latest Version on Packagist ![Total Downloads][ico-downloads], (*2)

This package is in active development, this is not a complete implementation of ActivityStreams 2.0, (*3)

A modern AS2 php library. At the moment, only the object model type is partially implemented. I look forward to getting this feature complete by the end of summer 2017., (*4)

Install

Via Composer, (*5)

``` bash $ composer require dansup/php-activitystreams, (*6)


## Usage > Lets create a [basic object model](https://www.w3.org/TR/activitystreams-core/#object) and echo the response to a json encoded string. ``` php use Dansup\ActivityStreams\ServerFactory; $item = ServerFactory::create('object'); $item->type('Note') $item->id('http://example.org/note/123'); $item->name('Our Weather Is Fine'); $item->content('I feel that the weather is appropriate to our season and location.'); $item->attributedTo([ 'id' => 'http://joe.website.example/', 'type' => 'Person', 'name' => 'Joe Smith' ]); $item->addField('url', 'http://example.org/permalink/123'); echo $item->get();

Result:

``` json { "@context": "https:\/\/www.w3.org\/ns\/activitystreams", "type": "Note", "id": "http:\/\/example.org\/note\/123", "name": "Our Weather Is Fine", "attributedTo": { "id": "http:\/\/joe.website.example\/", "type": "Person", "name": "Joe Smith" }, "content": "I feel that the weather is appropriate to our season and location.", "published": "2017-04-21T01:31:20+00:00", "url": "http:\/\/example.org\/permalink\/123" }, (*7)



## Change log Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently. ## Testing ``` bash $ composer test

Contributing

Please see CONTRIBUTING and CONDUCT for details., (*8)

Security

If you discover any security related issues, please email danielsupernault@gmail.com instead of using the issue tracker., (*9)

Credits

License

The MIT License (MIT). Please see License File for more information., (*10)

The Versions

31/12 2017

dev-master

9999999-dev https://github.com/dansup/php-activitystreams

Activity Streams is a simple specification used to describe social actions around the web. http://activitystrea.ms

  Sources   Download

MIT

The Requires

 

The Development Requires

json indieweb activitystreams dansup federation as2 activity-streams

21/04 2017

0.0.2

0.0.2.0 https://github.com/dansup/php-activitystreams

Activity Streams is a simple specification used to describe social actions around the web. http://activitystrea.ms

  Sources   Download

MIT

The Requires

 

The Development Requires

json indieweb activitystreams dansup federation as2 activity-streams

20/04 2017

0.0.1

0.0.1.0 https://github.com/dansup/php-activitystreams

Activity Streams is a simple specification used to describe social actions around the web. http://activitystrea.ms

  Sources   Download

MIT

The Requires

  • php ~5.5|~7.0

 

The Development Requires

json activitystreams dansup