Sign inSign up

michielbdejong/sockethub

By michielbdejong

Updated almost 8 years ago

Image
0

509

michielbdejong/sockethub repository overview

Sockethub

A polyglot messaging service.

Build Status Dependency Status devDependency Status Code Climate License Release

Flattr this

About

Sockethub is a polyglot (speaking many different protocols and APIs) messaging service for social and other interactive messaging applications. Not only does it assist unhosted and noBackend web application developers by providing server-independent, server-side functionality, but it also can be used as a back-end tool (invisible to the user) for many different applications, large and small.

Example uses of sockethub are: writing and receiving messages (SMTP, Facebook, Twitter), instant messaging (XMPP, IRC, MSN, FB Messenger, Hangouts), discovery (WebFinger, RDF(a)). The architecture of sockethub is extensible and supports easy implementation of additional 'platforms' to carry out tasks, sockethub can be run on your own server, or provided as a service by a service provider, or app store.

Docs

See the Sockethub wiki for documentation.

Features

We use Activity Streams to map the various social networks terms to a set of 'verbs' which identify the underlying action. For example,for a facebook friend request/accept cycle, we would use the activity stream verbs 'request-friend', 'remove-friend', 'make-friend'.

Below is a list of platforms we're currently working on and their activity stream verbs (when appropriate) or verbs that are specific to Sockethub, both the completed and not yet implemented ones. They all map to the platforms actions.

PlatformsVerbs
Email (SMTP, IMAP) to portcompleted send completed fetch (imap)
XMPPcompleted send completed request-friend completed remove-friend completed make-friend completed update completed join completed observe
Facebook to portcompleted post send completedfetch request-friend remove-friend make-friend like
Twitter to portcompleted post follow unfollow send completed fetch
Feeds (RSS, Atom)completed fetch
IRCcompleted send completed join completed leave completed observe completed update
pump.iopost follow unfollow send fetch
WhatsAppsend request-friend remove-friend make-friend
WebFingersearch
RDFsearch fetch
Bitcoin (e.g. sending signed transactions to a node)(to be evaluated) send receive ...
Ethereum (e.g. contract events)(to be evaluated)
WebRTC (signaling)(to be evaluated)
Signal(to be evaluated)
MicroPub (IndieWeb, ...)(to be evaluated)
OStatus (GNUSocial, Mastodon, ...)(to be evaluated)

Setup

$ npm install

Running

$ DEBUG=sockethub* bin/sockethub --examples

You should then be able to browse to http://localhost:10550 and try out the examples.

Running using Docker Compose

Requires Docker Compose 1.10.0+

$ docker-compose up

If you’re using Docker natively on Linux, Docker for Mac, or Docker for Windows, then sockethub should now be listening on port 10550 on your Docker daemon host. Point your web browser to http://localhost:10550 to find sockethub. If this doesn’t resolve, you can also try http://0.0.0.0:10550.

If you’re using Docker Machine on a Mac or Windows, use docker-machine ip MACHINE_VM to get the IP address of your Docker host. Then, open http://MACHINE_VM_IP:10550 in a browser.

Environment Variables

  • PORT Defaults to 10550

  • HOST Defaults to localhost

  • DEBUG Specify the namespace to console log, ie. sockethub* will print all sockethub related debug statements, whereas * will also print any other modules debug statements that use the debug module.

  • REDIS_PORT Defaults to 6379

  • REDIS_HOST Defaults to localhost

OR

  • REDIS_URL Overrides REDIS_HOST and REDIS_PORT, can specify a full redis connect URL (eq. redis://username:password@host:port)

Command-line params

  --help       : this help screen
  --info       : displays some basic runtime info

  --examples   : enabled examples page and serves helper files like jquery

  --host       : hostname to bind to
  --port       : port to bind to

License

Sockethub is licensed under the LGPL

Credits

Project created and maintained by Nick Jennings

Logo design by Jan-Christoph Borchardt

Sponsored by NLNET

NLNET Logo

Tag summary

Content type

Image

Digest

sha256:c71ba568d

Size

292.7 MB

Last updated

almost 8 years ago

docker pull michielbdejong/sockethub